[linux] shell脚本编程-ubuntu创建vsftpd服务

 1.  useradd -s /bin/bash -m 用户名 ,  创建用户,自动创建家目录 , 设置登录shell

 2.  echo 用户名:密码 | chpasswd ,非交互式设置密码

 3. echo -e "userlist_deny=NO\nuserlist_enable=YES\nuserlist_file=/etc/allowed_users\nseccomp

> /etc/vsftpd.conf 往配置文件中追加配置 保留换行符

 4. sed '/$NAME/d' /etc/ftpusers"  , 修改某项配置的值

 ubuntu 系统 16.04

#!/bin/ -e -s /bin/bash - $NAME:$PASSWORD | -get vsftpd - rs\nseccomp_sandbox=NO /etc/vsftpd.conf" -e _sandbox=NO> /etc/vsftpd.conf /etc/allowed_users > /etc/ /etc/ ;

相关文章

Centos系统之Shell编程基础知识
从Export理解Shell环境和变量生存期
linux shell数组变量、类型及规则
Centos编程Shell基本工作原理方案
Centos操作系统编程之Shell 问答录
rsync-linux备份脚本