Archive for the ‘Technology’ Category

  • Optimize MySQL Database Performance Using Indexes

    Date: 2011.03.17 | Category: Technology | Response: 0

    Recently we found a client’s script causing high MySQL CPU usage. MySQL was using almost 200% CPU when his script run.

    There were few concurrent queries. We noticed his table has more than 2 million records and all queries included regular expressions. By checking the structure of the table, we found no indexes were used on columns that are frequently used in where clauses. So we created an index on the most frequently used column to see if that help. MySQL’s CPU usage fell to 10% immediately.

    Similar issues may exist on your sites too. If you find that your SQL query is slow or the site bites too many system resources, you may need to check the indexes of your database.

    Indexes are best used on columns that are frequently used in where clauses, and in any kind of sorting, such as "order by". It can significantly improve sql query performance.

  • Get Your CPU Usage Info in cPanel

    Date: 2010.09.28 | Category: Hosting, Technology | Response: 1

    In the past time, many customers asked us " Where can I see my CPU Usage info ? ". The answer was always no. But from today, it changes to yes.

    We add a new cPanel plugin to show CPU usage information. You can see that on the left sidebar of your cPanel. The value is based on all CPUs. Multiply it by 4 or 8 ( depending on the number of the CPU cores of the server ) then you’ll get your real CPU usage.

    We plan to add an email notification function so that you can know when you should upgrade your host or check scripts. Auto-suspend function is also considered to be added to prevent most clients from being affected by a few high usage clients.

    *Note: The plugin is still beta.

    Update ( March 21, 2011 )

    The plugin is final released. The value you see is your real CPU usage now, you needn’t multiply it as above.

  • All Servers Come with Ksplice Now

    Date: 2010.09.28 | Category: Hosting, Technology | Response: 0

    To avoid downtime caused by Kernel updates, Sugarhosts now use Ksplice on all servers.  We strive to achieve 100% uptime in future.