LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 05-14-2009, 12:00 PM   #1
Sum1
Member
 
Registered: Jul 2007
Distribution: Slackware and Gentoo
Posts: 234

Rep: Reputation: 25
.xz compression with tar


I heard the news about Slackware starting to use xz compression to distribute its packages so I thought I'd give it a try.

I updated my tar package to ver. 1.22 and tried to create a tarball using xz:

1. Failure using the -J option

root@a1:/archive# tar -cJf Install.tar.xz Bits* (Bits* refers to a directory in /archive)
tar: xz: Cannot exec: No such file or directory
tar: Error is not recoverable: exiting now
root@a1:/archive#

2. Failure using --xz option: the tarball operation will complete with no errors reported, but I am left with a .tar.xz file 0 bytes in size

-rw-r--r-- 1 root root 0 2009-05-14 12:31 Install.tar.xz

Whereas a regular .tar.gz file ends up like this:

-rw-r--r-- 1 root root 3042426880 2009-05-14 11:57 Install.tar.gz

Any ideas?
Thanks for your time and help.
 
Old 05-14-2009, 12:06 PM   #2
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
Do you have the xz utilities installed? It looks like tar is trying to access the xz utilities and getting a file not found error.

HTH

Forrest
 
Old 05-14-2009, 12:34 PM   #3
Sum1
Member
 
Registered: Jul 2007
Distribution: Slackware and Gentoo
Posts: 234

Original Poster
Rep: Reputation: 25
Quote:
Originally Posted by forrestt View Post
Do you have the xz utilities installed? It looks like tar is trying to access the xz utilities and getting a file not found error.

HTH

Forrest
I probably do not if they are not contained in the updated tar package.
I'll go hunt them down and see if it takes care of it.
Thanks for the quick reply!
Best regards.
 
Old 05-14-2009, 01:46 PM   #4
Sum1
Member
 
Registered: Jul 2007
Distribution: Slackware and Gentoo
Posts: 234

Original Poster
Rep: Reputation: 25
For those that may run into the same problem, install this xz utils package along with an updated tar package:

http://tukaani.org/xz/

Currently compressing a few large .iso's into a tarball.
xz seems to be taking much longer than gzip, but let's see if there's a large percentage decrease in tarball size by using xz....

Forrestt, thanks for your kind guidance.
 
Old 02-16-2010, 07:17 AM   #5
oobe
Member
 
Registered: Sep 2003
Distribution: slackware
Posts: 83

Rep: Reputation: 15
lol
 
Old 02-16-2010, 07:30 AM   #6
JimBrewster
Member
 
Registered: Feb 2010
Location: usa:/dev/random
Distribution: Slackware, Salix
Posts: 237

Rep: Reputation: 59
You will need the xz package.

If you are upgrading some of the base packages to 13.0, you should upgrade the whole system so that all the dependencies are in line. The procedure is outlined in UPGRADE.TXT in the root of the 13.0 installation disk, or at any slackware mirror, like here.
 
Old 04-27-2012, 08:25 AM   #7
doublejoon
Member
 
Registered: Oct 2003
Location: King George, VA
Distribution: RHEL/CentOS/Scientific/Fedora, LinuxMint
Posts: 366

Rep: Reputation: 44
After you install xz
Code:
tar -xJvf foo.tar.xz
 
  


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
Tar at lower compression density thierry8p Linux - Newbie 8 04-13-2009 08:36 PM
Tar compression, is this enough? blizunt7 Linux - Server 9 08-08-2007 09:45 AM
Tar Compression carlosinfl Linux - Software 2 01-29-2007 10:34 AM
Curious about what tar, without compression, would be used for bdb4269 Linux - General 9 01-08-2007 06:36 PM
Does TAR use any compression? Micro420 Linux - General 15 12-13-2006 02:17 PM


All times are GMT -5. The time now is 01:12 PM.

Main Menu
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