Cpanel does not show created email accounts
The problem I ran into is cpanel did not show the created email account in the Email Accounts section of cpanel. The account was created in $HOME/etc/domain.com/etc/passwd and shadow. After running
strace -vvFf -s 4096 -o /root/strace.cpsrvd -p `cat /var/run/cpsrvd.pid`
And seeing what files were opened on the page I came to
5668 stat64("/home/flyingdu/.cpanel/email_accounts.yaml", 5668 stat64("/home/flyingdu/.cpanel/email_accounts.cache",
I removed the two files in the the .cpanel folder of the user - file email_accounts.yaml and file email_accounts.cache. Once the cpanel page was reloaded the email accounts showed.