Quantcast
Channel: SharpDevelop Community
Viewing all articles
Browse latest Browse all 1764

Problem when taring files larger than 8 gigabytes

$
0
0

Hi !

I'm using SharpZipLib since 2007 to backup databases (in zip format when the database is smaller than 1 Gb, and in tar.gz when it's bigger).

Right now, I cannot compress one of my databases with tar.gz anymore, because it is 11 Gb large.

When I tar.gz them, and untar them, I can see that the file has lost 8 Gb.

My file is 10818747904 bytes long.

After reading the code, I found that the file size was stored in octal, and it corresponds to:

120466177000

however, the value SIZELEN defines how much bytes store the size, with the ending zero, and it is 12.

Thus, the file size is truncated to:

20466177000

A quick search showed me that this was a problem from the original TAR format:

http://en.wikipedia.org/wiki/Tar_%28file_format%29#Problems_and_limitations

and that it has been fixed in a latter specification (around 2001).

The library tar-cs seems to handle this case, but I would prefer to remain with SharpZipLib.

Could you fix the problem ?


Viewing all articles
Browse latest Browse all 1764

Trending Articles