working with large files

directly opening the file in an editor will probably be inefficient (due to high memory utilization) because most text editors usually try to read the whole file into memory first.

instead, one can use less to view the contents of such a large file, scrolling up and down page by page, without the system having to place the entire file in memory before starting.

less somefile
cat somefile | less

reads the first few lines

tail

viewing compressed files

many standard command cannot be used directly. associated utilities often have the letter ‘z’ prefiexed to their name.

zcat, zless, zdiff, zgrep..