Need to su or sudo!
Hi. I'm trying out ExpanDrive and so far it is much better than McFuse/Fussion. My question is: how can I do things that require sudo or su? For example, editing remote files on a FreeBSD server? Thanks.
5
people have this question
I have this question, too!
Tell me when someone answers.
The more people who ask this question, the more it gets noticed.
The more people who ask this question, the more it gets noticed.
-
Inappropriate?Unfortunately, the SFTP versions in current use don't support sudo or su, but there is a relatively painless solution from our end. If you need to specifically use sudo, you'll need to enable root access in your sshd_config on the server. Next, you can just create another drive in the manager connected to the same server but with your substitute username or root as login. It's not exactly the same as using sudo, but end result is.
-
Inappropriate?According to WinSCP:
Use sudo on Login
In some cases you may be able to use sudo command straight after login to change a user, before file transfer session starts.
FTP protocol does not allow this.
The SFTP and SCP protocols allow for this, but the actual method is platform dependant.
With SFTP protocol, you can use SFTP server option on SFTP tab of Login dialog to execute SFTP binary under different user. Under Unix/Linux with OpenSSH server, you can specify:
sudo su -c /bin/sftp-server
If WinSCP can sudo, it should be possible. -
Inappropriate?I'm not entirely sure what the "SFTP server option" refers to, but I think that's the same as what I suggested above. It's just logging into the server using the substitute username, which is effectively the same thing as using sudo.
-
Inappropriate?our current server doesn't allow direct root login but it does allow sudo. Whatever WinSCP does, it works and that's what I use right now but if SFTPDrive could support that, I would switch in a heartbeat.
-
Inappropriate?OK, I'll look into the sftp-server thing. Thanks for the tip!
Loading Profile...




