Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Wrong user group
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
odegard
Guru
Guru


Joined: 08 Mar 2003
Posts: 324
Location: Trondheim, NO

PostPosted: Sat Sep 16, 2006 1:34 pm    Post subject: Wrong user group Reply with quote

Ok, this is very embarrassing! I just realised that when I made my non-root user (a few days ago after a reinstall) I made some mistake. I'm not in the user group, rather, I'm in my own group :oops:

It looks like this:
odegard:odegard
instead of
odegard:users

How can I fix this? I guess it's something simple, like modify my existing user, then chown -R odegard:users * in my home-dir, but I'd like some input anyway. (I must've been pretty tired)
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Sat Sep 16, 2006 2:32 pm    Post subject: Reply with quote

As root, do the following:
First fix the permissions on your home directory via
Code:
find ~odegard -group odegard -exec chgrp users \{\} \;
then either edit /etc/group manually (errorprone, watch for syntax errors) or remove yourself from the old group and add yourself to the new group via
Code:
gpasswd -d odegard odegard
gpasswd -a odegard users
Log off all of odegard's sessions, and if you're running X stop and restart xdm (or just reboot).
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
odegard
Guru
Guru


Joined: 08 Mar 2003
Posts: 324
Location: Trondheim, NO

PostPosted: Sat Sep 16, 2006 3:25 pm    Post subject: Reply with quote

Great, thanks :)
Back to top
View user's profile Send private message
moocha
Watchman
Watchman


Joined: 21 Oct 2003
Posts: 5722

PostPosted: Sat Sep 16, 2006 3:26 pm    Post subject: Reply with quote

Most welcome.
_________________
Military Commissions Act of 2006: http://tinyurl.com/jrcto

"Those who would give up essential liberty to purchase a little temporary safety deserve neither liberty nor safety."
-- attributed to Benjamin Franklin
Back to top
View user's profile Send private message
Paapaa
l33t
l33t


Joined: 14 Aug 2005
Posts: 955
Location: Finland

PostPosted: Sat Sep 16, 2006 6:01 pm    Post subject: Re: Wrong user group Reply with quote

odegard wrote:
Ok, this is very embarrassing! I just realised that when I made my non-root user (a few days ago after a reinstall) I made some mistake. I'm not in the user group, rather, I'm in my own group :oops:


I don't think you did any mistake. This is the default behaviour (or a bug?): there will be a group called "username" and "username" will get added to it. See this:

https://forums.gentoo.org/viewtopic-t-483035-highlight-.html

As you can see, the home directory will have "username" as the group.
Back to top
View user's profile Send private message
odegard
Guru
Guru


Joined: 08 Mar 2003
Posts: 324
Location: Trondheim, NO

PostPosted: Sun Sep 17, 2006 9:41 am    Post subject: Reply with quote

Hm, thanks, so I didn't do anything stupid afterall. I did what moocha proposed and will consider the state of things later :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum