码迷,mamicode.com
首页 > 系统相关 > 详细

ubuntu adduser && set smb

时间:2016-03-18 16:10:48      阅读:194      评论:0      收藏:0      [点我收藏+]

标签:

1) sudo apt-get install gedit samba

 

2) sudo groupadd dev

root@iwgame:~/test# cat batch_adduser
#! /bin/bash

set -x

for i in `seq 2 9`;
do
  u_name="public$i"
  if [ -n $u_name ]
  then
    useradd -d "/home/$u_name" -m $u_name -g dev
    echo $u_name:$u_name | chpasswd
    echo "Done"
  fi
done

 

3) sudo visudo   : /etc/sudoers

%dev ALL=(ALL) ALL

public2 ALL =(ALL) ALL 

 

4) cat /etc/apt/source.list

###### Ubuntu Main Repos
deb http://ftp.sjtu.edu.cn/ubuntu/ precise main restricted universe multiverse
###### Ubuntu Update Repos
deb http://ftp.sjtu.edu.cn/ubuntu/ precise-security main restricted universe multiverse
deb http://ftp.sjtu.edu.cn/ubuntu/ precise-updates main restricted universe multiverse

 

ubuntu adduser && set smb

标签:

原文地址:http://www.cnblogs.com/nancy0517/p/5292367.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!