The Computer Oracle

Splitting into many .ZIP files using 7-Zip

--------------------------------------------------
Hire the world's top talent on demand or became one of them at Toptal: https://topt.al/25cXVn
and get $2,000 discount on your first invoice
--------------------------------------------------

Music by Eric Matyas
https://www.soundimage.org
Track title: Lost Jungle Looping

--

Chapters
00:00 Splitting Into Many .Zip Files Using 7-Zip
00:26 Accepted Answer Score 26
00:59 Answer 2 Score 16
01:55 Thank you

--

Full question
https://superuser.com/questions/1370713/...

--

Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...

--

Tags
#diskspace #7zip

#avk47



ACCEPTED ANSWER

Score 26


Let's find out!

100 MB files (27 pieces):

7z a -tzip -v100M ./100m/archive ./kali-linux-xfce-2018.2-amd64.iso

$ du ./100m/
2677884 ./100m/

10 MB files (262 pieces):

7z a -tzip -v10M ./10m/archive ./kali-linux-xfce-2018.2-amd64.iso

$ du ./10m/
2677908 ./10m

Results: The 10 MB split archive takes up an extra 24 KB. So yes, there is a difference, the 100 1 GB files will take up more space than the 10 10 GB files.

The difference seems to be negligible though. I would go for whichever is more convenient for you.




ANSWER 2

Score 16


Every file has a file system overhead of unused logical sector space after the end-of-file, but this is eliminated if the split size is a multiple of the logical sector size (not necessarily true of my example below).

There may be extra bytes used by the extra directory entries, but these will not figure unless the directory now occupies an extra logical sector.

The split files are identical in content to those created by a binary splitter program with the same split size.

I verified these on Linux by using the GUI version on a 7+MB file, giving 8 split files of 1MB size with 7-Zip (File.7z.00?), then created a single, full archive (Full.7z), which I split with:-

7z -v1000000 a File;                                         # Create split volumes File.7z.00?
7z a Full File;                                              # Create full archive Full.7z
split -b 1000000 -a 3 --numeric-suffixes=1 Full.7z Full.7z.; # Split full archive into Full.7z.00?
for f in {001..008}; do cmp Full.7z.$f File.7z.$f; done;     # Compare splits with 7z volumes

To test on another OS you may need to down-load or write an appropriate splitter program.