Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On a CentOS server running Plesk, new users are added for each new domain. The users' home directories are in /var/www/vhosts/. New users' home directories are owned by root, and need to have an admin with root access come in and chown them:

dotan@sh2:~$ echo $HOME
dotan@sh2:~$ pwd
dotan@sh2:~$ touch testFile
touch: cannot touch `testFile': Permission denied
dotan@sh2:~$ ls -la ../ | grep someDomain
drwxr-xr-x 13 root root 4096 2012-08-07 19:47
dotan@sh2:~$ whoami
dotan@sh2:~$ chown dotan /var/www/vhosts/
chown: changing ownership of `/var/www/vhosts/': Operation not permitted

Why might the new users' directories be owned by root, and how might we fix this?


share|improve this question
How is the user created? The adduser script should do a chown of the user's home directory. – jan.vdbergh Sep 3 '12 at 6:16
up vote 1 down vote accepted

They are owned by root on my server also. That's a part of the security scheme designed for Plesk. A domain user is allowed to write in some of subfolders (docroots of their sites, cgi-bin, etc), but cannot change general structure of directories. If changed, sometimes this may cause malfunction of your Plesk server.

If you are sure you need these changes and they are safe for you servers, you can probably look at Event Handlers tool of Plesk and code a simple script changing privileges automatically for each new domain

share|improve this answer
I see, thanks. That is quite a hack by the Plesk devs, instead of coding Plesk to be more robust on unexpected directory structures, or simply keeping everything important to it in $HOME/.plesk like every other UNIX application. It breaks so many other things (RSA keys, VIM, no .bashrc, etc.). – dotancohen Sep 3 '12 at 9:59
Every other Linux application approach isn't good either. The one has whole $HOME of .xxx and .yyy instead of $HOME/.system/.xxx. – Sergey L Sep 3 '12 at 10:05
Thats why they use .name instead of name: to keep the directories hidden and not bothersome when one just needs to access his own files! I do see your point, though. I think that Microsoft operating systems use your suggested approach, no? – dotancohen Sep 3 '12 at 10:07

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.