Category Archives: Hosting
Force http to redirect to https via a .htaccess file
There are many ways you can force visitors of your site to use https regards of what they type into their address bars. Here are a few ways you can do this from your .htaccess file If https is not on, then rewrite the url to https RewriteEngine On RewriteCond %{HTTPS} !^on$ RewriteRule (.*) https://yourdomain.com/$1 …
Ticket ID Not Found. WHMCS Error – Disable mySQL Strict Mode
We recently moved our WHMCS to a much more powerful server. In the process we elected to use CloudLinux for the added security. The migration was smooth and there was no downtime because our System Administrators are awesome, however we did run into an issue with WHMCS after the move. Anytime we created a new …
How to backup a MySQL database via SSH
To backup a database, it is pretty easy. Here are the 2 commands I use most If you are planning on restoring this into a new empty database, then use this command. mysqldump –add-drop-table -u db_username -p db_name > mybackup.sql If you are planning on merging this backup into an existing database, then you should …
Manually adjust the number of visitors on a cPanel counter.
If you have a counter on your site using the cpanel counter script (/cgi-sys/count.cgi) and you need to adjust the number of hits that it reports, you can do so by editing the following file /var/cpanel/Counters/userid-something.dat Replace “userid” with his username, and the “something” with whatever the counter was called. Now when you got …
warning: shell_exec() has been disabled for security reasons
If you get an error like this, it means that shell_exec is disabled in the php.ini file. To re-enable it, you need to do the followng SSH to the server edit the php.ini file (on cpanel it’s /usr/local/lib/php.ini) search for the line that says “disable_functions” remove shell_exec from this line Save the file, and …
Quick Tip: Checking SPF and DKIM records
If you want to check if the DKIM and SPF records have been setup on the dns server for example.com issue the following 2 commands. DKIM dig default._domainkey.example.com TXT If you have it setup right, you should see something like this in the answer section: ;; ANSWER SECTION: default._domainkey.example.com. 300 IN TXT “v=DKIM1\; k=rsa\; p=MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyWompSSOHvgTtoRiLN1ieoj38kn7BK5suTGXeEXup9u96uCKw/73VaOfKngsUcAYr44/usj0cSNzlHbfWPDsm0cMToLiv7oqB4Ly+QsyzopfXc/UCJX2+pPGERiX9FjaEWADY6CTOxC+0f2J7150mh2G12cnSlmZvQ/M25GKnWDg9PX/8CojpDZUype5Mo15V” …
Mass changes to DNS zones on a cpanel server
Let’s say you have a DNS server change, and need to update the zone records on all your domains to use the new name server “NS” records. Rather then going through each and every one of them in the WHM, you can run these 2 simple commands. cd /var/named;grep -lR ns.oldnameserver.com *.db >> fixfiles.txt for …
- English Support
- 24/7 x 365
- Branded Support
- Reduced Overhead
- Linux Experts
- Friendly Staff