Wednesday, October 6, 2010

Split and Combine .ISO file in Ubuntu

Here are some linux commands that can be used to split and combine .ISO file.

Goto the directory in which .iso file is located
bond@bonds-desktop:~$ cd Downloads

to split file "myFile.iso" in parts of size 3gb
bond@bonds-desktop:~/Downloads$ tar cvzf - myFile.iso | split -d -b 3000m - myFile.iso.tar.gz.

output shown- myFile.iso

This creates parts as follows in the same folder
myFile.iso.tar.gz.00
myFile.iso.tar.gz.01

Now to combine parts
bond@bonds-desktop:~/Downloads$ cat myFile.iso.tar.gz.* | tar xvzf -

output shown- myFile.iso

and file is recreated

commands used are (you can split size to any size you want , here 100m)
tar cvzf - filename.iso | split -d -b 100m - filename.iso.tar.gz.
cat myFile.iso.tar.gz.* | tar xvzf -

No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...