0

So on a linux server, I was recently made as an admin, and I have writing rights to manage and write data on the server. However, I have to sudo su in order to do this.

When I try to use an FTP client (such as Filezilla), it is not recognizing that I have writing rights, and any directory uploads I try to push up is denied. When I had to push a single file up, it accepted.

I tried changing the directory permissions to 775, and had nothing come out of it.

Thank you! Any help is appreciated!

Edit: (Originally on stackoverflow before Kenster pointed me this direction.)

1 Answer 1

1

This is because your FTP user is by itself not root. The FTP server does not know that you have permission to do this, and the FTP protocol doesn't have a mechanism for sending an su request.

A workaround is to upload the folder with your normal user, but to your users home directory. Then you shell in and sudo su, and then copy the folder to where you actually want it. Be sure to chown the folder to the correct owner afterwards, tho.

Your approach of changing the permission to 775 could work, provided that your user is the same group as whoever owns the folder you're uploading to.


PS: Because of safety and security, you generally don't want to allow people to log in as root directly, be it via FTP or SSH.

2
  • That makes sense as to why I have my own user directory. I could not understand that until you explained something. I'll give it a shot and report back. :) Thanks!
    – MJV
    Jul 15, 2016 at 13:32
  • @Techgirl-52 Basically, it goes like this: Everyone has their own user. In addition, there is the root-user that has all rights. Some users are allowed so sudo su to become root.
    – Jarmund
    Jul 15, 2016 at 13:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .