Why drush fails with undefined function conf_path() error? Here's a weird one: I've got two nearly identical server setups, both running Drush 5.9. Both have been happy for a while. Went to use one today, and got the error:

Drush 5.9 does not support Drupal . Use Drush 4 instead.
PHP Fatal error: Call to undefined function conf_path() in /var/opt/drush/includes/bootstrap.inc, line 786

The other site runs Drush 5.9 just fine.  Any ideas?
Without knowing what command you're trying to run or your file structure, it's difficult to say.

Most commonly this happens when your drush has trouble bootstraping your Drupal root, either by corrupted Drupal core files or different loading the wrong files.

In example if you run drush inside Panels module directory it fails, because it contains includes/common.inc file and drush is confused that it's Drupal core version of common.inc so it's loading it and expects that conf_path() should be defined. The same with core/includes/common.inc. Check the _drush_bootstrap_drupal_site_validate() function at drush API site.

I believe this has been fixed in the recent drush (see #60 at GitHub and original issue), so please upgrade it to the recent version (see the instructions).

However in some other circumstances the problem is still happening (#937) for some reason.