add host in mysql connect

git-svn-id: http://svn.centreon.com/Plugins/Dev@2441 6bcd3966-0018-0410-8128-fd23d134de7e
This commit is contained in:
Julien Mathis 2007-06-05 19:53:23 +00:00
parent 33ad3b435f
commit e6d17ae545
3 changed files with 3 additions and 3 deletions

View File

@ -33,7 +33,7 @@ use DBI;
sub set_db { sub set_db {
require "@OREON_PATH@/ODS/etc/conf.pm" require "@OREON_PATH@/ODS/etc/conf.pm"
my $dsn = "dbi:mysql:$mysql_database_oreon"; my $dsn = "dbi:mysql:database=$mysql_database_oreon;host=$mysql_host";
return $dsn, $mysql_user, $mysql_passwd; return $dsn, $mysql_user, $mysql_passwd;
} }

View File

@ -33,7 +33,7 @@ use DBI;
sub set_db { sub set_db {
require "@OREON_PATH@/ODS/etc/conf.pm" require "@OREON_PATH@/ODS/etc/conf.pm"
my $dsn = "dbi:mysql:$mysql_database_oreon"; my $dsn = "dbi:mysql:database=$mysql_database_oreon;host=$mysql_host";
return $dsn, $mysql_user, $mysql_passwd; return $dsn, $mysql_user, $mysql_passwd;
} }

View File

@ -32,7 +32,7 @@ use DBI;
sub set_db { sub set_db {
require "@OREON_PATH@/ODS/etc/conf.pm" require "@OREON_PATH@/ODS/etc/conf.pm"
my $dsn = "dbi:mysql:$mysql_database_oreon"; my $dsn = "dbi:mysql:database=$mysql_database_oreon;host=$mysql_host";
return $dsn, $mysql_user, $mysql_passwd; return $dsn, $mysql_user, $mysql_passwd;
} }