From 880cccf57b71b60eb6195627565194d2b9d456d5 Mon Sep 17 00:00:00 2001 From: laf Date: Sun, 9 Aug 2015 14:36:31 +0000 Subject: [PATCH] Added some docs, update config.php.default and web installer to use mysqli by default --- config.php.default | 1 + doc/Support/Configuration.md | 16 ++++++++++++++++ html/install.php | 1 + 3 files changed, 18 insertions(+) diff --git a/config.php.default b/config.php.default index 479482113b..7bc2c78737 100755 --- a/config.php.default +++ b/config.php.default @@ -7,6 +7,7 @@ $config['db_host'] = "localhost"; $config['db_user'] = "USERNAME"; $config['db_pass'] = "PASSWORD"; $config['db_name'] = "librenms"; +$config['db']['extension'] = 'mysqli';// mysql or mysqli ### Memcached config - We use this to store realtime usage $config['memcached']['enable'] = FALSE; diff --git a/doc/Support/Configuration.md b/doc/Support/Configuration.md index e2288aef21..5ac1a25c22 100644 --- a/doc/Support/Configuration.md +++ b/doc/Support/Configuration.md @@ -19,6 +19,22 @@ $config['log_dir'] = "/opt/librenms/logs"; ``` Log files created by LibreNMS will be stored within this directory. +#### Database config + +These are the configuration options you will need to use to specify to get started. + +```php +$config['db_host'] = "127.0.0.1"; +$config['db_user'] = ""; +$config['db_pass'] = ""; +$config['db_name'] = ""; +``` + +You can also select between the mysql and mysqli php extensions: + +```php +$config['db']['extension'] = 'mysqli'; +``` #### Progams diff --git a/html/install.php b/html/install.php index d3611b5603..aedab8030e 100644 --- a/html/install.php +++ b/html/install.php @@ -352,6 +352,7 @@ $config_file = <<<"EOD" \$config\['db_user'\] = "$dbuser"; \$config\['db_pass'\] = "$dbpass"; \$config\['db_name'\] = "$dbname"; +\$config\['db'\]\['extension'\] = "mysqli";// mysql or mysqli ### Memcached config - We use this to store realtime usage \$config\['memcached'\]\['enable'\] = FALSE;