Ashoori Group

Ashoori Group | Homepage

  • Increase font size
  • Default font size
  • Decrease font size

Adding a new user on electron

Become root on electron.

There is a script in root's home directory called "adduser".  Run "./adduser newusername".  Don't forget the ./ or it will run Ubuntu's native adduser program.

You will be prompted for "sn" (surname), "gn" (given name) and a password.

All authentication for this new user on other lab machines should be handled by LDAP, so there is no need to duplicate this user on the other machines.

Here are the contents of /home/root/adduser in case it gets corrupted:

if [ -z "$1" ] ; then
echo Usage: adduser username [uid
echo Adding user $1
if [ -z "$2" ]; then
smbldap-groupadd -a $1  # Add the user's group to both unix and samba
smbldap-groupadd -g $2 -a $1
echo "smbldap-groupadd DONE"
ldapadduser $1 $1 $2      # Add the user, including setting email up.
echo "ldapadduser DONE"
smbldap-usermod -a $1
echo "smbldap-usermod DONE"   # Modify the user to have a Samba account.
smbpasswd $1            # Set the users password.

In order to perform measurements the user must be part of the gpib and dialout groups on local machines. The way to accomplish this is to add them to the src group on electron. As root:

usermod -G src NEWUSERNAME