Automatic GeoIP database update

Free binary GeoLite Countrydatabase by MaxMind is being  updated every month. To update it automatically you can  put this script to cron at the beginning of a month. That’s it. Didn’t find the answer to your question? Ask it our administrators to reply we will publish on website.

RPM: building proctitle for PHP

Sometimes it’s convenient to change PHP script name, it allows to check if it’s running by typing just pstree. You can perform that with use of proctitle. Unfortunately there is no rpm for this package for Fedora 15. So to use it you need to build it. Firstly you need to download source package to…
Read more

RPM: how to build Redis library package for PHP

At Supportex we use Redis a lot. It’s extremely fast and doesn’t consume a lot of resources.  Besides it’s easy to use for developers (especially for those who worked with Memcache). Unlike Python which has only one mature client, PHP has various of them.  For instance, Predis, phpredis,  Rediska, etc. We prefer phpredis. It’s written…
Read more

Python: sorting dict by value

Probably one of the most often task while working with dictionaries in Python is sorting by value. That is how it can be done: Didn’t find the answer to your question? Ask it our administrators to reply we will publish on website.

Troubleshooting: Cannot open TUN/TAP dev /dev/net/tun

If you are getting error ‘Cannot open TUN/TAP dev /dev/net/tun‘ while starting OpenVPN server, it means that you should load ‘tun’ module which features TUN/TAP device driver: OpenVPN 2.1.1 i386-redhat-linux-gnu [SSL] [LZO2] [EPOLL] [PKCS11] built on Jan 26 2010 NOTE: the current –script-security setting may allow this configuration to call user-defined scripts LZO compression initialized…
Read more

Nagios: monitoring virtual Windows servers

I would like to propose one of the ways of monitoring of OS Windows server, which is installed on a Linux server as a virtual one. For this purpose, we will use Nagios and the program for Windows – NSClient++. First of all we need to install program NSClient++ on the virtual machine. During the…
Read more

Python: distribution systems world

At the very beginning Python packaging world may seem too confusing. But only at first sight. There are a lot of different packages package formats, libraries and tools for distributing and  packages management in Python world. There is also PyPI – the Python Package Index is a repository of software for the Python. Most often…
Read more

AWK: quick way to get squid users traffic usage

If you need quick and simple way to get squid users traffic usage you can use this script: Here is an example: [root@server ~]# head -n 50000 /var/log/squid/access.log | /usr/local/bin/ alice – size: 1532.08 Mb linda – size: 11.84 Mb cray – size: 9.30 Mb focus – size: 3.05 Mb santa – size: 0.96 Mb…
Read more