View previous topic :: View next topic |
Author |
Message |
darkfnord23 n00b
Joined: 02 Nov 2003 Posts: 25
|
Posted: Sat Jan 31, 2004 9:58 am Post subject: Major Mistake, Looking for Solution |
|
|
I recently blasted by /usr directory with a
chown -R root:users *
because i thought i was in a different directory. So obviously, everything has the wrong permissions. Other than /usr/sbin, which I imagine should be owned by root:root, I have no clue what the exact permissions should be. Note that this includes /usr/bin and the portage directory. Do I need to reinstall? Reinstalling is going to be annoying.
Matt |
|
Back to top |
|
|
beowulf Apprentice
Joined: 07 Apr 2003 Posts: 225
|
Posted: Sat Jan 31, 2004 11:00 am Post subject: |
|
|
Aren't most things in /usr owned by root:root anyways? Luckily it wasn't chmod command eh
Anyways, I ran this command:
Code: |
# su -
# cd /usr
# find -not -group root -not -user root -exec ls -l {} \; 2>/dev/null >/root/non.root.files
|
And came up with this list:
Code: |
-rw-r--r-- 1 bin bin 1563 Jan 13 21:54 ./include/gdbm/dbm.h
-rw-r--r-- 1 bin bin 2003 Jan 13 21:54 ./include/gdbm/ndbm.h
-rw-r--r-- 1 bin bin 4744 Jan 13 21:54 ./include/gdbm.h
-rw-r--r-- 1 bin bin 5192 Jan 13 21:54 ./share/man/man3/gdbm.3.gz
-rw-r--r-- 1 bin bin 8696 Jan 13 21:54 ./share/info/gdbm.info.gz
-rwsr-xr-x 1 lp lp 8996 Jan 20 00:07 ./bin/lppasswd
|
Maybe the fix is to
Code: |
chown root:root /usr/*
chown games:games /usr/games
|
and then manually fix any files that match the list above? Maybe other's can help flesh out the list... _________________ I have nothing witty to say here... ever |
|
Back to top |
|
|
wilburpan l33t
Joined: 21 Jan 2003 Posts: 977
|
Posted: Sat Jan 31, 2004 6:19 pm Post subject: |
|
|
I just checked out my /usr directory. The vast majority of the files in /usr are owned by root. I see the occasional user/group set as something else, mainly bin, user, 1000, or an individual user name.
Packages that look like they emerge files with user/groups other than root include:
svgalibs
binutils
gdbm
kdemultimedia
xmms-themes
any games program
I think that if you just reemerge these, if you have them installed, the permissions will be set back to where they should be. If you have any package that looks like it's misbehaving, you can always reemerge that package too.
Hope this helps.
And just to tweak the command line advocates out there: this probably would not have happened if you were using a GUI to manage your files. _________________ I'm only hanging out in OTW until I get rid of this stupid l33t ranking.....Crap. That didn't work. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|