You are not logged in.
I want my user (sub) to be able to write to /srv/http. If I cd /srv and then chmod u+rw http, it complains that I do not have the right to do that operation. However, if I use sudo, then the root user is doing chmod so it still doesn't work. How do I make the directory writable by my user?
Offline
Make a subdirectory in there and make your user own it?
CPU-optimized Linux-ck packages @ Repo-ck • AUR packages • Zsh and other configs
Offline
add your user to the http group?
| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |
Offline
add your user to the http group?
.... Then log out, and back in.
Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way
Offline
However, if I use sudo, then the root user is doing chmod so it still doesn't work.
Wait, what?
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
subraizada3 wrote:However, if I use sudo, then the root user is doing chmod so it still doesn't work.
Wait, what?
Yes, that's right, it's still owned by root and not by sub (OP's user name). A chown could change that.
A much better approach would be the User Directories approach mentioned by ralvez (if you use apache), though. This gives you a special directory in your home dir (usually ~/public_html) that can be reached via http://localhost/~$USER (http://localhost/~sub in you case).
Edit: typo
Last edited by cookies (2013-09-07 19:04:30)
Offline
Yes, that's right, it's still owned by root and not by sub (OP's user name). A chown could change that.
I don't understand how root could not chmod it as the OP says, or am I reading it wrong?
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
cookies wrote:Yes, that's right, it's still owned by root and not by sub (OP's user name). A chown could change that.
I don't understand how root could not chmod it as the OP says, or am I reading it wrong?
chmod as root did work, but since the directory in question is still owned by root, OP would still have to be root to write to it.
Offline