LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Splitting 1.4 GB avi files (https://www.linuxquestions.org/questions/linux-general-1/splitting-1-4-gb-avi-files-397486/)

morgoth2400 12-29-2005 03:14 AM

Splitting 1.4 GB avi files
 
Hello

Is there anyone who can tell me how can I split an avi file over 1GB big into smaller pieces?
I've already know I should try it with avisplit but it seems to be a small problem with my Ubuntu version so I've been wondering if there are any other options?
Thanks a lot for any response and help
Happy New Year to everone ;)

heema 12-29-2005 03:28 AM

why dont u use the split command ??

you can split it to specific sizes
Code:

split -b 10m file
*it will split to to 10 MB parts*

then you could combine them using cat

e.g:
Code:

cat file1 file2 file3 > newfile
you could even combine them in windows ;)

e.g:
Code:

copy /B file1 + file2 newfile

cor67393 12-29-2005 03:33 AM

I don't know for what purpose you are trying to split, but have you tried the command 'split'?
Code:

split --bytes=10m movie.avi splitmovie.
This will split your file into 10MB chunks prefixed with splitmovie. To get your movie into one piece again, use:
Code:

cat splitmovie.* > joinedmovie.avi
'split' will not remove your original file, and 'cat' will not remove your splitted files.

gilead 12-29-2005 03:36 AM

It depends on what you need to do with the pieces. If all you want to do is break the file into smaller pieces, there always /usr/bin/split. If for example you wanted to split an avi file called big.avi into pieces no bigger than 500MB, you could use something like
Code:

/usr/bin/split -d --bytes=536870912 big.avi big.avi-
This would output files of 500MB in size called big.avi-01, big.avi-02, etc.
To put them back together again, you just cat them, e.g.
Code:

/usr/bin/cat big.avi-01 > big.avi
/usr/bin/cat big.avi-02 >> big.avi

This last part should go in a loop - you don't want to be doing that manually...


All times are GMT -5. The time now is 07:35 AM.