misermice
asked on
WinSCP access to SUDO user
I have a sudo user account in my system.
We use it to carry on common operations. More than one user has sudo user privilleges.
To access sudo user what i do is
1. Putty --> log in with my userID n pwd
2. Sudo su - sudouser's_ID
3. Prompt's for pwd : Enter my PWD (same PWD as for my userID)
4. ls... I am at sudo users hoem directory.
Life is good.
But when i have to copy something from my userID's hoem directory to sudouser's home directory
I have to use cp commands...
When i have a lot of file transfer to do ..i cnat do all of that in putty.
So i need to know HOW CAN I LOG IN INTO WINSCP using this SUDO account.
I wanna see all those direcories in WINSCP.
in WINSCP home i do have sudouser's directory next to mine, along with a folder for each user.
But when i try to open sudouser's directory, it shows me nothing there.
When I try to create a new session in WINSCP giving the user name of sudouser and my password..
again a new window opens with title
"Server Prompt" asking for password.
I looked online and found two links that i belive are talking about the same issue
you can go through them if you wnat
http://winscp.net/eng/docs/faq_su#use_sudo_on_login
Another link has teh following content
"
I fought with this today and came up with the following solution:
Add a line to your sudoers file:
username ALL=NOPASSWD: /usr/lib/openssh/sftp-serv er
Then in the SFTP setup section of WinSCP edit the session SFTP server:
sudo /usr/lib/openssh/sftp-serv er
Boom, root access to file system via WinSCP.
HTH,
Clint
"
The above comment was found here http://winscp.net/forum/viewtopic.php?t=3046
But i am not bale to comprehend it. Coz i dont know if thats the right way or if it is teh right way i donno how to do it.
What is sudoer's file ?
Thank You
We use it to carry on common operations. More than one user has sudo user privilleges.
To access sudo user what i do is
1. Putty --> log in with my userID n pwd
2. Sudo su - sudouser's_ID
3. Prompt's for pwd : Enter my PWD (same PWD as for my userID)
4. ls... I am at sudo users hoem directory.
Life is good.
But when i have to copy something from my userID's hoem directory to sudouser's home directory
I have to use cp commands...
When i have a lot of file transfer to do ..i cnat do all of that in putty.
So i need to know HOW CAN I LOG IN INTO WINSCP using this SUDO account.
I wanna see all those direcories in WINSCP.
in WINSCP home i do have sudouser's directory next to mine, along with a folder for each user.
But when i try to open sudouser's directory, it shows me nothing there.
When I try to create a new session in WINSCP giving the user name of sudouser and my password..
again a new window opens with title
"Server Prompt" asking for password.
I looked online and found two links that i belive are talking about the same issue
you can go through them if you wnat
http://winscp.net/eng/docs/faq_su#use_sudo_on_login
Another link has teh following content
"
I fought with this today and came up with the following solution:
Add a line to your sudoers file:
username ALL=NOPASSWD: /usr/lib/openssh/sftp-serv
Then in the SFTP setup section of WinSCP edit the session SFTP server:
sudo /usr/lib/openssh/sftp-serv
Boom, root access to file system via WinSCP.
HTH,
Clint
"
The above comment was found here http://winscp.net/forum/viewtopic.php?t=3046
But i am not bale to comprehend it. Coz i dont know if thats the right way or if it is teh right way i donno how to do it.
What is sudoer's file ?
Thank You
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.