All Forums |
Register |
Login |
Search |
Subscriptions |
My Profile |
Inbox |
Tool Warehouse |
FAQs |
Resources |
Help |
Member List |
Address Book |
Logout |
|
|
pax core dump
|
Logged in as: Guest |
Users viewing this topic: none |
|
Login  |
|
|
pax core dump - May 13, '05, 12:43:55 AM
|
|
|
wglass
Posts: 5
Joined: Apr. 26, '05,
Status: offline
|
Hi,
I'm trying to find a file archiving tool that will handle long file names. Tar seems to break on more than 100 characters. (I'm using it to collate a large directory tree for backup).
Something like this seems the way to go
pax -x cpio -w backup.pax *
But whenever I specify the -x option I get a core dump. I've updated to the latest version in the warehouse. Anyone have any ideas?
Thanks, WILL
|
|
|
RE: pax core dump - May 13, '05, 3:14:55 AM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
> Tar seems to break on more than 100 characters
For pathname length I assume you mean.
But you should be able to get to 254 characters unless it's a linkname.
With a linkname you are limited to 100 characters (linkname being a hard or
soft link). Do you receive a warning message about this ?
Well, actually if the filename is longer than 100 then strictly by the standard
for USTAR then this is a limitation. So I guess this is what you mean.
> Something like this seems the way to go...
The long term intent of the standards groups was/is for people to use pax.
to get past the limitations of tar. In practice it really hasn't happened.
The maxium length is 3072 for the pathname (well past MAXPATHLEN/PATH_MAX of 512)
which includes the filename. So a >100 character filename is fine.
> But whenever I specify the -x option I get a core dump.
Does it run for a while?
Have you tried it with "-v" to see more of what it is doing?
Can you isolate your core dump to a small example?
You are on which version of Windows and what SP level? (this could be very important)
|
|
|
RE: pax core dump - May 13, '05, 3:20:38 AM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
> Can you isolate your core dump to a small example?
Nevermind, I have just made an example.
I'm going to work on a fix now.
|
|
|
RE: pax core dump - May 13, '05, 11:31:24 AM
|
|
|
wglass
Posts: 5
Joined: Apr. 26, '05,
Status: offline
|
Thanks!
I ended up using cpio as follows:
find $dailybackup -xdev | cpio -o -H newc | $gzip -c > $archivedir/$dailyarchive
This gets around that path limitation and compresses my backup to 6GB nicely.
Which is better do you think - this approach or pax? Will I be able to easily restore from either?
|
|
|
RE: pax core dump - May 13, '05, 11:56:08 AM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
I think the pax approach is the better approach since the "extended cpio format"
is defined in the standard with pax. The cpio "-H newc" is using this format.
So that is a good choice that you made with the format option.
You should be able to extract/archive with pax the archive you just made.
With pax you do get the compress/decompress flags ("z" for gzip and "y/j"
for bzip2 and "Z" for compress). It saves a bit of typing. Cpio is scheduled
to get these flags too in the next few weeks (it's going through testing right now).
So, in this case, whichever you prefer is the real answer.
|
|
|
RE: pax core dump - May 13, '05, 3:22:17 PM
|
|
|
wglass
Posts: 5
Joined: Apr. 26, '05,
Status: offline
|
Thanks - that worked.
Just for the record (in case anyone else browses this thread), for my backup script I tried the built-in tar and gnu-tar 1.13. Both had problems with pathnames > 100 chars. It's possible gnu-tar 1.15 would have solved this but I had build errors. I also downloaded and tried zip/unzip from info-zip. This handled the long path names but the standard zip format has a max of 2GB. (apparently, the newer zip64 format holds more, but I couldn't find any free implementations).
pax or cpio, using the "newc" format (combined with gzip) seems the way to go. It handled both the extensive directory tree as well as the large archive size.
|
|
|
RE: pax core dump - May 13, '05, 3:26:55 PM
|
|
|
Rodney
Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
|
If you have a filename (not the pathname) with > 100 characters then no version
of tar will handle it. That's it's limit and the standard.
Tar is also limited to an 8M archive size.
|
|
|
RE: pax core dump - May 13, '05, 3:35:42 PM
|
|
|
wglass
Posts: 5
Joined: Apr. 26, '05,
Status: offline
|
Great - thanks for your help.
|
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
|
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts |
|
|
|