python error: no module named pylab

You’ll need to install numpy, scipy and matplotlib to get pylab. In ubuntu you can install them with this command: sudo apt-get install python-numpy python-scipy python-matplotlib If you installed python from source you will need to install these packages through pip. Note that you may have to install other dependencies to do this, as well … Read more

Context switches much slower in new linux kernels

The solution to the bad thread wake up performance problem in recent kernels has to do with the switch to the intel_idle cpuidle driver from acpi_idle, the driver used in older kernels. Sadly, the intel_idle driver ignores the user’s BIOS configuration for the C-states and dances to its own tune. In other words, even if … Read more

CronJob not running

WTF?! My cronjob doesn’t run?! Here’s a checklist guide to debug not running cronjobs: Is the Cron daemon running? Run ps ax | grep cron and look for cron. Debian: service cron start or service cron restart Is cron working? * * * * * /bin/echo “cron works” >> /tmp/file Syntax correct? See below. You … Read more

Speed up rsync with Simultaneous/Concurrent File Transfers?

Updated answer (Jan 2020) xargs is now the recommended tool to achieve parallel execution. It’s pre-installed almost everywhere. For running multiple rsync tasks the command would be: ls /srv/mail | xargs -n1 -P4 -I% rsync -Pa % myserver.com:/srv/mail/ This will list all folders in /srv/mail, pipe them to xargs, which will read them one-by-one and … Read more

What is the difference between the ‘sites-enabled’ and ‘sites-available’ directory? [closed]

The difference is that virtual sites listed in the sites-enabled directory are served by Apache. In the sites-available directory there are the virtual sites that exist on your server, but people can’t access them because they are not enabled yet. sites-available: this directory has configuration files for ApacheĀ 2 Virtual Hosts. Virtual Hosts allow ApacheĀ 2 to … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)