Posts

Showing posts with the label linux

Cacti on CentOS4 Quick Howto

Hi, I've been asked to write my How-To on the CentOS Wiki. I don't want to have to manage 2 versions, so here is the link . Sorry for the inconvenience...

Wget

Ah, I do feel good when I solve a complex problem with a simple tool. wget. This time, I wanted to take a backup of the database I have hosted somewhere. The only way to get these databases' backup files is to go the control panel of my hoster, cpanel. Usually, then I think about that, it is too late (as these files are the current databases, so if I just screwed something, these files are useless) I then remembered that wget can send authentication, so I basically use wget in a cronjob that downloads the database files and put them in a folder named after the current day's name. This way, I have 7 days of backup history. I like that :).

Virtual Private Servers Pitfalls

It didn't take much time until I found pitfalls with VPSs. Today, I got bit by memory problem. My VPS had 128 MB RAM max. Before installing my usual packages, the memory usage was around 20 MB. Nothing! :). But then I installed my packages, forgot to tweak apache to minimize memory requirement. Installed mysql for cacti, configured cacti... Then, this morning, I realize that many processes were missing on my VPS. Why? I had enabled the yum daily cronjob.... mistake! Do you have an idea of how much memory yum uses? Too much. Tektonic told me that they stopped selling UM0 packages because of that: too many clients having memory problems. I upgraded my plans to UM1. I'm wondering though... how does Vpslink do with the smallest plan, only 64 MB RAM! I can't end this post without adding again how much helpful the folks at Tektonic have been up to now.

Virtual Private Servers

Hi, Time for another knowledge-sharing post. I recently discovered a very good alternative to shared, reseller, or dedicated hosting: A virtual private server (VPS). In fact, a VPS is a virtual machine running, with many other virtual machines (VM). There are many packages, but the cheapest are: Tektonic (Based on Virtuozzo. I own 3 VPS from them. Very, very nice and responsive people. They've been very supportive for me in my beginnings with VPSs. OpenHosting (Based on linux Vserver, fedora core 4 only for now, interesting utility billing system) Vpslink (Based on OpenVZ, the open-source version of Virtuozzo, never tried yet) Tektonic puts limit on outbound bandwidth that can be sometimes harsh. (Unmetered 1 mbps max for the smallest plan (15$/month)). That is more interesting for applications that don't need much outbound traffic (like remote backup, you have an unmetered 100mbps!) or e-mail, which don't really need an instant transfer, but can be problematic for web...

Nagios

I just started playing with Nagios, an open-source monitoring software package (GPL). I used to use monit instead, but there are two limitations of monit that made me switch: It can only do port/protocol checks on remote hosts It has no tolerance setting for check failures (it sends a warning as soon as there is one failure) On the other hand, Nagios has tools that allows a Nagios server to perform "local" checks on remote servers, via the network (check_snmp, check_nt, check_nrpe and check_ssh). It has as side effect that it can monitor Windows servers quite well. The web interface enough for my needs. Note: I'm still using monit for process checks, as Nagios can't do that as well as monit does (monit uses the information in the lockfile to see if the process is still in memory, and uses user-defined commands to restart the process if it is not in memory). Here is how Nagios works, basically: The tools that do the checks are called plugins Objects have to be defi...