LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-08-2006, 04:01 PM   #1
jdb04
LQ Newbie
 
Registered: Jun 2006
Location: Boston, MA
Distribution: Ubuntu 8.04
Posts: 10

Rep: Reputation: 0
permissions


i'm having an odd problem... I'm running samba version 3.0.22 on my slackware machine. I turned it off yesterday while it was working perfectly fine and I turned it on today and now it won't work. Upon further investigation, I found that smbd doesn't have permission to smb.conf in etc/samba. I went to change that, but found out that I don't have permission to it either! I can't do anything with the file! I'm by no means an advanced user, so please feel free to dumb down your responses =)

if you need any more information, just let me know. thanks.
 
Old 08-08-2006, 04:05 PM   #2
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
I'm a little confused when you say you don't have permissions to the file. Do you not have access to the root account? If not, you will probably need to ask the system administrator to update it for you.

If you mean that you can't change the file after logged in (or su'd) as root, then that's another story. Is the /etc/smbd.conf being hosted by another computer though nfs or a samba share? If so, you need to configure the permissions on that computer.

regards,
...drkstr
 
Old 08-08-2006, 09:21 PM   #3
jdb04
LQ Newbie
 
Registered: Jun 2006
Location: Boston, MA
Distribution: Ubuntu 8.04
Posts: 10

Original Poster
Rep: Reputation: 0
i wish there were a more compitent sys. admin, but unfortunately that's me =\ Here's what happens step by step...

I log in as root
#cd /etc/samba
#ls -l
/bin/ls: smb.conf: Permission denied
/bin/ls: private: Permission denied
total 0

if i try to do anything else to either of these files, similar messages about "Permission denied" follow. What troubles me is that I was under the impresssion that, as root, I have access to everything regardless of ownership and permission. Was I mistaken? How did this even happen in the first place? anyway thanks,

-jeremy
 
Old 08-08-2006, 10:48 PM   #4
drkstr
Senior Member
 
Registered: Feb 2006
Location: Seattle, WA: USA
Distribution: Slackware 11.0
Posts: 1,191

Rep: Reputation: 45
Quote:
I have access to everything regardless of ownership and permission. Was I mistaken? How did this even happen in the first place?
Well this is sorta true. You could still deny your self access by changing the permissions incorrectly. If this is the case, then your in luck; it's an easy fix.

Just log in as root and change them back.

Code:
chown root.root /etc/samba/*
chmod 700 /etc/samba/*
This changes the ownership of all the files back to user root, group root. The next command changes the permissions of the file to Owner=rwx (full permissions), group=--- (not accessible), and everybody=--- (not accessible). You can also use 722 for rwx--r--r.

Let me know if this still does not resolve the problem.

regards,
...drkstr
 
Old 08-09-2006, 09:07 AM   #5
jdb04
LQ Newbie
 
Registered: Jun 2006
Location: Boston, MA
Distribution: Ubuntu 8.04
Posts: 10

Original Poster
Rep: Reputation: 0
same thing =\

Code:
chown: cannot access `/etc/samba/smb.conf': Permission denied
same deal with chmod. that was my first instict. when that didn't work, I posted.

this is pretty odd, hehe...

thanks,

-jeremy
 
Old 08-09-2006, 09:13 AM   #6
piete
Member
 
Registered: Apr 2005
Location: Havant, Hampshire, UK
Distribution: Slamd64, Slackware, PS2Linux
Posts: 465

Rep: Reputation: 44
I'd be willing to bet someone's left leg that the problem is not the files inside /etc/samba, but the directory!

What are the permissions on /etc/samba itself?

Code:
administrator@Melchior:~$ ls -l /etc/ | grep samba
drwxr-xr-x   3 root root     4096 2005-04-19 15:44 samba/
If that's correct, then we need to start wondering if there is some more deep-rooted fault. My next step would be use a bootdisk and see what sort of edits i could make using something else; if that still failed, i'd start to suspect hardware faults and probably run a non-destructive disk check.

Let us know how it turns out,
- Piete.
 
Old 08-09-2006, 10:35 AM   #7
jdb04
LQ Newbie
 
Registered: Jun 2006
Location: Boston, MA
Distribution: Ubuntu 8.04
Posts: 10

Original Poster
Rep: Reputation: 0
what piete suggested might be correct. There is indeed a problem with the directory. the permissions on the folder are indeed what you said, drwxr-xr-x root root. however, I can't read or write *anything* to the directory:
Code:
cp new /etc/samba/
cp: cannot create regular file `/etc/samba/new': Input/output error
so... how do i make a bootdisk? and consequently, how do i run a non-destructive disk check? You can direct me to a tutorial somewhere if you don't feel like running me through it here.

thanks for helping me narrow down what the problem is!

-jeremy
 
Old 08-09-2006, 10:43 AM   #8
piete
Member
 
Registered: Apr 2005
Location: Havant, Hampshire, UK
Distribution: Slamd64, Slackware, PS2Linux
Posts: 465

Rep: Reputation: 44
Ooh, ouch, IO errors are not good ...

There are lot of different tools out there, but I reckon the only one you need to check this problem is here:

http://www.ultimatebootcd.com/

I make the assumption you know how to a burn a CD, since you've managed to get Slackware installed =)

Pop back to LQ if you need some more pointers!

- Piete

PS: The disk check tools available to you will be based on your hard drive manufacturer. UBCD consolidates all these tools into a bootable CD for ease of use.
 
Old 08-09-2006, 01:01 PM   #9
jdb04
LQ Newbie
 
Registered: Jun 2006
Location: Boston, MA
Distribution: Ubuntu 8.04
Posts: 10

Original Poster
Rep: Reputation: 0
well, i managed to get slack installed because I have a really brilliant friend help me do it! Since he's away, I've been on my own. However these are all things I need to learn eventually, so i guess this is a blessing in disguise! (I'm trying to keep a positive attitude here =) ).

I'll try out that website and let you know how it goes.

Thanks again,

-Jeremy
 
  


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
file permissions OK, but command permissions? stabu Linux - General 2 10-05-2005 01:00 PM
permission ... permissions .... permissions alaios Linux - General 1 05-31-2005 05:16 AM
Need Help with Permissions imagreg Slackware 21 04-30-2004 01:58 PM
permissions spuppett Linux - Newbie 4 04-12-2004 02:32 PM
getting a directory's permissions and creating a new one with the same permissions newbie1000101 Programming 1 04-10-2004 01:52 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 03:29 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
Open Source Consulting | Domain Registration