The server is having problems. Installed an extra NIC, to rule out problems with the onboard NIC, but that didn’t solve the problem. Removed the memory DIMMs now, and replaced them with two out of my desktop machine, since that had 4x4G and I don’t really use it at the moment. So they both now have 8GB internal memory. The desktop memory is Corsair Vengeance, the server memory was some value ram. Hopefully the Vengeance dimms will solve the system freezes.
With ulimit -n
you can see what the maximum number of open files can be. As superuser you can change that -per session- with the ulimit command, but an ordinary user can not do that. Therefore, you need to change the /etc/security/limits.conf file. For instance:
* soft nofile 10000
* hard nofile 10000
Meaning that the hard and soft limit are now increased to 10000. I didn’t know that this does not change the limits for the superuser. The asterisk (*) is not intended to change superuser limits. Instead, repeat both lines, changing the asterisk to the word root. You might need a reboot for that, but that’s all.
I needed this for Neo4j and was surprised to see that normal users could have more open files than the superuser. No more, I say, no more!
I edited /etc/sudoers without visudo, and made a mistake. That will prevent you from successfully using sudo again. No real harm done, but it takes rebooting to get it fixed.
1) reboot in recovery mode (press escape when booting so the grub options are shown)
2) drop to a root shell (option in the recovery menu)
3) mount -o rw,remount /
4) visudo (emacs based editor)
5) reboot the system
You should be up and running again!
Just switched from MySQL to MariaDB as per these instructions. Piece of cake and done (on my not so busy server) in under a minute.
As a result of the switch, this blog should be a fraction faster, since MariaDB claims to be faster than MySQL.
I had a need to use the Sun/Oracle JDK instead of the OpenJDK supplied with Ubuntu 12.04. I found this page, and following that did the trick.
One remark: when you download the tar.gz version from Oracle, you will end up with just a .gz file. In fact it is a tar.gz file, they just mixed up the extension.