![]() |
Shot myself in the foot
OK, I made a mistake that is killing me. Long story, but I reset the permissions on /var/run to to be owned by root, group users with group having read/write as well. I then copied that down to the subfolders and stuff stopped working (most notably apache couldn't access mysql through the socket in /var/run/mysql).
Is there anyway to recover these permissions. Or in knowing how they should be set? (FWIW, I have backups but not of the entire /var tree) (FWIW2 - this is my home system and of not huge importance) Thanks |
/var/run
drwxr-xr-x 35 0 0 4096 2009-01-03 16:49 run The sub directorys have drwxr-xr-x 2 0 0 4096 2008-07-29 16:33 sshd |
You may get help from the script Alan Hicks posted on a.o.l.s. some years ago. The script uses Slackware's "slackware/MANIFEST.bz2" file to generate a load of commands that reset the permissions back to the original state of every file/directory installed by Slackware.
You can capture these commandlines (they are written to the standard output of the script) and remove everything you don't need (only the commands that change permissions and owndership below /var are relevant to you). You can find the posting of that script here: http://groups.google.nl/group/alt.os...1872abfdf2c110 Eric |
These are mine if they help
directories: Code:
root@jupiter:~# find /var/run -type d -exec ls -ld {} \;Code:
root@jupiter:~# find /var/run -type f -exec ls -ld {} \; |
Quote:
Brian |
Eric, I'm trying a hybrid approach. I'm reviewing the contents of MANIFEST And setting the perms by hand. I can always go back and cleanup MANIFEST and run the script. Thanks
Brian, when I set /var/run/mysql to mysql:mysql I get this error from a web app Code:
Can't connect to local MySQL server through socket '/var/run/mysql/mysql.sock' (13) |
what does "ls -l /var/run/mysql" show?
Brian |
Quote:
Code:
root@USlack2:/etc/cron.weekly# ls -l /var/run/mysqlNote: this is a php app if it matters. |
Is that = sign at the end of mysql.sock a typo?
"chmod o+w /var/run/mysql.sock" should take care of it. Brian |
Following GazL's lead, here are mine (Slackware 12.1, basic install):
Code:
root@FamilyRoom:/# find /var/run -type d -exec ls -ld {} \; |
Quote:
Eric |
Quote:
Brian |
Solved
Quote:
Before: Code:
root@USlack2:/var/run/mysql# ls -lCode:
root@USlack2:/var/run/mysql# ls -lOne other thing. the "=" is not a typo. It shows in the console like that. What does that mean? |
Quote:
|
I need to find a good tutorial on unix/linux rights. I know the basics, ok. But the sticky bit, uid & gid still trip me up. For instance, the "s" at the beginning of this line:
Code:
srwxrwxrwx 1 mysql mysql 0 2009-01-01 01:24 mysql.sock= |
| All times are GMT -5. The time now is 11:07 AM. |