How to install IonCubeLoader without recompiling apache

There are two ways to install IonCubeLoader on cPanel. The standard way includes recompiling Apache using EasyApache from WHM (or shell) and it takes 10-30 minutes to complete and results in Apache restart in the end.

But there’s also a quick way: just login to SSH and execute this command, wait a minute and that’s it!

/scripts/phpextensionmgr install IonCubeLoader

Ping returns unknown host

If your server returns unknow host errors when you try to ping some website, or wget returns unable to resolve host address, it’s most probably that you don’t have a valid DNS settings in /etc/resolv.conf

wget: unable to resolve host address downloads.sourceforge.net
ping: unknown host downloads.sourceforge.net

If you’r host didn’t provided their nameservers that you can use – you can use one provided by OpenDNS.net.
All you need to do is edit file /etc/resolv.comf and add their nemeservers into the file:

nameserver 208.67.220.220
nameserver 208.67.222.222

Save the changes and you’re ready to go!
(No need to restart anything)

How to remove WHM/CPanel untrusted certificate error

Untrusted certificate
If you just bought your new server powered with cPanel/WHM and you went to login at WHM/cPanel using secure connection (https://) and got that red error saying that certificate can not be trusted.
WHM cPanel certificate not trusted - The security certificate presented by this website was not issued by a trusted certificate authority. Security certificate problems may indicate an attempt to fool you or intercept any data you send to the server

You can just press “Proceed Anyway” and get to WHH, cPanel or Webmail login but that will just bypass it but it becomes quite annoying.

The Solution
Well there are two actually. First one includes buying SSL Certificate and those come at price from about $10 to few hundred bucks per year. If you sell hosting – I would recommend buying and installing one – but if you’re using the server alone – you can do it this way:

1. Login to cPanel/WHM (you’re clicking “Proceed Anyway” button for the last time I promise 🙂 )

2. Go to SSL/TLS and select SSL Key/Crt Manager in the menu

3. In the Certificates find the your host and download click the download button/icon:
SSL Key Crt Manager

4. Copy everything from (including) —–BEGIN CERTIFICATE—– to (including) —–END CERTIFICATE—– and paste it in a notepad and save that as whmcert.crt on desktop.
SSL Certificate

5. Double click on that file you have just saved/created and click on Install Certificate button.
SSL install step 1

6. Just click Next > 🙂
SSL install step 2

7. This is important step for all Windows Vista, Windows 7 and Windows 8 users. Select Place all certificates in following store then click Browse and in new small windows select Trusted Root Certificate Authorities, press OK and Next >
SSL install step 3

8. Press Finish
SSL install step 4

9. Restart the browser

10. Navigate to WHM, cPanel or Webmail secure login and you should no longer have that red error warning!

As I’ve said if you’re in hosting business – don’t be cheap buy a real SSL and install it. If you share server with a friend(s) or a business partner(s) just zip that whmcert.crt and email it to them and email them this article as a guide how to install the certificate. They have to do it from point 5. to point 10. Hope this helps!

Disk space usage showing 0 Mb on VPS

I have just installed a cPanel on new VPS account but it’s simply not showing any disk usage even with quoatas turned on. I have tried running /scripts/fixquotas but it didn’t help and it returned error: quotacheck: Cannot find filesystem to check or filesystem not mounted with quota option..

To make cPanel calculate disk usage you need to execute following commands:

touch /home/quota.user
touch /home/quota.group
chmod 600 /home/quota.user
chmod 600 /home/quota.group
quotacheck -acugvm

The result of the last command should look something like this:

quotacheck: Your kernel probably supports journaled quota but you are not using it. Consider switching to journaled quota to avoid running quotacheck after an unclean shutdown.
quotacheck: Scanning /dev/sda [/] done
quotacheck: Cannot stat old user quota file: No such file or directory
quotacheck: Old group file not found. Usage will not be substracted.
quotacheck: Checked 22164 directories and 750401 files
quotacheck: Old file not found.

By now it should work already but just to make sure execute quotas one more time

/scripts/fixquotas -force

That’s it!

When CSF firewal is enabled – ping reports lots of lost packets

I use just-ping.com when I need to ping my servers from various locations in the world to see if it’s working right. I have noticed that when CSF Firewall is installed and active I get losts of lost packets when trying to ping the server, but when I disable it – results are okay. The solution for this is to increase the ICMP_IN_RATE value from 1/s to 30/s.

To do so login to your WHM go to ConfigServer Security & Firewall and there click on Firewall Configuration button and on that page locate ICMP_IN_RATE (CTRL+F can help you locate it) and then increase it’s value from 1/s to 30/s. Scroll all the way down and pres “Change” button to save the changes. Restart the firewall and test it again.

Here’s a screenshot of what you need to chage:
csf ping problem solution

Now you should have good ping results at just-ping.com 🙂

04.12.2014 Update: Looks like the just-ping (now on new address cloudmonitor.ca.com) changed the way their service works. Now they ping you instantly from all places at once and CSF firewall will block most of these out and you’ll get lost packets in report. So for the testing you should set ICMP_IN_RATE to 0 – that will disable it – and then you can do tests. Other way around it to set it to fairly large number (200 or even bigger). Don’t forget to restart CSF + LFD in order these changes to apply.