Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Slackware This Forum is for the discussion of Slackware Linux.


  Search this Thread
Old 08-30-2007, 02:33 AM   #1
Registered: Aug 2004
Distribution: opensuse ,debian
Posts: 208

Rep: Reputation: 30
Totally messed up the user permissions.*want to cry*

Hi all,

i need help.

i've done something stupid cause of my ignorance.
Im' not too familiar with chmod and did something stupid invoked
#chmod -R 766 /DATA *
in / directory.
actually i wanted to make this happen inside /DATA (my own partition) only but you know the rest...
anyway, in the middle i pressed ctrl-c so not all directories changed.
but some like /bin,/boot, have changed

fallback is just chmode -Rv 755 for directories that seems have been affected.
is that good enough?

and now after exit su and want to su again, i get this error:
setgid: Operation not permitted
Should i reinstall?
Old 08-30-2007, 03:50 AM   #2
Senior Member
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 291Reputation: 291Reputation: 291
I'm not sure how to correct you problem, but if your /DATA partition is just for your personal files, and you just want to get read and write permission to /DATA as a regular user, then in the future just do "chown -R your_user_name:users /DATA" will do it.
I have a /data partition for my personal data because I have several distros on my PCs and want to keep the config files that are stored in /home separate from each other so that is how I do it.

Last edited by tommcd; 08-30-2007 at 03:51 AM.
Old 08-30-2007, 04:11 AM   #3
LQ Guru
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
I see two choices here, one is to have a (working) Linux from which to check the working permissions on the directories and then chmod them to your own machine's equivalents, and the other is to reinstall. If you have a separate /home, have backed your data up or don't have anything to back up, it's definitely easiest done if you reinstall. If you haven't got a separate /home (if you did, you could reinstall without losing personal data), back up at least your /home and possible other important data, and boot from Slackware install disc.

This is a good example why people should not use commands with root privileges without thinking first, and preferrably using interactive mode (question per target, yes/no).
Old 08-30-2007, 04:19 AM   #4
LQ Guru
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,844

Rep: Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596Reputation: 1596
Take a look at this post and the link provided to see if it can help you to avoid reinstalling.

Good luck
Old 08-30-2007, 12:10 PM   #5
Amigo developer
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,856

Rep: Reputation: 547Reputation: 547Reputation: 547Reputation: 547Reputation: 547Reputation: 547
Here's the script in question if not still avaliable:
#Create a script to restore the filesystem permissions from the MANIFEST (stdin)

# Author:   Cameron Kerr
# Email:
# Website:
# Version:  27 August 2001'

if [ $# -ne 0 ]; then
  echo "USAGE: zcat MANIFEST.gz | `basename $0` > /tmp/" >&2
  echo "       su - (if not root already)" >&2
  echo "       /tmp/" >&2
  exit 255

echo "#!/bin/sh"
echo "#This script was generated by `basename $0` from a Slackware MANIFEST.gz"
echo "#It will restore permissions to all files listed in the MANIFEST.gz,"
echo "#even files not there, so you might like to filter out 'not found'"
echo "#messages"
echo "#"
echo "#About the generator ${about_text}"

cat | sed -e '
/^ *$/d
  s/^\(.*\) \(.*\)\/\(.*[^ ]\)  *.* .* .*  *\(.*\)$/\
chown \2.\3 \/\4\
chmod PERM\1PERM \/\4/
  /PERM.*[^ ]PERM/{
If your MANIFEST is a .bz2 file you can change the 'zcat' above to 'bzcat' and make it work. Be sure to cd into the directory where the MANIFEST is or give the full path.
Old 08-30-2007, 11:16 PM   #6
Registered: Aug 2004
Distribution: opensuse ,debian
Posts: 208

Original Poster
Rep: Reputation: 30
Dear moderator,
sorry for the double threads, it seems i clicked twice when submitting yesterday.Too nervous

Hello guys,
thanks for the replies!
using MANIFESTO.gz and the smprms script from ,IIRC,linuxangel site quite working well didn't know what MANIFESTO.gz was all about until now...
tnx,tnx,tnx !
my su is working, sound is working. At least my slackware more usable now.
But, i don't trust my own system anymore cause of my own action .lol.. and i have
some unofficial pkg installed that probably have changed in yesterday disaster and not covered by MANIFESTO.gz .
so, now i have the reason to fresh install slackware 12.0 sometime soon!
won't forget to backup my data ofcourse.

oh yeah,b0uncer i think you know what i was trying before this mess-up you're the only one that reply in my other thread
I will update that thread after trying MORE carefully.
This is why i like about slackware and the community.Dependable most of the time..
Old 08-31-2007, 05:00 AM   #7
Registered: Aug 2004
Distribution: Slack10 & curr. tried numerous
Posts: 189

Rep: Reputation: 36
Before reinstall might want to
 man upgradepkg
As in from your source subdirectories
 upgradepkg --reinstall *.tgz
yea there is a way to make it recursive but didn't


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Totally whacked permissions! raid517 Linux - Software 1 06-04-2005 06:26 AM
X hangs at startup, permissions for normal user messed up. elgatofilo Slackware 5 12-20-2004 08:48 PM
sound totally messed up djlosch Linux - Hardware 8 09-02-2004 09:24 PM
Messed up my permissions usercsr Slackware 7 07-08-2004 11:21 AM
GRUB is totally messed up! is blaster to blame randyriver10 Linux - Software 6 03-22-2004 05:28 PM > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:30 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration