How to connect as root using WINSCP – Ubuntu
In Ubuntu and other Linux distribution the “root” user is not directly accessible with a login operation without first doing an intermediate login with an unprivileged user.
Luckily, you can configure WinSCP to log in automatically from an unprivileged user into the “root ” user, by following these simply steps:
- log into the system and become “root” via su or sudo;
- launch the command “visudo“and configure it to allow other users to became “root” without a password by adding the following line;
user ALL = (ALL) NOPASSWD: ALL
the string “user” must be changed with the name of your regular unprivileged user;
- Finally, to save and exit visudo (vi editor), enter the command;
- Then change the following option into the WinSCP program: “Environment>> SCP >> Shell” from “Default” in;
sudo su –
Now try to login with WinSCP, you will be logged in directly in as “root”.