How to copy a file from my linux machine to remote window machine
I am able to copy the file from window machine to linux machine via pscp but i wanted to know is there any command by which i can copy the file from linux machine to windows machine.
Please help if anyone know about the same. Thanks in Advance.:) |
it depends on what is installed on windows. If you have shared a directory (and C$, D$ usually available) you can mount it on your linux and a simple copy should do the job.
|
Thanks pan64 for your rply .
So I cant use SCP to copy the file from linux server to window server ??Can you share me the steps how can i share the directory of window server and mount it to the linux server . NOTE: both linux and window server are remote . |
you can use scp if an scp server was installed on the windows side. I do not know anything about that. I suggest you to check:
http://www.cri.ch/linux/docs/sk0001.html http://www.howtogeek.com/168115/moun...ux-with-samba/ |
I think that the best general approach is to "bloom where you are planted." In other words, connect to the remote system using standard network file-sharing in a manner most-well supported by that host. Linux, Samba, etc. makes it easy to connect to a Windows shared network, and to participate fully in such a network as a true peer. Thus, you simply mount the share (logging-in to the Windows network unless it automagically recognizes you), and copy the files to-and-fro as you see fit. Exactly as you would do if you weren't (ick ...) using Linux. :)
|
I'd use shttpd to run a tiny web server on Linux, then use windows to download from it.
|
He doesn't need to run a webserver on linux. Linux already has ssh running. He already knows how to use pscp to copy files from windows to linux. He just needs to learn how to use pscp to pull files from linux to windows.
Instead of calling it like this Code:
pscp sourcefile user@host:targetdir Code:
pscp user@host:sourcedir/file targetfile |
Most Linux distros come with Samba client installed. Check your distro to find out whether it does. You do not need Samba server for what I will describe below.
If you run into any problems, post them to this thread, including any error messages you get. |
If you're initiating the transfer from the windows computer, winscp works very well.
|
The "putty" package on the Windows side is a good, reliable client. Yes, they prefixed the letter "p" to all of their command-names, which is actually rather annoying, but otherwise it's directly on-par with the Linux equivalents. Their SSH-agent is called "pagent." (Or is it the English word, "pageant?" I don't recall.) Anyhow, everything you need to do SSH from the Windows world, and I believe also to provide an SSH daemon on Windows, is all there.
|
If you can access the remote Windows machine using RDP, then you can use the '-r disk:' option to rdesktop (a Linux RDP client) to have a directory on your Linux machine appear in the Windows file manager.
|
I'm with fmattheus; just do pscp pull instead of a push; no need to use another tool or setup file sharing.
|
All times are GMT -5. The time now is 10:55 PM. |