Splitting a large file into smaller files in linux terminal

by guruprasad 2014-03-25 18:40:53

To Split a large file into number of smaller files in linux terminal,follow the steps below,


To Split the file name example.txt,use split command

split example.txt


To Split the file with some name and with required set of lines say 100 lines for each file,then

split -l 100 example.txt example_split

To Specify the memory size of the splitting file,then go with,

split -b 20k example.txt segment_split

Note:Can be useful in viewing the file when the large files takes loading time for viewing.
1010
like
0
dislike
0
mail
flag

You must LOGIN to add comments