LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 07-26-2006, 10:03 PM   #1
Justin2021
Member
 
Registered: Apr 2006
Distribution: Gentoo 2005.1
Posts: 32

Rep: Reputation: 15
Cool permissions wont allow me to write


as the controller of my file server, i want to be able to access all accounts on it without any problems. for some reason, after mounting one of the accounts to my personal home folder from the server, and try putting a file on it, i get this error.

Error "File not found" while copying "/home/justin...s/intro.doc".

I give all accounts (except mine) chmod 550, so that they can't write to their home folder, and can't look in other peoples folder. But when i sign into my account, i want to be able to see everything, and be able to do anything i want. delete files, create files, look into people's home folders. any ideas?
 
Old 07-26-2006, 10:24 PM   #2
scott2004
Member
 
Registered: Nov 2004
Location: Toronto, Canada
Distribution: Debian, OpenBSD, SuSE, Ubuntu
Posts: 68

Rep: Reputation: 15
please provide more info

Hi Justin,
This might be a permission issue, or it might be something else. Could you post your /etc/fstab or the mount command you used to manually mount the file system? Is the file system you're mounting on the same server (e.g., separate partition) or is it a network share?

To be thorough, once you have your file system mounted also post the outpout of "cat /etc/mtab".

Scott
 
Old 07-26-2006, 10:42 PM   #3
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
Umm, use a root account?
 
Old 07-26-2006, 10:50 PM   #4
spooon
Senior Member
 
Registered: Aug 2005
Posts: 1,755

Rep: Reputation: 51
Quote:
Originally Posted by Justin2021
I give all accounts (except mine) chmod 550, so that they can't write to their home folder, and can't look in other peoples folder.
What does it mean to "give all accounts (except mine) chmod 550"? And why would you want to do this? There's no point to denying permissions to the owner of something (since they control the permissions).
 
Old 07-26-2006, 10:56 PM   #5
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
If you mounted a partition at your home directory you won't see any of the files that were in that directory. For example, if you have a file called /home/justin/intro.doc and then you mount a partition with something like mount /dev/something /home/justin then the files that were in /home/justin are no longer visible. After you umount with umount /dev/something then /home/justin/intro.doc will again be visible.

You could mount the partition a level lower, for example mount /dev/something /home/justin/mnt and that would work. Either that, or I'm mis-interpreting your error

Please read spooon's reply carefully - if you do chmod 0550 /home/bloggs and bloggs is the owner of /home/bloggs, then bloggs can change the permissions to whatever they like.
 
Old 07-26-2006, 10:57 PM   #6
scott2004
Member
 
Registered: Nov 2004
Location: Toronto, Canada
Distribution: Debian, OpenBSD, SuSE, Ubuntu
Posts: 68

Rep: Reputation: 15
I'm guessing by "accounts" he means home directories?
 
Old 07-26-2006, 10:58 PM   #7
Justin2021
Member
 
Registered: Apr 2006
Distribution: Gentoo 2005.1
Posts: 32

Original Poster
Rep: Reputation: 15
to mount my account on the debian server, i used the program smb4k, which is a graphical program that allows mounting shares and acts as a samba client. and it is a network share because it's not part of the harddrive im using now, its in the server.

here is my /etc/fstab on my ubuntu desktop

Code:
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda1       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda5       none            swap    sw              0       0
/dev/hdd        /media/cdrom0   udf,iso9660 user,noauto     0       0
and here is the one on my debian server

Code:
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda2       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda1       /home           ext3    defaults        0       2
/dev/hdc        /media/cdrom0   iso9660 ro,user,noauto  0       0
/dev/fd0        /media/floppy0  auto    rw,user,noauto  0       0
ubuntu's mtab:


/dev/hda1 / ext3 rw,errors=remount-ro 0 0
proc /proc proc rw 0 0
/sys /sys sysfs rw 0 0
varrun /var/run tmpfs rw 0 0
varlock /var/lock tmpfs rw 0 0
procbususb /proc/bus/usb usbfs rw 0 0
udev /dev tmpfs rw 0 0
devpts /dev/pts devpts rw,gid=5,mode=620 0 0
devshm /dev/shm tmpfs rw 0 0
lrm /lib/modules/2.6.15-26-386/volatile tmpfs rw 0 0
/dev/hdc /media/cdrom-1 udf ro,nosuid,nodev,uid=1000,gid=1000,umask=007,iochars$//DEBIAN/ninjamasterbobby /home/justin/debian/DEBIAN/ninjamasterbobby smbfs rw $

