FREE Backup space & FREE setup fee – Limited time for new signups!


* Current specials:
– We’re offering FREE 20GB off-site backup space with all of our server management plans for a limited time, for new signups.- We’re offering FREE SETUP and FREE 2nd month for transferring your server management services to us!

For more information, Please contact us at [email protected]

How to Optimize MySQL

CentOS
There is a default my.cnf that comes with mysql (4+5) that will make mysql run a bit quicker if you have 2+ gig of ram cp -f /usr/share/mysql/my-large.cnf /etc/my.cnfThere is also my-huge.cnf, or my-medium.cnf depending on your hardware setup.   Check the contents of these my*.cnf files for the one that’s right for you.

*NOTE* the log-bin option is enabled  by default.  This will quickly use a lot of disk space.  It’s recommended to comment out the log-bin line from your /etc/my.cnf, if it exists.

 

Remember to restart mysql when you are done with your my.cnf tweaking:

Redhat:/sbin/service mysqld restart

FreeBSD:/usr/local/etc/rc.d/mysqld restart

Increase /tmp partition size in cPanel and secure it

1. Stop cpanel, apache (or whatever webserver you are using), mysql services:

/etc/init.d/cpanel stop
/etc/init.d/httpd stop
/etc/init.d/mysql stop

2. Umount /tmp and /var/tmp:

umount -l /tmp
umount -l /var/tmp

3. Move /usr/tmpDSK file to another location (just in case you’ll need to mount it somewhere else to preserve data):

mv /usr/tmpDSK /usr/tmpDSK_back

4. Modify /scripts/securetmp to set tmpdsksize to desired size:

vi /scripts/securetmp

$tmpdsksize = 2048000

5. Run:

/scripts/securetmp

6. Start cpanel, apache (webserver), mysql services:

/etc/init.d/cpanel start
/etc/init.d/httpd start
/etc/init.d/mysql start

How to forward a website to another url

There are several ways to accomplish this task, but the simplest to understand is to use php.

To do this, you need to create the page that will do the forwarding.  This can be any page, as long as it ends in “.php”.  If you are trying to redirect a domain, you’d create “index.php” inside the public_html directory.

Once you decide which page you will use, then create the file and enter the following text:

<?php
header(“Location: http://whereyouwant.com/to/go.html“);
?>

Where http://whereyouwant.com/to/go.html is the location that you want the page to forward to.  You can use local values, ie: /page.html, or full urls as in the above example (http://..etc.)


Another way to accomplish this is to use an .htaccess file in the public_html directory.  Sample contents:

Redirect 301 / http://whereyouwant.com/to/go.html