As soon as I log into Winscp session, I need to sudo as another user (such as oracleuser)
So tried a couple of different things:
1) in Advanced settings, Environment > SFTP I enter:
sudo -u oracleuser -i -c /usr/libexec/openssh/sftp-server
However, I get the error message:
Cannot initialize SFTP protocol. Is the host running a SFTP server?
If I only use /usr/libexec/openssh/sftp-server it works - because that's the path to our sftp server.
What am I doing wrong?
2) So tried this other way:
After I login as my userid, I select Commands > Open in Putty. Then I execute sudo -u oracleuser -i. I am able to sudo in Putty, but my Winscp session ignores that I sudo. (I know b/c It does not allow me access directories that oracleuser allows).
Please help. I do not have need to enter password when I sudo -u oracleuser -i