Clearing Drupal's cache
You may need to clear caches after moving your site from one host to another. Also useful when you install new modules or for troubleshooting things. It is relatively harmless. Your site might slow down a bit after-wards while the cache fills back up.
A php snippet
You will never lose irretrievable data with this query. Use it as needed.
<?php
db_query("DELETE FROM {cache};");
?>The Devel Module
The devel module makes it easy to clear Drupal's cache. Just install the module and enable the developer block for easy access to cache clearing.
The Admin_menu module
The admin_menu has many time saving features, including several cache clearing options for menu, page requisites, theme registry, cache tables and administration menu. It also has cron and update.php links too.
A PHP file to clear caches and rebuild the routing tables
Be careful not to leave this on the server as anyone can clear caches if they know the file name. Create a file named clear.php with the following code. Place the file in drupal base directory and run it by browsing to http://example.com/clear.php.
<?php
include_once './includes/bootstrap.inc';
drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
drupal_flush_all_caches();
?>