Operating System - HP-UX
1835213 Members
2331 Online
110078 Solutions
New Discussion

Re: Copying Files from Unix to windows machine

 
Chakravarthy_1
Occasional Advisor

Copying Files from Unix to windows machine

Hi,
I need to copy files generated on unix machine to windows machine. This showld be done thru a shell script. The unix machine is installed with Openssh.Pls let me know How can i do this.

bye.
14 REPLIES 14
Arunvijai_4
Honored Contributor

Re: Copying Files from Unix to windows machine

Hi,

You need to automate it using FTP. Check this thread for more information : http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=101940

-Arun
"A ship in the harbor is safe, but that is not what ships are built for"
Peter Godron
Honored Contributor

Re: Copying Files from Unix to windows machine

Hi,
logical steps:
ftp -n ip-address
user usr-name usr-pwd
put file
bye

You may also want to consider the unix2dos facility to make the UNIX file DOS compatible.
Jaime Bolanos Rojas.
Honored Contributor

Re: Copying Files from Unix to windows machine

Chakravarthy,

Also there are other methods to the the copying of files:

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1016568

Regards,

Jaime.
Work hard when the need comes out.
Chakravarthy_1
Occasional Advisor

Re: Copying Files from Unix to windows machine

Hi,
Since i am using secured shell, i am not able to use ftp. How can it be done over a secured shell and what are the prerequistes need to set up at windows machine.


Bye.
Marvin Strong
Honored Contributor

Re: Copying Files from Unix to windows machine

with ssh setup the ssh-keys on the windows host for the user, then you can use ssh to copy the files.
Chakravarthy_1
Occasional Advisor

Re: Copying Files from Unix to windows machine

Hi,

Do i need to install Openssh server on windows machine. Also can you give me some brief steps of how to set up ssh-keys on windows machine.


Bye.
Marvin Strong
Honored Contributor

Re: Copying Files from Unix to windows machine

yes the windows machine will need ssh installed.

then create a user on the windows server.
add the unix users public key to the windows users authorized_keys file.

that should be it. don't think I left out any steps.
Jaime Bolanos Rojas.
Honored Contributor

Re: Copying Files from Unix to windows machine

Chakravarthy,

Ok, this thread will give you links to download software that you need, it open your door to other options, very completed information.

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=995411&admit=-682735245+1155211289033+28353475

Also this site is good to find for info on configuring the whole thing:

http://www.openssh.com/windows.html


Regards,

Jaime.
Work hard when the need comes out.
Chakravarthy_1
Occasional Advisor

Re: Copying Files from Unix to windows machine

Hi,
I installed Winsshd on Windows machine and tried to connect to my machine. Its able to connect to the machnine but failing to logon to the machine.

I tried to connect using sftp with guest user on to my local machine but its throwing
Permission denied, please try again.
pls tell me if anything need to be set.

Bye.

IT_2007
Honored Contributor

Re: Copying Files from Unix to windows machine

Chakravarthy,

Otherway to copy files from windows is just download putty from http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html and it is just a binary file. Then go to command line on windows, c:\cd program files\putty, then look for psftp.exe which is basically does same ftp functions.

Thanks,
Srini
Michael Bush
Occasional Advisor

Re: Copying Files from Unix to windows machine

Not sure if CIFS would apply here or not, but I have had some success in porting files from a UNIX system to a Windows system by installing the CIFS client on the UNIX system and mounting the Windows system as described in the following URL:
http://www.docs.hp.com/en/B8724-90044/ch02.html?btnPrev=%AB%A0prev
Chakravarthy_1
Occasional Advisor

Re: Copying Files from Unix to windows machine

Hi,

I installed Winsshd on windows and able to connect to the machine from unix. Now i need to automate this process. I need to know where should i put the public key in the windows directory and what the permissions should be for the files. Pls guide me with some breif steps for doing this.


Bye.

rmueller58
Valued Contributor

Re: Copying Files from Unix to windows machine

I use CIFS mount points on my unix box to mount the Windoze share as a directory on my unix box.

CIFS simply makes a Windows box look like an NFS mount point,

Create a directory on your unix box you what to mount,

Put an entry in your /etc/fstab for the mount point

Make the Share available on the Windoze box

mount the directort.

Then copy files at will to and from the mount point in crontab

I use Fedora FC4 or FC5 as my primary linux boxes to perform the "duty" I use Webmin to manage the File System mounts.

Anshumali
Esteemed Contributor

Re: Copying Files from Unix to windows machine

Try SFTP over SSH
Dreams are not which you see while sleeping, Dreams are which doesnt allow you to sleep while you are chasing for them!!