Category Archives: cli

Add extra SWAP in Linux

If, by any chance, you happen to run out of SWAP space in Linux and you desperately need it, you can use a temporary file to supplement: dd if=/dev/zero of=/swap1.swp bs=1024 count=512K mkswap /swaptemp.swp swapon /swaptemp.swp Now verify if the image file was successfully mounted: cat /proc/swaps

Convert PDF to JPEG in Linux

If you want to convert some PDF files in JPEG format in Linux, you can use pdftoppm and ppmtojpeg. After you installed the two applications, do a ppm file.pdf file.ppm The result will be a PPM file for each page in the PDF. From here, to convert all PPM files in JPEG format do a… Read More »

Better default compression with GZIP

If you’d rather use the maximum compression settings in GZIP, use export GZIP=–best in CLI. Next time you’ll archive a folder or a set of files, compression will take place at the highest level.