On a new cpanel server imap service found not working.
Checked if all library for imapd is available with
root@server38 [~]# ldd /usr/lib/courier-imap/bin/imapd
libfam.so.0 => not found
libgdbm.so.2 => /usr/lib64/libgdbm.so.2 (0x0000003166600000)
libcourierauth.so.0 => /usr/lib64/courier-authlib/
libcourierauth.so.0 (0x0000003c7da00000)
libc.so.6 => /lib64/tls/libc.so.6 (0x0000003165700000)
/lib64/ld-linux-x86-64.so.2 (0x0000003165500000)
root@server38 [~]#
Found libfam.so.0 not available on the server.
Problem is fixed by installing fam from yum.
yum install fam
After installing fam restart imap with
/scripts/restartsrv imapd