Link to home
Start Free TrialLog in
Avatar of cpatte7372
cpatte7372Flag for United Kingdom of Great Britain and Northern Ireland

asked on

Linux Binary File Conversion

Hello Experts

I need to ftp a file because when I run an installer I get the following output:

-bash-4.1$ ./DBConfig_RHEL_SAM_10_0_R5.bin
Preparing to install...
Extracting the JRE from the installer archive...
Unpacking the JRE...

gzip: /tmp/install.dir.3691/Linux/resource/vm.tar.Z: corrupt input. Use zcat to recover some data.
./DBConfig_RHEL_SAM_10_0_R5.bin: line 609: uncompress: command not found

gzip: /tmp/install.dir.3691/Linux/resource/vm.tar.Z: corrupt input. Use zcat to recover some data.
The included VM could not be uncompressed (GZIP/UNCOMPRESS). Please try to
download the installer again and make sure that you download using 'binary'
mode.  Please do not attempt to install this currently downloaded copy.

So, I need to ftp the file from my usb to the RHEL hard drive in order to make this work.

I'm currently running RHEL v6 and ftp is already installed. It has been suggested that I need both ftp client and server on the RHEL (which makes sense) .

Please be aware that this is all happening on the same platform.

The workstation name is localhost.localdomain.

Can someone please tell how to ftp from the ftp server to client on the same machine in order to get the file, DBConfig_RHEL_SAM_10_0_R5.bin to be recognized as a binary file -as copy and paste makes it an ascii file.


Avatar of omarfarid
Flag of United Arab Emirates image

if the file is on the same machine, then why you want to ftp it? you could use the cp command to copy from one location to another.

Any way, if the ftp it take place on the same server (linux machine), then run

ftp 0

use your username and password to login

then from the ftp prompt type


then you can get or put the file

Please note that if the file is not a binary file then ftp can not convert it to binary.
Avatar of cpatte7372



Thanks for responding.

At what level should I issue the ftp 0 command? Because I'm getting the response "command not found"
Avatar of omarfarid
Flag of United Arab Emirates image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial

How do I get to shell command prompt?
how do you login to your box? is it from console? if yes and you have graphical interface then you need to see how to run terminal application , this will give you shell command prompt
Avatar of skullnobrains

i do not know how you got that file on the USB key, but most likely you downloaded it to the USB key from a windows machine in ascii mode and corrupted it, so just forget about it.
copy+ paste is binary safe and would not corrupt the file so one of the previous operations did


when you see this "-bash-4.1$", you have a command prompt


just download it from whatever place you downloaded it it the first place using
of course replace the download url with the one you used oin the first place

Thanks for responding.

I need to copy the file from the usb stick to the linux workstation in binary mode. Are you suggesting that I issue the command 'wget DOWNLOADURL' while within linux? i.e.

bash-4.1$wget DOWNLOADURL


no, if you know the full url to the file from where you downloaded (e.g. then you can run from command prompt


are you able to get shell to run (as I mentioned before to run terminal application) commands?

Also, when you insert the usb stick into the linux box and it is mounted then you should be able to copy files from there to any location in your box

But again you need to get shell command prompt
you do not need ftp to copy a file from an USB stick to a local filesystem. the copy will ALWAYS be in binary mode, you cannot change that.

you need to understand that the problem you experienced is not because of the copy from usb to your local disk.

most likely the file that is on your usb key is already corrupted, so you can copy it in whatever way you want, or even run the install directly from the USB key, and it won't make a difference. it is also possible that your problem is completely unrelated to binary VS ascii mode.

try and explain where you got that file from. try and be clear about the point where you are sure the file was pristine. then describe your problem without jumping to your own conclusions. you'll bet much better help