LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 04-19-2013, 12:30 PM   #1
thirteen_engines
Member
 
Registered: Sep 2009
Distribution: Slackware 14.1
Posts: 118

Rep: Reputation: 20
Can't cd to a directory


I have a weird little problem, the solution of which is eluding me.

I have a database on my office machine that is accessed by logging in as a special user. The user's default 'shell' is the database program and therefore is all the user sees upon login. Each year I update the program and database ... this year in March. Everything was ok then but not now.

When I log in as user "csd" I get:

bash: /usr/src/cambridge/.bashrc: Permission denied

This is csd's home folder. The permissions for the folder are:

drwxr-xr-x 18 csd users 4096 Mar 7 14:39 cambridge/

When I temporarily change csd's shell to bash I find that I cannot cd to this folder. Why would that be if csd owns it? BTW, folder cambridge/ is in /usr/src (because it's located on a large drive). There have been no such problems in the past. Everything was working in March.

If I change csd's home folder to /home/csd but leave the 'shell' program in cambridge/bin it still doesn't work. If I copy the entire cambridge/ folder to /home/csd I can then begin to run the program ... but I don't want to do that. I'd rather leave it on the large drive. There are other problems associated with moving it as well.

Colour me puzzled.
 
Old 04-19-2013, 12:40 PM   #2
tuxbg
Member
 
Registered: Sep 2012
Location: Bulgaria,Varna
Distribution: Slackware64
Posts: 249

Rep: Reputation: Disabled
And what is the permissions of .bashrc ?
 
Old 04-19-2013, 01:21 PM   #3
thirteen_engines
Member
 
Registered: Sep 2009
Distribution: Slackware 14.1
Posts: 118

Original Poster
Rep: Reputation: 20
There's no .bashrc file .. that's part of the mystery.
 
Old 04-19-2013, 10:15 PM   #4
Richard Cranium
Senior Member
 
Registered: Apr 2009
Location: McKinney, Texas
Distribution: Slackware64 15.0
Posts: 3,858

Rep: Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225Reputation: 2225
Please post the output of the command
Code:
grep csd /etc/passwd
What happens when you log in as root first, issue the command "su csd", and then attempt to cd into /usr/src/cambridge?
 
Old 04-20-2013, 10:20 AM   #5
thirteen_engines
Member
 
Registered: Sep 2009
Distribution: Slackware 14.1
Posts: 118

Original Poster
Rep: Reputation: 20
Here's the output of "grep csd /etc/passwd":

csd:x:1035:0:,,,:/usr/src/cambridge:/bin/bash

Logging in as root and then su'ing to csd gives:

bash: /usr/src/cambridge/.bashrc: Permission denied

What I don't understand is that I've set the permissions of /usr/src/cambridge so that csd owns it and all of it's sub-directories. This approach has worked for years but seems to have suddenly changed.

Last edited by thirteen_engines; 04-20-2013 at 10:23 AM.
 
Old 04-20-2013, 10:28 AM   #6
thirteen_engines
Member
 
Registered: Sep 2009
Distribution: Slackware 14.1
Posts: 118

Original Poster
Rep: Reputation: 20
Found what was causing the problem!!

/usr/src had permissions 700 ... only root could cd there. Everything is good now. Thanks for the replies.
 
  


Reply



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
[SOLVED] Modify the directory entry structure of a directory to show manipulated data shreyas08 Linux - Newbie 1 12-13-2011 05:34 AM
Username & Password Sync Fedora Directory and Microsoft Active Directory karnac01 Fedora 4 07-19-2010 12:51 AM
change default vsftp anonymous accout directory /var/ftp to other directory? hocheetiong Linux - Newbie 2 01-24-2010 06:33 PM
Active Directory User Cannot Write to Samba Home Directory jonwatson Linux - Networking 2 12-19-2006 12:40 PM
LXer: Directory services made easy with Fedora Directory Server LXer Syndicated Linux News 0 12-08-2006 03:54 AM

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

All times are GMT -5. The time now is 10:47 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