SFTP Configuring multi-user permissions

Source: Internet
Author: User

SFTP configuration Multi-user rights   work needs, users upload files to the directory, with FTP is not too safe, choose SFTP. Let the user in their own home directory activities, can not SSH to the machine to operate. Start working under  . To view SSH version ssh-v, my system is CentOS6.4 SSH version is 5.3 (greater than 4.8) no problem.  0, create user directory root permissions create user and genus Group are root   mkdir  -p/opt/sftp/dir1/{upload,public} 1, create Groupadd Sftp  2. Create User-s/sbin/nologin  -g sftp davis        user-s/sbin/nologin-g sftp davis1 3, creating da Vis password     passwd Davis or Echo davis:123456|chpasswd   passwd davis1 4, modify Sshd_config file & nbsp   #Subsystem      sftp    /usr/libexec/openssh/sftp-server (commented out) Add the following line Subsystem       SFTP internal-sftpmatch Group  sftp        chrootdirectory/opt/sftp/dir1  &N Bsp     Forcecommand    internal-sftp           x11forwarding no  &nbs P     allowtcpforwarding No restart sshd/etc/init.d/sshd restart 5, give directory subordinate permissions      chown Davis:sftp/opt/sftp/dir1/upload   chown davis1:sftp/opt/sftp/dir1/public   chmod  /opt/sftp /dir1/upload   chmod 700/opt/sftp/dir1/public 6, will upload to Davis users

SFTP Configuring multi-user Permissions

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.