How to remove Tomcat on cPanel

Want to remove Tomcat from cPanel?

Log-into your server as root using ssh:

Execute the following command to stop the Tomcat process:
# /usr/sbin/stoptomcat

…and to remove the next files, enter:
# rm -f /usr/sbin/starttomcat
# rm -f /usr/sbin/startomcat
# rm -f /usr/sbin/stoptomcat

Finally, remove all mod_jk lines from httpd.conf, including addmodule, loadmodule, and include lines.

Virtuozzo: Fixing Windows VPS Container Start Errors

Due to the way the Virtuozzo virtualization platform works, all VPS containers are linked to the Host Node Operating System. For this reason, Windows updates are specifically disabled in Virtuozzo VPS Containers as any changes or updates to Windows System Files or Drivers, that differ from the host node can render the VPS Container unusable – All Windows Updates must be approved by SWSoft/Parallels and offered as Virtuozzo updates, which have to be applied on the Host Node.

Continue reading Virtuozzo: Fixing Windows VPS Container Start Errors

Unsuspend Plesk Domain Accounts

Occasionally Plesk can be a little temperamental and suspend accounts over expired validity errors. Attempting to “unsuspend” the account from your Plesk control panel will generally fail, and you will need to activate the domain by force using the command line.

In Windows, goto Start -> Run and cd to your Plesk “bin” folder – typically c:\Program Files\Parallels\Plesk\admin\bin

Then type the following:

domain.exe –on

This can take a little while but you should see “SUCCESS, status of domain changed”, and the domain will again appear as “Active” from your Plesk Control Panel.

cPanel Server : Restoring MySQL SimLink.

If you’re unable to restart mysqld and troubleshooting the cause: if u log into SSH and go to /tmp you may see that there is no simlink

To create a simlink you can do the following:

cd /var/lib/mysql/
touch mysql.sock
chmod 1777 mysql.sock
chown mysql.mysql mysql.sock

Create a symlink for the sock file :-
ln -s /var/lib/mysql/mysql.sock /tmp

Restart mysql :- service mysql restart

Then your MySQL service should be back to normal.

Linux server tip: force reboot/shutdown

Forcing reboot

A Linux Server is not Windows XP and if reboot fail you usually still connect by SSH and do something. This commands will show you how to remotely hard reboot machine. Hard reboot mean that shutdown scripts will not run and machine reboot immediately without syncing hard disk drives, shutdown applications etc, it’s more like hitting the reset button.

echo 1 > /proc/sys/kernel/sysrq

echo b > /proc/sysrq-trigger

This commands enable sysrq and after this calls fast reboot. If you want to force shutdown machine try this.

Force shutdown

echo 1 > /proc/sys/kernel/sysrq

echo o > /proc/sysrq-trigger

This came handy, when I had a server that had some IO error and it can no longer read from disk, only few cached binaries into memory kept it running (kernel, SSHD, bash), I could still access the machine via SSH but can no longer do anything, forcing the reboot as mentioned above was my only resort, and it worked like charm…

How To Set Up A Load-Balanced MySQL Cluster With MySQL 5.1

This tutorial is based on Falko Timme’s tutorial for MySQL Cluster 5.0. It shows how to configure a MySQL 5.1 cluster with five nodes: 1 x management, 2 x storage nodes and 2 x balancer nodes. This cluster is load-balanced by an Ultra Monkey package which provides heartbeat (for checking if the other node is still alive) and ldirectord (to split up the requests to the nodes of the MySQL cluster).
Continue reading How To Set Up A Load-Balanced MySQL Cluster With MySQL 5.1

How to update Virtuozzo Node to the newest Kernel

Virtuozzo includes a utility to update itself and the included templates. To run this, you will need to ssh into the hardware node and execute the command:


In order to update the templates, add a -t to the command thusly:

vzup2date -t

It should be noted that if Virtuozzo is installed on the server, the standard Redhat up2date command should never be run.

If you are running Virtuozzo on a Windows server, then you can run the Virtuozzo update utility accessed through the Start menu.