Nagios is powerful monitoring software. And like OTRS in most cases it’s used with Apache. But sometimes you might want to use it with nginx. Here is a simple way to do that. Actually it’s very similar to launching OTRS with nginx – in both ways we use Perl FastCGI wrapper. I assume that you…
Trac: fixing ‘Warning: Can’t synchronize with repository “(default)” (Unsupported version control system “svn”: No module named svn).’
If you get a message ‘Warning: Can’t synchronize with repository “(default)” (Unsupported version control system “svn”: No module named svn). Look in the Trac log for more information’ while setting up or migrating you Trac, it means that you don’t have SVN library for Python installed. Note that Trac uses subversion-python package and not pysvn.…
Migrating OTRS from Apache to Nginx
Installing OTRS on Fedora is quite easy considering it has pre-built RPM packages and clean documentation. Usually OTRS is used with Apache. It’s stable well-tested solution. But what to do if you have nginx and you don’t want to have Apache? An issue becomes more complicated considering that nginx doesn’t support CGI from a box,…
MySQL: chained replication M1>S1>S2
In most case simple master-slave replication provides enough level of high-avalability (about 99.9%), read ops balancing and allows non-blocking backups (if you use MyISAM tables since InnoDB tables can be backed up without blocking). But sometimes you may want to setup chained replication with two slaves: first slave replicates from the master, and the second…
Dumping MySQL database from slave for replication set up
Usually to set up MySQL replication it’s convenient to dump database from current master with –master-data parameter. With this option mysqldump includes commented SQL operator which needs to be issued on slave to set up replication: CHANGE MASTER TO MASTER_LOG_FILE=’mysqld-bin.000008′, MASTER_LOG_POS=687808977; But sometime it’s not very good idea to dump database from master server. For…
Nginx: embedding Lua into webserver
Lua is a tiny but powerful programming language. Due to its small memory footprint (about hundreds of kilobytes) it’s widely used in application which need to be extended with more complex logic. For instance, Salvatore Sanfilippo has published a post describing how you can use power of Lua with Redis. It also applied to nginx,…
Lua: installing luarocks as RPM in Fedora 15
Ruby has gem, Python has pip and Lua has luarocks. Unfortunately, in Fedora 15 there is no rpm package of luarocks, so if you need it and don’t want to install it from sources, you will have to build it. Fortunately, there is a spec file written by Duboucher Thomas, so we don’t need to…
MySQL: checking replication with mk-table-checksum
Here is a simple way to check if your database on master and slave server have the same data. We will use mk-table-checksum from maatkit tools for this purpose. Note! Never do it on the production server! Or use it on your own risk! As stated: mk-table-checksum executes queries that cause the MySQL server to…
Using RRD with Python: short introduction
RRDtool is a great facility which aims to replace MRTG and was written by Tobias Oetiker. RRDtool provides powerful features for collecting and visualizing various system metrics like network traffic, MySQL counters or whatever you want. It’s always good idea to know what is going on under the hood of your server. Managing servers we…
Fixing ‘Missing dependency Cache::Cache at /usr/share/munin/plugins/mysql_’ error
While installing MySQL plugins for munin in Fedora 15 you may encounter this problem: [root@monitor plugins]# /usr/share/munin/plugins/mysql_ suggest Missing dependency Cache::Cache at /usr/share/munin/plugins/mysql_ line 716. [root@monitor plugins]# It means that your system lacks perl-Cache-Cache and perl-IPC-ShareLite packages. After installation you can proceed: yum install perl-Cache-Cache perl-IPC-ShareLite [root@monitor plugins]# /usr/share/munin/plugins/mysql_ suggest bin_relay_log commands connections files_tables innodb_bpool…