Admin menu in Drupal6 disappears or is incomplete (solution) - developed.be

  • Published:March 14th, 2013
  • Category:Drupal 6

This post applies when

  • The admin menu suddenly disappears
  • The admin menu is incomplete (menu-items are missing)

Following scenario causes this behaviour:

  • The records of table “menu_links” with menu_name “admin_menu” were deleted (could be caused by an unfinished or erroneous cache wipe).
  • Cache-clear was called and caused a time-out by the webserver or php. (keep in mind cache-clear could’ve been called by cron through wget or by poormanscron)
  • Before the table menu_links was entirely refilled, a page of the website was requested by a user.

Even if you clear-cache afterwards, it says incomplete or missing.

A quick solution I’ve found is this:

  • Backup table “menu_links”
  • Delete the records in the table “menu_links” with menu_name = “admin_menu”. Don’t remove all the records in the table because primary and secondary links are also located in that table and they would be deleted permanently.
    DELETE FROM menu_links WHERE menu_name='admin_menu';
  • Call “cache-clear” but with Drush, because Drush doesn’t get interrupted by time-outs.

Or the more sustainable solution:

  • Change the time-out of the webserver to let’s say 120s.
  • Backup table “menu_links”
  • Delete the records in the table “menu_links” with menu_name = “admin_menu”. Don’t remove all the records in the table because primary and secondary links are also located in that table and they would be deleted permanently.
    DELETE FROM menu_links WHERE menu_name='admin_menu';
  • Call “cache-clear”, preferably with Drush, but you could also call it with the web admin as long as it doesn’t time-out.

Rss Comments

Comments

No comments yet.

Leave a comment