vsftpd user cannot put file on ubuntu EC2

0

I want to put files in vsftpd server directory.

I used this tutorial https://blog.e-zest.com/setting-up-sftp-server-on-amazon-ec2 but I cannot put files. I get the following error:

sftp> put sftp-test.txt
Uploading sftp-test.txt to /shared/sftp-test.txt
remote open("/shared/sftp-test.txt"): Permission denied

However, I can easily get files which have sftpuser group permissions. Is this because I sftp user should only be able to retrieve files, not put files? Or is some of the chown or chmod commands in this tutorial some what incorrect? I also tried adding the following lines in /etc/vsftpd.conf:

allow_writeable_chroot=YES
write_enable=YES

I restarted the vsftpd server but it didn't have any effect on being able to put files. I also logged into the vsftpd server using sftp command on mac: sftp myuser@<ec2-ip-address>

Anyone know how to resolve the put issue?

nealous3

Posted 2019-05-20T01:24:13.200

Reputation: 101

No answers