LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   bzip2: (stdin) is not a bzip2 file. error (https://www.linuxquestions.org/questions/linux-newbie-8/bzip2-stdin-is-not-a-bzip2-file-error-939933/)

Aqua_Regia 04-15-2012 02:44 PM

bzip2: (stdin) is not a bzip2 file. error
 
I've been trying to uncompress the file XpressConnect-x86.tar.bz2 using the tar command but I keep getting the following error.

Code:

richard@richard-K52Jr:~/Software$ tar -xvjf XpressConnect-x86.tar.bz2
bzip2: (stdin) is not a bzip2 file.
tar: Child returned status 2
tar: Error is not recoverable: exiting now

I think it may be a problem with the file itself b/c it was provied by our wonderfully incompetent IT dep. I've also tried tar -xvf but that did not work either. I'll attach the file to this post if I can any help would be appreciated.

colucix 04-15-2012 02:57 PM

What is the output of the following command?
Code:

file XpressConnect-x86.tar.bz2
It could be either a badly created file or a badly formed file name. Or eventually it is the result of an erroneous download.

Aqua_Regia 04-15-2012 03:05 PM

The output is:

[code]
richard@richard-K52Jr:~/Software$ file XpressConnect-x86.tar.bz2
XpressConnect-x86.tar.bz2: HTML document text
[\code]

colucix 04-15-2012 03:34 PM

Ok. It appears to be caused by an erroneous download (or even an erroneous upload on the server from which you downloaded it). Anyway, how did you get it? From a browser? Using wget? Try to download it again and/or share the link if it is public stuff so that we can test it.

John VV 04-15-2012 03:43 PM

let's see
using tar on a bzip2 file ?

and this bz2 file is a html text file ?
odd

what did you DL and save ?
the file or a html link ( web address ) to the file

Code:

bzip2 -d XpressConnect-x86.tar.bz2
- then tar --

tar -xf XpressConnect-x86.tar

however just using "tar" should have done it

or if you have a gui
double click the file and have your archive manager open it in the GUI
"file-roller" for Gnome
"ark" for KDE

Aqua_Regia 04-15-2012 03:56 PM

I'm getting the file from here:

Code:

wget <moderated - see below>
I tried using bzip2 to to extract:
Code:

richard@richard-K52Jr:~/Software$ bzip2 -d XpressConnect-x86.tar.bz2
bzip2: XpressConnect-x86.tar.bz2 is not a bzip2 file.

If you can't get the file using the above url I also uploaded it here (my FTP server is down): <moderated - see below>

colucix 04-15-2012 04:10 PM

Well, if you open the HTML file with a text editor, you can see some reference to a password protection mechanism to download the file. In other words it is not a direct download you can easily resolve using wget, but it goes through a java script that manages authentication.

Since XpressConnect is not a free and open source software, I'm going to remove the links from your post. Your best bet is to contact the IT department to ask for clarification about how to get the software (that should be properly licensed).

On the other hand, please notice I asked to share the link if it was public stuff (see post #4 above).

Aqua_Regia 04-15-2012 04:28 PM

Ok. Thanks for the help. The guys that set up the network for linux should be back on monday so I guess I'll have to wait till then. I tought that the xpress connect application was freeware, anyone can downlowd it here, should have double checked.

colucix 04-15-2012 04:34 PM

No problem. The only solution is to retrieve the correct file. Good luck! :)

dado_linux 05-25-2015 10:57 AM

Did you try with:
Code:

tar -xvf XpressConnect-x86.tar.bz2

fatmac 05-25-2015 02:19 PM

Quote:

Originally Posted by dado_linux (Post 5367203)
Did you try with:
Code:

tar -xvf <filename>.tar.bz2

See man tar

x=extract
v=verbose
f=filename

z=gzip/gunzip
j=Bzip2/Bunzip2

:)

Edit: c=create

dado_linux 05-26-2015 04:26 AM

That's ok, agree with you, but this worked for me yesterday... I have downloaded the newest stable version of linux kernel and -xvf was enough to work with tar.bz2 file.

brianL 05-26-2015 04:46 AM

Look at the date on the original post - over 3 years ago.

dado_linux 05-26-2015 05:47 AM

That is right, but it is obvious that still there are visitors with the same problem.
Most of the posts are many years old, but the problems for many linux beginners are the same.
So, any experience plus is welcome for all of us. Moreover, pls read the answer given by the moderator.

John VV 05-26-2015 03:09 PM

if your problem is like the OP's
the op downloaded a html link to a file behind a javascript LOCK

wget can not be used. Firefox is needed ( or internet explorer) and you have to let the script run on your system and answer the captcha

so if you are saving html links as tar.bz2 archives
( you also CAN NOT do that in windows. windows can not open a html file as a tarbz


you really have a issue with ALL basics ( windows and Apple also )


All times are GMT -5. The time now is 04:32 PM.