can someone shed some light on this issue

I've set up and installed vsftpd. Created a user ftp-user and created a home directory, so they can log in, and just have access to drop their files here.

>> sudo useradd -d /home/ftp/ftp-user -m ftp-user

This works fine, user successfully logs in over ftp, uploads a file.

I now need to be able to access this ftp-user directory as another user say for example ubuntu. There is a script that runs as ubuntu, and I need to be able to access the directory to be able to grab the files and copy them across to other locations.

I tried to add ubuntu to the ftp-user group:

sudo usermod -a -G ftp-user ubuntu

Although, when trying:

>> whoami
>> cd ftp-user/
>> -bash: cd ftp-user/: Permission denied

Hope someone has an idea - Cheers in advance!

  • Can you post the output of ls -l /home/ftp/? – Khaled Feb 16 '12 at 12:09
  • Ah - my permissions weren't allowing me in to the directory, I've updated this. Will try logging in and out. - Thanks! – williamsowen Feb 16 '12 at 12:24
  • note that adduser ubuntu ftp-user is an easier to remember way to add the user ubuntu to the ftp-user group – stew Feb 16 '12 at 12:48

New groups are only picked up when the user logs in. Log the ubuntu user out then in again.

| improve this answer | |
  • running groups in a shell will list the current groups for that shell. – stew Feb 16 '12 at 12:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.