HOWTO+-+Use+Command+Line+rar+in+Linux+to+Split+Files+Or+Folders

Assuming that you have rar already installed ("apt-get install rar" for ubuntu linux)

To compress file(s) to split rar archive know which directory you want to compress, I used /home as an example

code rar a -m5 -v5M -R myarchive.rar /home/ code

Let me break the above command down

rar - starts the program a - tells program to add files to the archive -m5 - determine the compression level (0-store (fast)...3-default...5-maximum(slow)) -v5M - determine the size of each file in split archive, in this example you get files with size 5MB (if you wanted files of 512kB size you would write -v512k) myarchive - name of the archive you are creating /home/ - is folder of the files you wish to add to the archive

You can read the manual for more options: code man rar code

Press q to exit and arrows to scroll up/down You can also add -p to the command after a and it will prompt you for a password.

To uncompress the archive type:

code rar x myarchive.part01.rar code