Fedora Linux Support Community & Resources Center

Go Back   FedoraForum.org > Fedora 17/18 > Using Fedora
FedoraForum Search

Forgot Password? Join Us!

Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 2nd June 2012, 09:38 PM
SlowJet Offline
Registered User
 
Join Date: Jan 2005
Posts: 5,002
linuxfirefox
How do I pass pbzip2 -parms to tar?

I saw a new compile of pbzip2 on koji and it remined me to check it out.
(It is a paralell threaded bzip2. The kernel's arre now all smp, use tar.bz2 to reduce space on disk.

The pbzip2 has some parms that would reduce the intesity of the compress a bit and save some memory.
But I do not know how to include those -parms in tar.

old tar -cj mean compress with bzip2, ext bz2 means the file is compressed
#tar -cj -f filetocompresson.bz2 ...

new tar (remove j, use -I pbzip2 "want pbzip2 <parmes here> -f file
#tar -c -I "pbzip2 -m4 -b4 -p2" -f file ...

The question is:
Can it be quoted as shown somehow to include it's -parms?

The default used all the memory but a few MB of the 3.9GB after system of about 500MB.
The 4.9GB root took 32 min on a Pent IV, vs. about 47 min with bzip2 and got about the same compresstion size(1.4GB)
I would like to speed it up a few more minutes and use a litte more disk space.

Also could some try this on a qud intel in 32 bit, it you have one?
Your compession default rate s/b in the range of 7 to 12 MB/s.for 4 to 5GB input with a result of around 1.5GB output. But the default will require 4x900MB + 900MB + a few MB for the programs tar and pbzip.

I could not find any config file for pbzip2, nor were the examples practical for recovery.
The Man page says -I=pbzip2 but the = sign crashes the child thread.

SJ

---------- Post added at 12:33 PM ---------- Previous post was at 10:42 AM ----------

Well, I googled and read and tried the quoted bit
but it did not work. Also I was confusing some KB's for MB's,
So I'll live with the defaults for now.

SJ

---------- Post added at 12:38 PM ---------- Previous post was at 12:33 PM ----------

On second thoht, I can't use it inside tar because I need a -d parm to unzip it.
Back tot bzip2.
SJ
__________________
Do the Math
Reply With Quote
  #2  
Old 3rd June 2012, 01:08 PM
george_toolan Offline
Registered User
 
Join Date: Dec 2006
Posts: 1,718
linuxfirefox
Re: How do I pass pbzip2 -parms to tar?

The kernels are SMP now, but do you have a dual core Pentium 4 or at least one with hyper-threading?

Btw what about xz compression or 7z?
Reply With Quote
  #3  
Old 3rd June 2012, 04:15 PM
Gareth Jones Offline
Official Gnome 3 Sales Rep. (and Adminstrator)
 
Join Date: Jul 2011
Location: Leamington Spa, UK
Age: 30
Posts: 1,689
linuxfirefox
Re: How do I pass pbzip2 -parms to tar?

You could do it the old-fashioned way:
Code:
tar cf - DIRECTORY | pbzip2 -YOUR_ARGS > ARCHIVE.tar.bz2
pbzcat ARCHIVE.tar.bz2 | tar xf -
(I'm assuming that pbzip2 interprets its command-line similarly to the original bzip2.)
Reply With Quote
  #4  
Old 3rd June 2012, 04:47 PM
stevea's Avatar
stevea Online
Registered User
 
Join Date: Apr 2006
Location: Ohio, USA
Posts: 8,299
linuxfirefox
Re: How do I pass pbzip2 -parms to tar?

Quote:
Originally Posted by SlowJet View Post
new tar (remove j, use -I pbzip2 "want pbzip2 <parmes here> -f file
#tar -c -I "pbzip2 -m4 -b4 -p2" -f file ...

The question is:
Can it be quoted as shown somehow to include it's -parms?
No.


Quote:
I could not find any config file for pbzip2, nor were the examples practical for recovery.
The Man page says -I=pbzip2 but the = sign crashes the child thread.
The syntax is like
tar -I pbzip2 -cvf foo.tpz ./some/files
tar -I pbzip2 -tvf foo.tpz
tar -I pbzip2 -xvf foo.tpz






Quote:
On second thoht, I can't use it inside tar because I need a -d parm to unzip it.
Back tot bzip2.
SJ
That's not a problem. tar adds the '-d' for extracts otr lists.

If you need to add options you can make a script like this, and put i ton your path,
[stevea@hypoxylon ~]$ cat bin/mypbzip2
#!/bin/bash
pbzip2 -v -m4 $@



Then use tar like ....
tar -I mypbzip2 -cvf foo.tpz ./some/files
tar -I mypbzip2 -tvf foo.tpz
tar -I mypbzip2 -xvf foo.tpz
__________________
None are more hopelessly enslaved than those who falsely believe they are free.
Johann Wolfgang von Goethe

Last edited by stevea; 3rd June 2012 at 04:57 PM.
Reply With Quote
Reply

Tags
parallel, parms, pass, pbzip2, tar

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Last Pass on F15/FF4 michaelm3 Using Fedora 4 18th June 2011 04:53 AM
cup 'o joe - pass it on JN4OldSchool Wibble 11 12th December 2007 09:23 PM
FC5 X86_64 AC3 Pass Through publicmsu Hardware & Laptops 0 7th November 2006 06:47 PM
PHP won't pass variable ??? imryn Programming & Packaging 6 6th April 2006 09:09 PM


Current GMT-time: 16:02 (Sunday, 19-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat