Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations sizbut on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Deleting files remotely with Putty?

Status
Not open for further replies.

jlong07

Technical User
Nov 8, 2002
56
US
I use putty to connect to a linux box running ssh1 that is home to my appache web server. I have just started playing around with this, and I can't seem to figure out how to delete files on the server. I have read all the documentation I can find, and all I come up with is how to do it with psftp. Well, psftp only works with ssh2. So, how can I use putty or pscp to delete files remotely through ssh1.
 
Putty creates a shell on the remote system using the permissions of the user. You may need to su to root to have the permission to delete the files. Pscp is nothing more than putty's version of scp run at a command prompt (DOS). You can copy files back and forth as long as the pscp user has the permission to do so. You may need to create an identity with putty-keygen and cat that file into the identity.pub on the remote machine in the /root/.ssh directory. That will use the root permissions for file copying and also for putty to eliminate the su step.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top