Default files and settings for new users on most Linux distribution – Linux Ubuntu

2010-06-09 1 min read Linux
For most common distributions of Linux the default settings for the newly created user with GUI or useradd command is taken from the directory /etc/skel All the files (including the hidden files) are copied to the newly created users home directory. This can be used to modify the defaul .bashrc .vimrc and other such files in the users home directory. You can copy the files in ”/etc/skel” the files that you want to keep in the users home directory. Continue reading

Scripts to create logins from bash command – for creating multiple accounts

2010-06-09 1 min read Fedora Linux
Heres the script: cat «EOF > for i in `cat logins` ; do login=`echo ”$i”|awk -F”:” '{print $2}’`; comment=”`echo ”$i”|awk -F”:” '{print $1}’`”; gr=”`echo ”$i”|awk -F”:” '{print $3}’`”; echo ”login –» $login –Comment –» $comment –Group –»$gr –”; echo ”useradd -c ”$comment” -d /export/home/$login -m -g $gr -s /bin/bash $login” useradd -c ”$comment” -d /export/home/$login -m -g $gr -s /bin/bash $login done You would need to create file called logins to store the comment, login name and the group. Continue reading