How to optimize Drupal is one of the most common questions in the mind of every website owner. Drupal is no doubt one of the most admired and well accepted CMS (Content Management System) applications in the online world today. Literally, with so many CMS applications these days in the marketplace it is really tough to maintain the position. Almost daily we hear some new templates and new add-ons to make them unique and apart from the crowd.
Not only this but they have to prove themselves as efficient and as user-friendly as possible. They literally have to show why they have an edge over their competitors. What are the features their competitors won’t have and so much. When it comes to Drupal it has enjoyed a great privilege in the marketplace by offering unprecedented stability and performance for almost every kind of site; general or business purpose, technical for the techno savvies or simple enough for newbies.
The end use for any CMS site is to make their content popular and reach the target audience to generate business. There are many technical issues which only CMS sites can handle. So the main issue is to optimize the Drupal website to make it popular between human visitors as well as search engines, most of the times the things that seem to work on human visitors don’t seem to work on the search engines and visa-versa. So perhaps there is no short cut when it comes to optimization; however, a few things can surely go a long way.
We are discussing a few important tips to optimize a Drupal website here. The first and foremost tip is to enable the caching for your Drupal website, next much importance should be given to optimizing Drupal database. No doubt, when it comes to optimizing Drupal database, it is easier said than done. There can be many ways to optimize tables in Drupal database but mainly there are two ways:
The first one is to install the Data Base Maintenance (DBM) module. This is already given on your Drupal; you can do that by enabling/disabling “Drupal Modules” from the “Drupal Administration” area. Then go to “Administer” then to “Site building” and finally “Modules” section. Upon the module is successfully installed and activated, you can access it from your “Drupal admin” area. Then go to “Administer” and then to “Site configuration” and finally go to “DB maintenance”. All you need to do is to select the tables that you want to optimize and click “Optimize now”.
There is another method of optimizing your Drupal database. Perhaps this can be a little tricky than the previous one which requires some technical knowledge of PHP and SQL query. However the entire code is very simple to understand and implement instantly. The code should be like that:
$db = mysql_connect('localhost','user','password');
if(!$db) echo "cannot connect to the database";
mysql_select_db('user_drpl1');
$result=mysql_query('OPTIMIZE TABLE accesslog,cache,comments,node,users,watchdog;');
echo mysql_error();
?>
Once you have included this code you should then log in to your Drupal “admin” area and go to “Site Configuration” area, after that go to “Performance”. Here you should remember that apart from just enabling cache, you must also enable “Page compression”, “Optimize CSS” files and “Optimize JavaScript” files. Please note that for better performance and speed you should modify the global MySQL settings on a VPS/Dedicated server. Lastly, don’t forget to disable/remove all modules/blocks you are not using, as they further add up in the due course of time.
Popularity: 15%



[...] http://www.stevearun.com/429/optimizing-your-drupal%E2%80%94a-few-important-points-you-must-know/ [...]