LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux > 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
 
Thread Tools
Old 11-30-2007, 10:54 AM   #1
300zxkyle
LQ Newbie
 
Registered: Jun 2007
Distribution: OpenSuSE 10.2
Posts: 13
Thanked: 0
Question tar how to auto next volume?


[Log in to get rid of this advertisement]
I have an older system running an older version of reiserfs with a file size limit of 4gb. I have a very large amount of data to backup, roughly 250gb kept on the file system. tar seems to fit the best however I have to manually enter the volume name each time I hit the 4gb limit for the filesize. Is there a way that I can get tar to auto increment the name of the volume each time a new file has to be created?

this is what I have been doing:

Code:
tar -vc -L 4194000 -f backup.tar /directory/to/backup > backup_log.txt
Which produces every 4gb

Code:
Prepare volume #2 for 'backup.tar' and hit return: n backup_2.tar
thanks
300zxkyle is offline     Reply With Quote
Old 11-30-2007, 12:39 PM   #2
indienick
Senior Member
 
Registered: Dec 2005
Location: London, ON, Canada
Distribution: Debian, Ubuntu, OpenBSD, OpenSolaris
Posts: 1,725
Thanked: 26
Does the man page not yield anything like this?
indienick is offline     Reply With Quote
Old 11-30-2007, 04:28 PM   #3
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :}
Posts: 18,849
Blog Entries: 1
Thanked: 160
It does indeed - and it can't be done w/o scripting. The feature
is (was) meant for tapes initially, and as such didn't work non-
interactively. With the -F option, you can run a script to rename
the chunks so they don't get overwritten, and with --volno-file you
can store info about the current version so the script for -F can
use that information ....



Cheers,
Tink
Tinkster is offline     Reply With Quote
Old 11-30-2007, 05:15 PM   #4
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 377
Thanked: 4
split(1) is what you want.
Samotnik is offline     Reply With Quote

Reply

Bookmarks


Thread Tools

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 multi-volume (-M): how to specify size? jhwilliams Linux - Software 1 08-16-2007 08:39 PM
tar multiple volume archive - volume script RGummi Linux - General 2 08-31-2006 05:08 PM
need some help with muli-volume tar (ubuntu, bash, gnu tar) MattCarp Linux - General 4 06-05-2006 09:15 AM
Kmix PCM volume problem (auto. set to 0 at every new track) Grisha8 Linux - Software 2 12-01-2005 03:48 AM
multi-volume tar exodist Linux - Software 11 01-18-2005 04:32 AM


All times are GMT -5. The time now is 07:06 AM.

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
RSS2  LQ Podcast
RSS2  LQ Radio
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration