[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 663
  • Last Modified:

How to copy information from windows to linux using SSH

HI

I have Linux CentOS server virtualized by virtualbox  and running over a windows server 2003 in which there are some files that  I need to copy to Linux Server using SHH, but I don't know how, is that possible?

I have putty.exe in windows in order to connect it from windows to linux.

Regards.
0
dimensionav
Asked:
dimensionav
8 Solutions
 
Jordan MedlenCommented:
You can use filezilla to do this.

https://filezilla-project.org/

It is an FTP client, so it works the same way. I use this as my client of choice to make similar file transfers.
0
 
NickUpsonCommented:
you can also use winscp

http://winscp.net/eng/index.php

it can use ftp or scp (based on ssh)
0
 
piwowarcCommented:
Hi

SCP based copy is the simplest as guys already stated.  You have more choices though. If you have Virtual Box Guest Additions installed in this linux VM you can map folder of physical machine to VM. Linux distributions normally support SMB file sharing as well so you can either create share in VM guest or map physical machine into location of VM.

Bot those solutions have benefit over SCP over SSH. If you plan to use it in production it's way safer than openining machine via SCP (user has all filesystem access by default and way more difficult to restrict it).

Choice is yours my friend. Your usage case should give you answer which solution will be best for you.

Regards
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
tmx84Commented:
scp c:\directory\* username@ip or hostname:/directory

Here is the SCP Command if you are using Putty...

the first directory is obviously local and the second is the ssh remote computer.. you would just reverse this to do it the opposite way.. you could copy files from linux to local like this as well.  If you use \* it will copy everything in the directory, or you can specify the file name...

Here are more examples if you need them...

http://www.hypexr.org/linux_scp_help.php

Otherwise the above options will work as well... Using an SFTP will probably be the easiest.. but if you would like to venture out and use Putty, you can!
0
 
farzanjCommented:
You can use WinScp client.

http://winscp.net/eng/index.php

It is easy to use drag and drop but if I understand you correctly, you don't even need that if the VM (VM Box) resides on the same machine then all you need is to share a folder between the VM and the host machine.

For virtual box, all you need to do is:
Machine --> Setting menu

Select shared folder.  And put a folder name on the Windows side.

For the linux side, you need to install the VM Box package so that Linux mounts it.  From the "Devices" menu, select "Insert Guest Additions CD image".  This should create some package on your Desktop in Linux and you have to follow instructions to install it.  Once done, this is a much better way to share a folder between host and guest.
0
 
MazdajaiCommented:
You can use pscp from the putty suite . It has been answered here.

http://www.experts-exchange.com/OS/Linux/Q_28209471.html#a39398859
0
 
Sudeep SharmaTechnical DesignerCommented:
Another method would be rsync, that would help in case if you need to schedule the copy/move of file and also in case of backups.

For rsync from Windows to Linux you can use Ultra copier which is not only replacement for windows copy move feature but it also has rsync module which could be used to copy the files to Linux.

http://ultracopier.first-world.info/
0
 
NARANTHIRANCommented:
U can mount the Windows directory  to Linux system  and copy the files in ssh mode..

Try the following to command to mount and copy the files.

[root@masterdns]# mount -t cifs //192.168.1.100/Share -o username=username, password=password /var/window

[root@masterdns]# Cp filename  newfilename
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now