Operating System - HP-UX
1833268 Members
2890 Online
110051 Solutions
New Discussion

ftp a patch file from desktop to Unix server?

 
Jasen Rogers_1
Occasional Advisor

ftp a patch file from desktop to Unix server?

This should be easy, but I'm not having much luck so far...

I have a 500mb hp gold patch pack on the C drive of my PC, and would like to get it out to our HPUX server.

ftp and put should work, right?

ps - I'm not very good with ftp

Thanks ~
11 REPLIES 11
Rita C Workman
Honored Contributor

Re: ftp a patch file from desktop to Unix server?

Always works for me !

Rgrds,
Rita
Bob E Campbell
Honored Contributor

Re: ftp a patch file from desktop to Unix server?

Unix and MS* differ in how a line should end. If you transfer in binary mode each way you should be OK. If you transfer in ASCII mode each way it will modify the file twice and you should be OK. If you use differing modes the shar archive might not be usable. Look to the dos2ux(1) man page for more information.

Bob
A. Clay Stephenson
Acclaimed Contributor

Re: ftp a patch file from desktop to Unix server?

Just make sure that when you downloaded the file to your PC from the website and when you ftp to your UNIX box, all transfers are done in BINARY mode. Specifically, before you issue the ftp put (or get) command, issue a "BIN" ftp command.
If it ain't broke, I can fix that.
Jasen Rogers_1
Occasional Advisor

Re: ftp a patch file from desktop to Unix server?

Here's what I've been trying:

On windows PC, start / run /cmd

Type dir, to make sure I'm in the folder that has the file.

ftp _unix_server_ip

enter uname and password

cd to where I would like to have the file paced

bin

then

put _filename_

But it's not working...

Feels like I'm on the wrong path here.

A. Clay Stephenson
Acclaimed Contributor

Re: ftp a patch file from desktop to Unix server?

That should be working fine as long as this user has write permissions in this directory or is not performing an operation forbidden by the ftpaccess file. Perhaps, you could define "not working" a little better. You might issue the "hash" command which will output a '#' character after every 1KiB has been transferred.
If it ain't broke, I can fix that.
Bob E Campbell
Honored Contributor

Re: ftp a patch file from desktop to Unix server?

Are we talking about a patch shar(1) file or a serial depot file? Use view to take a peek at the file. If you see "This is a shell archive" you have a shar(1) file. If you see a "^M" at the end of the line you have some ASCII translation problems that can be fixed with dos2ux(1).
If you see a jumbled line beginning with "catalog/INDEX" you have a serial depot. In this case try the command "tar tvf filename". All you care about is that a list of files flows past and exits cleanly. Any failure here means you should grab a new copy from HP or media.

For the shar(1) file, use the command "sh file" to expand into a .depot and .text file. The .depot file can be swcopy'd or swinstall'd (once dependencies are accounted for).
Jasen Rogers_1
Occasional Advisor

Re: ftp a patch file from desktop to Unix server?

It's a .depot file, around 500mb...
James R. Ferguson
Acclaimed Contributor

Re: ftp a patch file from desktop to Unix server?

Hi Jasen:

So, exactly what isn't working for you?

Have you transferred the depot (file) from your PC to your HP server?

If so, are you having trouble with the file once it is HP-UX resident?

Regards!

...JRF...
Bob E Campbell
Honored Contributor

Re: ftp a patch file from desktop to Unix server?

Is the failure from the ftp transfer failing as Clay discussed or from an attempt to install the bundle after the transfer? Assuming the problem is not in the ftp, check for corruption using the command:

# tar tvf GOLDQPK11i_B.11.11.0612.459.depot

Or similar. If that is the bundle in question, the cksum should be:

# cksum GOLDQPK11i_B.11.11.0612.459.depot
3982417177 532346880 GOLDQPK11i_B.11.11.0612.459.depot

If these checks are wrong you must download the bundle again from HP using binary mode.

Jasen Rogers_1
Occasional Advisor

Re: ftp a patch file from desktop to Unix server?

I can't get it to transfer to the unix box.

After the put command, the file name will show up on the server, but it will be 0kb.

- OK, it just went through. Transfer complete.

Something I did on the windows machine must have deleted the contents of the file, but kept the name, and I was unknowingly trying to transfer that worthless file. Strange.

But it finally went through, thanks all for your help.
Jasen Rogers_1
Occasional Advisor

Re: ftp a patch file from desktop to Unix server?

Not sure what happened, but the problem is solved. Thanks.