LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-07-2008, 12:28 PM   #1
Unstoppable86
LQ Newbie
 
Registered: Oct 2003
Distribution: centos 5
Posts: 2

Rep: Reputation: 0
Major stupidity: Chown -R someuser /


First I laughed at my stupidity. I'm not laughing anymore.

Logged in as root (shoot me) I wanted to execute the command:
$ chown -R someuser /home/someuser
Instead i pressed ENTER after the first /

So all files on my system were owned by someuser. I chowned them all back to root first.

Trying to get some stuff working again, before I do a complete reinstall tomorrow.

DA/Apache/MySQL all seem to be fixed.

Can't seem to get mail to work.

I run Dovecot and Exim on centos 5 with DirectAdmin 1.32.3

Is there a list of files that should be owned by specific users for DirectAdmin/dovecot/exim?

Some suggestions or some advice would be very welcome.

Thanks in advance.

Best Regards,

NME
 
Old 11-07-2008, 12:38 PM   #2
DotHQ
Member
 
Registered: Mar 2006
Location: Ohio, USA
Distribution: Red Hat, Fedora, Knoppix,
Posts: 545

Rep: Reputation: 33
UUUUuuuuuuu That is ugly.
My only advice would be to cd to where you want to do the chown before running the command with a -R. Then you wouldn't need the / in front of the command. If you are using absolute path it really doesn't matter where you are. Hitting the enter key at that inoppurtune time would have the same result if just the / is there.
Sorry, but like you said this will probably take a reinstall to get everything back as it should be ...unless you happen to have a backup that you could restore.

Last edited by DotHQ; 11-07-2008 at 12:40 PM.
 
Old 11-07-2008, 12:46 PM   #3
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
ditto re-install

I have done things like this many times---most attempts to fix have failed.
 
Old 11-07-2008, 12:48 PM   #4
Unstoppable86
LQ Newbie
 
Registered: Oct 2003
Distribution: centos 5
Posts: 2

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by DotHQ View Post
UUUUuuuuuuu That is ugly.
My only advice would be to cd to where you want to do the chown before running the command with a -R. Then you wouldn't need the / in front of the command. If you are using absolute path it really doesn't matter where you are. Hitting the enter key at that inoppurtune time would have the same result if just the / is there.
Sorry, but like you said this will probably take a reinstall to get everything back as it should be ...unless you happen to have a backup that you could restore.
Yep, you are absolutely right.

Fortunately I run DirectAdmin. Through the DA forums I found this solution:

Code:
cd /usr/local/directadmin/scripts
./set_permissions.sh all
That should restore all permissions and ownage for all DA-related stuff.

However e-mail is still not working. No errors anymore, but e-mails just seem to disappear...

Exim log says:

appendfile transport process returned non-zero status 0x0100: exit code 1
unable to set gid=12 or uid=503 (euid=8): local delivery to...
failed to read delivery status for email@address.com from delivery subprocess

Edit: just ran the exim.sh (install)script from the DA scripts dir and that fixed it. E-mail seems to work. Everything seems to work.

Probably will find new errors in the next couple of days. If so, i'll reinstall.

Thanks guys.

Last edited by Unstoppable86; 11-07-2008 at 01:53 PM.
 
  


Reply


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
Record company stupidity. jschiwal General 6 03-03-2007 01:53 AM
??? Xsession: Login for someuser is disabled. mark_umr SUSE / openSUSE 2 10-12-2005 05:25 AM
rm stupidity JoeUser11 Linux - Newbie 1 07-12-2005 10:49 PM
Stupidity in America xhypno General 26 02-17-2005 09:43 PM
php DSO stupidity Kilka *BSD 5 01-08-2004 04:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:49 AM.

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