Miscellaneous

  Home arrow Miscellaneous arrow Page 4 - Putty File Transfer Commands in SSH Pr...
MISCELLANEOUS

Putty File Transfer Commands in SSH Protocol
By: Codex-M
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 4
    2009-12-30

    Table of Contents:
  • Putty File Transfer Commands in SSH Protocol
  • Browsing web server files using Putty
  • Uploading and downloading files using the Putty Secure Copy Client
  • Transferring multiple files in one SSH command

  •  
     

    SEARCH CODEWALKERS

    TOOLS YOU CAN USE

    advertisement

    Putty File Transfer Commands in SSH Protocol - Transferring multiple files in one SSH command


    (Page 4 of 4 )

    Suppose you are going to upload the whole files (not just one) to your website root directory, follow the steps below:

    Step 1: In your Windows local path, put all your files inside a folder (for example say C:uploads). This folder contains all the files and inner folders that you need to upload to your server. Now using PSCP Putty, execute this command using a DOS prompt (following procedures similar to those in the previous section):

    C:ssh>pscp -P 22 -r c:uploads codexm@php-developer.org:html/

    Step 2: SSH will upload all files inside “uploads” to the root directory /html in your website server.

    To download an entire folder to your Windows C:downloads directory:

    C:ssh>pscp -P 22 -r codexm@php-developer.org:html/foldertodownloadatroot c:downloads

    Other useful SSH server administration commands (inside [] are variables) that can be executed by the putty.exe SSH client (not the PSCP):

    rmdir [foldername] -> deletes the directory in your server, must be empty first.

    rm [filenamewithextension] -> deletes one file.

    rm * -> deletes all files inside the folder

    Details on Putty file transfer in SSH can be found in this documentation. There is another page you can visit if you're looking for advanced UNIX-based SSH commands

    Important note: In a UNIX file path, use the forward slash (“/”), while in Windows, the file path uses the back slash (“”). This is clearly illustrated in the command line examples given in this article.


    DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.
    blog comments powered by Disqus

    MISCELLANEOUS ARTICLES

    - Oracle Database XE: Indexes and Sequences
    - Modifying Tables in Oracle Database XE
    - Oracle Database XE: Tables and Constraints
    - More on Oracle Databases and Datatypes
    - Oracle Database XE Datatypes: Datetime and L...
    - Oracle Database XE Datatypes: Character and ...
    - From Databases to Datatypes
    - Firefox 3.6.6 Released with Improved Plug-in...
    - Attention Bloggers: WordPress 3.0 Now Releas...
    - Reflection in PHP 5
    - Inheritance and Other Advanced OOP Features
    - Advanced OOP Features
    - Linux from Scratch V.6.6 Review
    - Linux Gaining in Strength
    - Install Slackware on Your Old PC


    © 2003-2012 by Developer Shed. All rights reserved. DS Cluster 6 - Follow our Sitemap