LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-23-2008, 01:53 AM   #1
shipon_97
Member
 
Registered: Oct 2005
Location: Bangladesh
Posts: 504

Rep: Reputation: 31
Question user command problem !!!


Dear Friends ,

Can u plz give me the following answer :

1)

In the following example :
[root@rptsvr ~]# groups paul
paul : alice sysadmin

In the above example How can I understand , what is the primary group and secondary group of the user 'PAUL'.


2)

If I make a change like following :

"usermod -G mygroup paul"

Then now, how can i undo this change ?
 
Old 08-23-2008, 04:11 AM   #2
tungvs
Member
 
Registered: May 2008
Distribution: Centos; Ubuntu; Fedora
Posts: 98

Rep: Reputation: 15
1. In my opinion, the first one is the initial group (primary group, as you say)
2. No idea. I think you have to use "usermod -G <group_list> paul" once more time.
 
Old 08-23-2008, 05:01 AM   #3
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
1. Primary group for user paul is always paul. alice and sysadmin are supplementary groups.
2. By douing this you deleted user paul from alice and sysadmin groups, and added it to mygroup group. Linux don't remember your previous status, so you're not able to simply undo change - you should assign an old grouplist to user paul by hands.
 
Old 08-24-2008, 04:03 AM   #4
tungvs
Member
 
Registered: May 2008
Distribution: Centos; Ubuntu; Fedora
Posts: 98

Rep: Reputation: 15
Quote:
Originally Posted by Samotnik View Post
1. Primary group for user paul is always paul. alice and sysadmin are supplementary groups.
It's not "always", indeed. You can change paul's primary group by using "usermod -g <primary_group> paul"
 
  


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
Adding user creating command not found problem Geetha S R SUSE / openSUSE 3 01-17-2006 07:20 AM
problem in running the command as a normal user junaid18183 Linux - General 2 06-25-2005 06:27 AM
user can use command.. bruse Mandriva 2 04-12-2005 07:21 AM
what is the command to make a user change their password after creating a new user? naweenio Linux - Newbie 7 01-05-2005 07:07 AM
User Login Problem: "command not found" unless root! DreameR-X Linux - General 15 12-21-2004 11:27 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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