LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 11-15-2012, 01:26 PM   #1
carltonp
Member
 
Registered: Nov 2012
Posts: 69

Rep: Reputation: Disabled
converting file to binary issue


Hello Forum

This is my first posting and I'm really hoping that someone help me out.

Everytime I run a program in RHEL v6 I get a message that the downloaded file needs to be binary.

The workstation is currently standalone. It has been suggested that I ftp the file to RHEL workstation but it not currently networked.

Can someone please tell me if there is a workaround;

The following is the output after running the program:

-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.

Cheers

Carlton
 
Old 11-15-2012, 02:30 PM   #2
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,974

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Hello carltonp, welcome to LQ,

the message doesn't say that the downloaded file needs to be binary but that
Quote:
Please try to download the installer again and make sure that you download using 'binary' mode
an explanation is here. How has the file been downloaded?

Markus

Last edited by markush; 11-15-2012 at 02:31 PM.
 
Old 11-15-2012, 02:39 PM   #3
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,055
Blog Entries: 6

Rep: Reputation: 798Reputation: 798Reputation: 798Reputation: 798Reputation: 798Reputation: 798Reputation: 798
When you use "ftp" it has two modes - ASCII and binary. When you use ASCII it will try to make the file ASCII for YOUR operating system. DOS/Windows is different than UNIX/Linux as one uses Carriage Return/Line Feed [CR/LF] at the end of every line and the other uses only LF. There are also other minor differences but this is the main one. When you use binary mode transfer you tell ftp NOT to do any sort of ASCII translation from one platform to another so it transfers it exactly as it finds it.

You can tell ftp to do BINARY by typing "bin" at the ftp prompt before you do the get or put of the file.
 
1 members found this post helpful.
Old 11-15-2012, 02:45 PM   #4
carltonp
Member
 
Registered: Nov 2012
Posts: 69

Original Poster
Rep: Reputation: Disabled
Mensawter,

Thanks for responding.
The file is currently on a USB. As this is all occurring on the same platform, will I need to download the file from usb to the harddrive by installing an ftp server and client on same machine?

Cheers mate.
 
Old 11-15-2012, 02:54 PM   #5
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,974

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Probably it would be good to download the file on a Linux-computer.

Markus
 
Old 11-15-2012, 02:59 PM   #6
carltonp
Member
 
Registered: Nov 2012
Posts: 69

Original Poster
Rep: Reputation: Disabled
mark,

Is there a simple way of downloading the file from usb to the linux computer? The linux computer isn't currently networked. I just want to install and application for the moment.

Cheers

Carltn
 
Old 11-15-2012, 03:05 PM   #7
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,974

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Don't you have another Linuxcomputer available? then download it on the other computer, put it onto the USB-device and then from USB to the other computer.

Markus
 
Old 11-15-2012, 03:23 PM   #8
carltonp
Member
 
Registered: Nov 2012
Posts: 69

Original Poster
Rep: Reputation: Disabled
Markus

I have tried configuring a network connection with a manual ip address. However when I issue the command ifconfig I don't see the configurations.

I'm going to try and setup a network connection between the RHEL and another PC as there doesn't appear to be any other way of downloading file in binary?
 
Old 11-15-2012, 03:35 PM   #9
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,974

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Regarding to the logo at your last post you have a Mac-computer. When you have wget running there, you could download the file from there. simply use
Code:
wget ftp://pathtothefile....
where you have to insert the correct url for the binary file.

Markus
 
Old 11-15-2012, 04:44 PM   #10
carltonp
Member
 
Registered: Nov 2012
Posts: 69

Original Poster
Rep: Reputation: Disabled
Why do you say I'm running a mac-computer?
 
Old 11-15-2012, 07:52 PM   #11
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,396
Blog Entries: 2

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
You don't need to 'download' the file from the USB thumb drive. You simply need to copy it. It is very likely that when you plug the thumb drive into your Linux computer, the computer will automatically mount the thumb drive. You can either use the commandline to copy the file from the thumb drive to a suitable place on the hard disk, or you can use a filesystem browser to drag it around.
How did the file get on the USB thumb drive in the first place? If you put it there yourself somehow, can you repeat the process? It may have gotten corrupted in transit. Are you sure the thumb drive is of large enough capacity? If the thumb drive is formatted with a DOS filesystem (by default, most USB thumb drives are), is the file small enough to be accommodated by that filesystem?

--- rod.
 
Old 11-15-2012, 11:03 PM   #12
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,974

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
Quote:
Originally Posted by carltonp View Post
Why do you say I'm running a mac-computer?
because of the logo on the left hand bottom side of your posting. Now it seems that you've internet access with your RedHat machine, so you can download the file there.

Markus
 
Old 11-16-2012, 03:35 AM   #13
carltonp
Member
 
Registered: Nov 2012
Posts: 69

Original Poster
Rep: Reputation: Disabled
[QUOTE=theNbomr;4830442]You don't need to 'download' the file from the USB thumb drive. You simply need to copy it. It is very likely that when you plug the thumb drive into your Linux computer, the computer will automatically mount the thumb drive. You can either use the commandline to copy the file from the thumb drive to a suitable place on the hard disk, or you can use a filesystem browser to drag it around.
QUOTE]

Thanks for responding. Did you see the output in my question. It has been suggested that the only way to 'download' or 'copy' the file is by ftp'ing it in binary format. Unfortuantely, its not possible to do that with simple copy and paste from the usb stick - unless you have any other ideas?

Cheers
 
Old 11-16-2012, 08:12 AM   #14
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,396
Blog Entries: 2

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
Well, whoever said you need FTP to transfer a file from a USB drive to somewhere else in your filesystem is mistaken. FTP is used to transfer files from one host to another. Moving and copying files within a filesystem (as the USB thumb drive is when it gets plugged in) is done with cp and mv.
I asked how the file got on the USB drive. If it got there by downloading it from another host, then a binary mode file transfer would be required. Instead of using FTP, the more modern method would be to use scp, in which there needs to be no distinction paid to binary vs. text modes. All transfers are 'binary' mode.
--- rod.
 
1 members found this post helpful.
Old 11-16-2012, 08:51 AM   #15
markush
Senior Member
 
Registered: Apr 2007
Location: Germany
Distribution: Slackware
Posts: 3,974

Rep: Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850Reputation: 850
theNbomr, as I understood the OP downloaded the file with Windows. And Windows has downloaded it in ascii-mode instead of binary mode. It seems to be some of these *.run files where a part of the file is a shellscript, if this is modified by Windows it is no longer useable with Linux. My idea was simply to download it again with a Linux (or Mac) computer. The computer on which the file has to be installed seems to have no network-connection.

Markus
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Converting a binary file from little endian to big endian jaepi Programming 6 09-05-2011 09:51 PM
'Cannot Execute Binary File' issue kickout Linux - Software 4 09-16-2010 10:54 PM
Tar archive from windows to linux, binary file issue jblevins Linux - General 3 04-13-2009 11:50 PM
converting a hex file to binary linx win Programming 3 07-20-2006 03:04 AM
j2sdk installation issue - cannot execute binary file mcolley73 Linux - Software 2 04-18-2004 12:40 PM


All times are GMT -5. The time now is 03:04 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration