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 - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-13-2005, 03:08 AM   #1
u4u
LQ Newbie
 
Registered: Aug 2003
Location: Pune (india)
Posts: 15

Rep: Reputation: 0
Unhappy Others should not access my home directory.


I have an account on Unix server. After typing login name and password i can go into my home directory.
If my home directory is "/home/abc" so now
$ pwd
$ /home/abc
$ cd /home
$ pwd
$ /home
$ ls ab*
abc:
abc:
shows the directory contents

abd:
abd: Permission denied

abe:
abe:
shows the directory contents

abg:
abg: Permission denied
$

That means for few home directories (including my directory) i have accessed to browse in that directories (/abc, /abe). But for few directory it doesn't allow me to enter (/abd, /abe).
Now the question is i also want to block my home directory so that no one can access it. And when other users fire the same command (ls ab*) then it does not show my home directory contents (msg: Permission denied).
How can i achieve it? Please help me.
 
Old 01-13-2005, 03:19 AM   #2
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
You need to change the directory permissions of your home directory. See
Code:
man chmod
for details.

Note: If the nobody user can't see your home directory, then you won't be able to serve web pages in your user's public_html folder.
 
Old 01-13-2005, 03:23 AM   #3
oneandoneis2
Senior Member
 
Registered: Nov 2003
Location: London, England
Distribution: Ubuntu
Posts: 1,460

Rep: Reputation: 48
chmod -R 700 /home/yourdir

will work, but as rjlee says, may have consequences you don't like. . .
 
Old 01-16-2005, 09:28 AM   #4
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
What is your default group? Is it 'abc' or 'users'?
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
programs have no access to home directory. SnowSurfAir Linux - Software 4 07-14-2005 12:05 AM
Unable to access home directory zillah Solaris / OpenSolaris 50 07-07-2005 07:39 AM
apache unable to access /home/*/public_html directory cavemanf16 Linux - Software 6 07-08-2004 05:43 AM
vsftpd access to non-home directory rwhart Linux - Newbie 1 02-10-2004 01:42 AM
Access denied to 'Home' directory aviceda Linux - Newbie 2 11-07-2003 01:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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