arrow_upward

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Join split files (.001, .002, ...) easily on Linux
#8
I downloaded a random 100 MB file (generated from /dev/random) and split it up into 10 MB parts using this command:
split -d -a 3 --bytes=10M random-100M random-100M.

Result files are:
Quote:random-100M.000
random-100M.001
random-100M.002
random-100M.003
random-100M.004
random-100M.005
random-100M.006
random-100M.007
random-100M.008
random-100M.009

After downloading them to a Windows computer with 7Zip installed I attempted to extract them. As expected 7Zip does recognize the .001 file. However if you noticed the files from the split are starting with .000 to .009. So you cannot extract it because the initial part is not going to be picked up by 7Zip. And I didn't even bother to experiment with renaming.

How to fix this? Simple, instead of -d just use --numeric-suffixes=001 to tell it to start from 001 instead of 000. -a 3 controls how big the suffix is. So a -a 3 equals size a of 000-999. While the default is 2 and would limit it to 00-99.

So the command you would use is:
split --numeric-suffixes=001 -a 3 --bytes=10M random-100M random-100M.

Now the output files start from .001. I downloaded them to the same Windows computer and could extract them just fine Smile .


@chanalku91

It is combining a single file that has been spit into many smaller files. Nothing to do with cropping. You don't/can't crop files. You an crop photos or screenshots or a video but not files.
[Image: zHHqO5Q.png]
lockThread Closed 




person_pin_circle Users browsing this thread: 2 Guest(s)
Sponsors: VirMach - Host4Fun - CubeData - Evolution-Host - HostDare - Hyper Expert - Shadow Hosting - Bladenode - Hostlease - RackNerd - ReadyDedis - Limitless Hosting