I have been having a problem lately with cpanel trying to add users to the wrong directory, even though I have double and triple checked the configuration, and verified that it is set to create user accounts in /home/cpusers.
When I attempted to create accounts through WHM, it gave me a very vague error message, saying something simple like "Couldn't create user account". I dug further, into the cpanel error logs and found that cpanel was attempting to create the user's home directory in a location other than /home/cpusers, with this error message: "Adding User...useradd: cannot create directory /other/directory/username". It may or may not be relevant, but the /other/directory is a network-mounted share I use for backing up system files.
How it came to be that cpanel is trying to create user accounts there is boggling my mind, though, and any insight into this would be greatly appreciated!
(I have found a workaround, by the way: unmount the network share, add user, remount. I haven't attempted it through WHM, but it works with /scripts/wwwacct!)
When I attempted to create accounts through WHM, it gave me a very vague error message, saying something simple like "Couldn't create user account". I dug further, into the cpanel error logs and found that cpanel was attempting to create the user's home directory in a location other than /home/cpusers, with this error message: "Adding User...useradd: cannot create directory /other/directory/username". It may or may not be relevant, but the /other/directory is a network-mounted share I use for backing up system files.
How it came to be that cpanel is trying to create user accounts there is boggling my mind, though, and any insight into this would be greatly appreciated!
(I have found a workaround, by the way: unmount the network share, add user, remount. I haven't attempted it through WHM, but it works with /scripts/wwwacct!)