
FTPサーバとして proftpd を立てているんですけど、新しいユーザを追加するとき、いつも、どうやるんだっけ?と悩むので、自分用のメモ。
 
1.proftpdの環境
/etc/proftpd/ /etc/proftpd/proftpd.conf /etc/proftpd/ftpd.group /etc/proftpd/ftpd.passwd
 
2.グループの追加
  基本、1ユーザ=1グループにしているので、まずグループを追加します。
  グループIDをどこまで使ったかは、cat /etc/proftpd/ftpd.group で。
ftpasswd --group --file=/etc/proftpd/ftpd.group --name=group_name -gid=5003
 
3.ユーザの追加
ftpasswd --passwd --file=/etc/proftpd/ftpd.passwd --name=user_name --uid=5003 --gid=5003 --home=/home/www/user_root --shell=/bin/bash
 
4.アクセス環境の設定
e /etc/proftpd/proftpd.conf
DefaultRoot    /home/www/user_root    user_name
  AllowOverwrite on
  Umask 000
  
    AllowAll
  
5.サービスリスタート
/etc/init.d/proftpd restart


