Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I just installed tuxracer, it gives me this output
Code:
* Remember, in order to play games, you have to
* be in the 'games' group.
* See the usermod(8) manpage for more information.
* If you had the game installed before please reset
* the data_dir variable in ~/.tuxracer/options
>>> Regenerating /etc/ld.so.cache...
* Caching service dependencies...
I did do man usermod, could you dumb it down a little for me.
If you do that games will be the only group
the user will be in. Probably not what you want.
Youd have to check which groups the user
already is in, and add those to your list, too.
Alternatively, just manually edit /etc/groups
locate the line that starts with games, and
append the user to it ... if there's currently
NO users, just type his name, if there already
are some, append him using a , before his name.
this will accomplish the same thing as manually editting /etc/group. caveat - both the user and group must already exist.
also, the new group info will not take effect until that user logs in again at through a tty terminal(logging back in to KDE or using 'su' is not enough).
Last edited by Tramontane; 12-04-2003 at 02:09 PM.
I can't speak for slackware as my experience so far has been limited to debian. adduser can also be used to add users to a system, so I guess the ability to modify group members is just a little extra functionality. It seems that it's just a perl script that makes calls to useradd and it's ilk.
so here are the relevant parts of that script
Code:
NAME
adduser, addgroup - add a user or group to the system
SYNOPSIS
adduser [options] [--home DIR] [--shell SHELL] [--no-cre_
ate-home] [--uid ID] [--firstuid ID] [--lastuid ID]
[--ingroup GROUP | --gid ID] [--disabled-password] [--dis_
abled-login] [--gecos GECOS] user
adduser --system [options] [--home DIR] [--shell SHELL]
[--no-create-home] [--uid ID] [--group | --ingroup GROUP |
--gid ID] [--disabled-password] [--disabled-login]
[--gecos GECOS] user
adduser --group [options] [--gid ID] group
addgroup [options] [--gid ID] group
adduser [options] user group
Code:
printf _("Adding user %s to group %s...\n"),$existing_user,$existing_group
if $verbose;
&invalidate_nscd();
# FIXME - the next line has a race condition.
#&systemcall('usermod', '-G',
#join(",", get_users_groups($existing_user), $existing_group),
#$existing_user);
&systemcall('gpasswd', '-M',
join(',', get_group_members($existing_group), $existing_user),
$existing_group);
#&systemcall('gpasswd', '-a',$existing_user,$existing_group);
&invalidate_nscd();
print _("Done.\n") if $verbose;
exit 0;
so maybe if your distribution has the gpasswd program(which is binary, so not script) you could look into that. But I guess at this point it's easier to just edit the files by hand anyway.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.