Nginx

From Steak Wiki
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Nginx and Apache are the main web servers used on the internet today.

Tips & Tricks

Log on RAM instead of the HDD

If you write all website visits on the HDD, you will wear it out faster. Instead, write to the RAM. The data will be volatile, but it will prolong server life. In GNU\Linux, tmpfs is a filesystem interface to the RAM. It is used when you need faster access to data than the HDD can provide. It can also be used as in this example, when you don't want to actually write to the HDD. To find where tmpfs is

df -h

Usually its in /dev/shm or /run/shm. Test out writing to the RAM:

nano /run/shm/hello

and write some text, then save. You have now written data to the RAM instead of the HDD.

See also Docker.