I inherited a linux server and I am attempting to access SFTP for a specific user. I can access a shell with no issues using an admin account "admin" and I can also access the filesystem with Filezilla using a public rsa key.

I need to write files to a directory that is owned by user-ftp. I reset the user-ftp password and can access everything for that user via shell with su, but can't seem to access sftp through Mozilla. I can't find a public key for that user, but I know the previous admin was uploading files with that user.

I looked in ~/ and their is no .ssh. I would appreciate any help tracking down how the current access is configured.


This could be a lot of things.

sftp only has two configuration options - where and what to log. You should enable that:


Subsystem sftp /usr/lib/openssh/sftp-server -f auth -l DEBUG

Restart ssh server (WARNING - easy to lock yourself out of a remote system here!)

service ssh restart

Then monitor /var/log/auth while trying to log in:

tail -f /var/log/auth

My suspicion is that your predecessor didn't use sftp, but instead rsync over ssh which can be invoked in such a way to sudo into the target account.

rsync -Pav -e "ssh" --rsync-path="sudo -u user-ftp rsync" \
   $SOURCE \
| improve this answer | |
  • I appreciate the input and am giving you credit because you led me to the eventual answer. I found a proftpd log (I knew it was installed, but it wasn't running, so I didn't look further into it). It turns out he was using plain ftp (I tested it out). I'm not sure if he was stopping the service or what. Appreciate the help. – kakridge Dec 24 '14 at 2:44

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.