Using a for loop in bash to read a file line by line can sometimes be very annoying, here’s a little trick to make it actually red it LINE BY LINE.
Category: Linux

Automatic Debian System Installation for ISPConfig 3
Update (2015-07-15): This script is outdated. Matteo Temporini gave live to a new version. This version can be found here: https://github.com/servisys/ispconfig_setup Update (2013-02-28): This script is pretty old. I changed jobs and don’t use ISPConfig anymore. The script is NOT being maintained anymore. Since I’m installing new ISPConfig 3 servers on a frequent base I […]

Running multiple Postfix setups
Today a customer wanted to use their current mail server for sending regular emails to a list with about 200.000 addresses in it. Sure no problem, but this will fill your queue and all other mail from/to your company will get delayed. To avoid this, you can setup Postfix so that it can run a […]

Add date and time to bash history
The .bash_history file has no date or time information in it. Sometimes it would be very nice to know when some command got executed. What i did is add the following 2 lines in /etc/profile: HISTTIMEFORMAT=’%F %T ‘ export HISTTIMEFORMAT Now logout, and log back in. Execute a command and check ‘history’: mark@localhost:~$ history 1 […]

Hotlink protection in nginx
People hotlinking your content on their websites can be pretty annoying, especially if you don’t have a flat-fee traffic contract. The following will explain how to setup hotlink protection for nginx.

Disable creation of .DS_Store files on samba shares
Don’t you hate it when your file server is filled with .DS_Store files and .TemporaryItems directories? .DS_Store files are hidden files created by Mac OSX in each directory you access with Finder and stores custom attributes of a folder like icon position and background images. Since they’re ‘custom’ and besides that they’re annoying, you don’t […]

H264 Streaming Module for Nginx compiling error
Update 2011-11-02: As of version 1.0.7, nginx has built-in support for mp4 streaming. When compiling Nginx with the nginx_mod_h264_streaming module, you might run into this error: error: ‘ngx_http_request_t’ has no member named ‘zero_in_uri’ Apply this patch or manual patch it like this: Look for this piece of code, and remove it. Save the file and […]

Installing ffmpeg 0.8 on debian squeeze and newer
I’ve created a newer version of this how-to which covers all current active releases of ffmpeg. The new how-to can be found here.

Preventing DOS attacks on apache with mod_evasive
Mod_evasive tracks the number of requests at the apache webserver and blocks the delivery in case that a certain limit has been reached. This way you can prevent DOS attacks. DDoS attacks are not really prevented with this module, it might help a little bit, but it’s not a full prevention.

Fix slow samba shares for windows machines
When you’re working with a lot of small files on a windows computer that has a network connection to a samba share, the performance can be awful! There is a quick fix for this problem, applying this will improve the performance of working with the share.