LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
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 11-24-2011, 05:20 AM   #1
scramble64
LQ Newbie
 
Registered: Nov 2011
Posts: 7

Rep: Reputation: Disabled
Change of suffix format on "split" tar archive files


Hello all,

I recently used the command below with the intent to back up about 1TB of data into an external HD:

tar -cvpj 'directory/name'/ | split -d -b 2000m - /name/of/archive.tar.bz2.

which produced a list of files named:
archive.tar.bz2.00
archive.tar.bz2.01
...
archive.tar.bz2.99

Now that I am trying to access this data I am realizing that the numbering of the chunks goes from 00 to 99, which got me thinking that actually not all of the original data may have been backed up, given that the suffix for the split files contains only 2 digits and can reach at most a value of "99".

Is there a way to change the format of the suffix to contain more than two digits?

Many thanks for your help!

Carlo
 
Old 11-24-2011, 05:28 AM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
Yes. Try option -a of split
Code:
-a, --suffix-length=N
       use suffixes of length N (default 2)
 
Old 11-24-2011, 05:41 AM   #3
scramble64
LQ Newbie
 
Registered: Nov 2011
Posts: 7

Original Poster
Rep: Reputation: Disabled
Thanks a lot! How did I not see that?!?!
 
  


Reply

Tags
backup, split, tar



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
rsync "skipping non-regular files" with --archive option andrewtblake Linux - Server 2 04-29-2010 04:15 PM
Error in TAR - tar: GNU features wanted on incompatible archive format. kuldeep.k Linux - General 3 08-14-2009 11:09 AM
"tar -xzf" error: "tar.child died with signal 13" vlsi Linux - General 4 05-26-2009 02:04 AM
is there a linux-supported archive format that can split into multiple files? Moebius Linux - Software 3 07-11-2006 02:52 PM
How to "cp" or "rm" or "tar" all the files except a certain file? cqmyg5 Slackware 7 04-07-2006 02:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:16 PM.

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
Open Source Consulting | Domain Registration