[drupal-devel] [feature] Make default $db_url informative and unique

danielc drupal-devel at drupal.org
Wed Apr 13 17:23:00 UTC 2005

Issue status update for http://drupal.org/node/19800

 Project:      Drupal
 Version:      cvs
 Component:    base system
 Category:     feature requests
 Priority:     normal
 Assigned to:  Anonymous
 Reported by:  danielc
 Updated by:   danielc
 Status:       patch

This patch changes the default $db_url in settings.php to match the one
already in INSTALL.txt: mysql://userid:password@localhost/database


Previous comments:

April 1, 2005 - 00:21 : danielc

Attachment: http://drupal.org/files/issues/settings.dburl.diff (581 bytes)

Currently, the default $db_url in /drupal/sites/default/settings.php is
"mysql://drupal:drupal@localhost/drupal".  It would be helpful for end
users if its contents were more descriptive, such as

A side benefit of this change is helping automated installation scripts
determine if the settings in the /drupal/sites/default/ are meant to be
used or not.  This is because the existing db_url could possibly be
used in real life while the proposed text is very unlikely to be used.


April 3, 2005 - 07:36 : Dries

This is clearly documented in the text above the setting.  Also, the
modifications are not consistent with the example in the documentation.


April 3, 2005 - 13:44 : danielc

I'm concerned that some users could actually use the "drupal" for the
db, user and password.  That would trip up any bulid scripts that want
to ignore settings in sites/default/settings.php ONLY if they're not
really being used.  Plus using those as db/user/pw sucks for security.

How about using the sample URL from the docblock as the default $db_url
and I submit a patch to update the documentation with the new


April 5, 2005 - 12:23 : danielc

If the default $db_url does get changed, here is a list of Handbook
pages that make reference to $db_url:


This last page makes mention of includes/conf.php instead of

Plus INSTALL.txt would need to be updated.


April 7, 2005 - 13:50 : danielc

Attachment: http://drupal.org/files/issues/settings.dburl.per.install.diff (1.68 KB)

This patch unifies the format of the default $db_url.  It uses the
format found in INSTALL.txt, plus it clarifies the ability to change
the DMBS.


April 11, 2005 - 17:46 : danielc

Can this please be applied to HEAD and 4-6?


April 11, 2005 - 17:55 : Morbus Iff

-1. No user knows, or is told, what DBMS is.


April 11, 2005 - 18:06 : danielc

If "dbms" is the concern, we can either explain what it means or can
leave the default as "mysql."  But, please, the default $db_url in
settings.php needs to be something else.  Tell me what you want it to
be and I'll make a patch with it.

More information about the drupal-devel mailing list