debian server's mtab:

/dev/hda2 / ext3 rw,errors=remount-ro 0 0
proc /proc proc rw 0 0
devpts /dev/pts devpts rw,gid=5,mode=620 0 0
tmpfs /dev/shm tmpfs rw 0 0
/dev/hda1 /home ext3 rw 0 0
usbfs /proc/bus/usb usbfs rw 0 0

and i am using ubuntu so i dont know how to graphically log into root. also, i am denying these permisions because i dont want them to put stuff into the server, i just want them to take stuff from it. in other words i dont want it used as a storage space for their stuff. is there anyway to not let them change their permissions?

Last edited by Justin2021; 07-26-2006 at 10:59 PM.
 
Old 07-26-2006, 11:12 PM   #8
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
Quote:
Originally Posted by Justin2021

and i am using ubuntu so i dont know how to graphically log into root. also, i am denying these permisions because i dont want them to put stuff into the server, i just want them to take stuff from it. in other words i dont want it used as a storage space for their stuff. is there anyway to not let them change their permissions?
Never log into X as root. Ubuntu's good in that way.

If you just want them to 'take', why don't you just create a shared directory that allows access from anyone?
 
Old 07-26-2006, 11:20 PM   #9
Justin2021
Member
 
Registered: Apr 2006
Distribution: Gentoo 2005.1
Posts: 32

Original Poster
Rep: Reputation: 15
the reason is because there are certain people who i want to only have certain things.
 
Old 07-26-2006, 11:26 PM   #10
scott2004
Member
 
Registered: Nov 2004
Location: Toronto, Canada
Distribution: Debian, OpenBSD, SuSE, Ubuntu
Posts: 68

Rep: Reputation: 15
Could you clarify which server is supposed to be doing what and what you are trying to do with the servers? For ex., what directory on which server do you want users to access but not write to? How are users getting access to that directory -- Samba, http, a graphical or terminal session on the file server, NFS?

Scott
 
Old 07-26-2006, 11:29 PM   #11
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
This might be one of those occasions where acls are appropriate.
 
Old 07-26-2006, 11:40 PM   #12
Justin2021
Member
 
Registered: Apr 2006
Distribution: Gentoo 2005.1
Posts: 32

Original Poster
Rep: Reputation: 15
okay, i have a debian server running samba that i want to use as a sort of repository. you can get stuff from it, but you cant add to it. every person's account can't be written to by them, but i want to be able to write and add to it. lets say i made an account for a friend and its called /home/travis/. well, i want travis to only be able to draw from this account, and not be able to store things in this accoutn, for hard drive space reasons. but yet, if i want to give travis something, lets say a text file, i have the power to go into his acount and put that text file in there, without having any permission problems. those people would be using ssh to get to their account.
 
Old 07-27-2006, 12:43 AM   #13
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
If you're going to use samba, why not just set "read only = yes" on the shares?
 
Old 07-27-2006, 01:19 AM   #14
Justin2021
Member
 
Registered: Apr 2006
Distribution: Gentoo 2005.1
Posts: 32

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Matir
If you're going to use samba, why not just set "read only = yes" on the shares?

because when the people log on, they are not connecting to samba, they are actually going into the server and accessing their home folders in the server.
 
Old 07-27-2006, 01:27 AM   #15
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Debian, Arch
Posts: 8,507

Rep: Reputation: 128Reputation: 128
Ok, so you want users with full SSH access to be unable to write to any part of the system? That'll need quite a bit of tweaking. Take /tmp for example... any user can write files there.

Securing their home directory... I guess you'd need to create a group for each user, then make their home directory owned by root:<their group> with permissions like 750. Then place files in there and set the owner and permission accordingly as well.
 
  


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
No Write Permissions? Masrad Ubuntu 2 06-03-2006 04:48 PM
'write permissions einstien Linux - General 1 03-28-2005 08:47 AM
Write permissions kougar Linux - Newbie 13 06-04-2004 12:43 PM
LILO.conf wont write w0lv3rin3 Linux - Software 7 03-13-2004 05:08 PM
MBR wont let write over 65K slackwarefan Linux - Software 1 10-05-2003 10:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 01:30 PM.

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