Just a quick one-liner to remind me how to ultra compress a file using 7za instead of the bog standard gzip which I always seem to automatically turn to because its the only one I can remember out of my head!
Anyway, the command to ultra compress a single file is:
7za a -t7z -m0=lzma -mx=9 -mfb=64 -md=32m -ms=on archiveName.7z filetocompress.ext
where the -t7z indicates a 7z archive, -m0=lzma indicates lzma compression method, -mx=9 dicates compression level (9 is ultra), -mfb=64 is the number of fast bytes for LZMA, -md=32m allows for a 32mb dictionary size and -ms=on indicates a solid archive.
Using the above I managed to compress a 285mb SQL dump to a insignificant 7.4mb archived file!