LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 06-06-2003, 10:11 PM   #1
cli_man
Member
 
Registered: Apr 2002
Location: New York, USA
Distribution: Redhat 7.2, 9.0 Slackware 9.1
Posts: 428

Rep: Reputation: 30
2 users 1 UID?


I do alot of webhosting and I have companys that would like several usernames and passwords to be able to ftp the files to the server, all the users need to be able to add, delete, and modify the files in that directory. In the past when one user would post a file another user in the same group could not modify, or something like that, there always seemed to be odd problem.

My question and it is probably a bad idea but...

Can I have several users with the same uid? I wouldn't have thought of it but I mistakenly made sever users in webmin with the same uid and it didn't crash my system or anything, or will this give me big problems in the future?

In my mind if it is ok to have several users with the same uid there would be no permission problems. Oh and as a sidenote the users only have access to the web so there is no other data to concider.

Thanks for the info
 
Old 06-06-2003, 11:10 PM   #2
whansard
Senior Member
 
Registered: Dec 2002
Location: Mosquitoville
Distribution: RH 6.2, Gen2, Knoppix,arch, bodhi, studio, suse, mint
Posts: 3,304

Rep: Reputation: 65
yes you can.
next poster will say,
no, you shouldn't
 
Old 06-07-2003, 08:22 AM   #3
cli_man
Member
 
Registered: Apr 2002
Location: New York, USA
Distribution: Redhat 7.2, 9.0 Slackware 9.1
Posts: 428

Original Poster
Rep: Reputation: 30
That is what I thought, but I thought it would be worth an ask.
 
Old 06-07-2003, 02:18 PM   #4
whansard
Senior Member
 
Registered: Dec 2002
Location: Mosquitoville
Distribution: RH 6.2, Gen2, Knoppix,arch, bodhi, studio, suse, mint
Posts: 3,304

Rep: Reputation: 65
if you think about it, it's not really like having several
users with with the same id, it's like have one user
with several passwords(and login names)

the standard way for doing what you want would be to
make a group that those users belong to, and the
default file creation permission mask makes files
rwx to that group. i guess what you want is
permission 775 for those files.
 
Old 06-07-2003, 06:55 PM   #5
JayCnrs
Member
 
Registered: Mar 2003
Location: Winnipeg
Distribution: Suse 9.3 Pro
Posts: 404

Rep: Reputation: 30
Yes you would want one group, ensure everybody is part of the group and the group has read write permission.

For the directory you would want do this in console:
chown -R user:group /name-of-directory
chmod -R 775 /name-of-directory

This will change permissions on every file in the named directory, give that a shot and everybody part of that group should be able to write to the directory and change files in the directory.

Also doing this way everybodies primary group must be the same. If that is not possible then you might want to run a script for the chown and chmod whenever a new file is placed in the directory. I'm not sure if this is possible I'm not very good at scripts yet.

Last edited by JayCnrs; 06-07-2003 at 07:12 PM.
 
  


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
what is uid and gid rmanocha Linux - Software 9 08-18-2008 11:03 PM
Set UID hinetvenkat Linux - Security 4 06-08-2005 03:50 AM
FREEBSD5.3 platform: PHP setcookie() successful, but $uid = $_COOKIE['uid']; fail tclwp Programming 1 03-30-2005 08:05 PM
how to change UID linuxidiot2 Linux - General 2 07-30-2004 04:17 PM
What is UID mapping? darai Linux - Newbie 2 06-22-2004 11:53 AM

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

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