AdianC Posted November 5, 2008 Share Posted November 5, 2008 Hi , I just uploaded the files to the real server and I get the error:Unable to connect to database server! On the localhost all was fine and working.Now I get that annoying message. I talk with technical support ,they test the data base and is good and working. They told me that I have to find in the code where the pointing is for the data base ,and to change the....localhost to: xxxx.startlogicmysql.com. Can anyone tell me where I have to do this? Thank You So much Link to comment Share on other sites More sharing options...
aureolin Posted November 5, 2008 Share Posted November 5, 2008 Look in configure.php in the includes directory. The line you want to change is : define('DB_SERVER', 'localhost'); Link to comment Share on other sites More sharing options...
AdianC Posted November 5, 2008 Author Share Posted November 5, 2008 Thank You , I try yhat and I got same message. Here is the the wholw config file what else I need to change : <?php define('HTTP_SERVER', 'http://localhost'); define('HTTPS_SERVER', 'http://localhost'); define('ENABLE_SSL', false); define('HTTP_COOKIE_DOMAIN', 'localhost'); define('HTTPS_COOKIE_DOMAIN', 'localhost'); define('HTTP_COOKIE_PATH', '/dianaciulei/'); define('HTTPS_COOKIE_PATH', '/dianaciulei/'); define('DIR_WS_HTTP_CATALOG', '/dianaciulei/'); define('DIR_WS_HTTPS_CATALOG', '/dianaciulei/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/'); define('DIR_FS_CATALOG', 'C:/AppServ/www/dianaciulei/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); define('DB_SERVER', 'dianaciulei.startlogicmysql.com'); define('DB_SERVER_USERNAME', 'xxxx'); define('DB_SERVER_PASSWORD', 'xxxxx'); define('DB_DATABASE', 'dianaonline'); define('USE_PCONNECT', 'false'); define('STORE_SESSIONS', 'mysql'); ?> domain is :www.dianaciulei.com Thank You Adrian Link to comment Share on other sites More sharing options...
aureolin Posted November 5, 2008 Share Posted November 5, 2008 Question that I should have asked first ... What is the actual error you're getting? Also, you might try connecting through a tool like phpMyAdmin and ensuring everything works there - then copying the connection information to configure.php. Steve G. Link to comment Share on other sites More sharing options...
php_Guy Posted November 5, 2008 Share Posted November 5, 2008 Have you ever run the install program on the live server? It needs to be run once to create and populate the tables. During the installation, it also creates a new configure.php based on the settings you gave it. Those settings are also the ones you used to create the database. Keep that configure.php in the /catalog/includes/ folder on both the live server and on your local computer. Put the configure.php file that you have been using in the /catalog/includes/local/ folder on your local computer. Then, when you upload files from your local computer to the live server, just don't upload the /catalog/includes/local/configure.php The reason for this setup is that when osc loads, it looks in the /catalog/includes/local folder and if it sees a configure.php file there it uses it. If it doesn't, it uses the configure.php file in /catalog/includes/ directory instead. hth Link to comment Share on other sites More sharing options...
AdianC Posted November 5, 2008 Author Share Posted November 5, 2008 Thank You for replays, The error is: Unable to connect to database server! . I try to install and it goes trough the setup without errors.It gets at the end where you have catalog and admintool.When I click catalog or admin I get same error Unable to connect to Database server. I did like suggested and I deleted the Config .php from live server and then I run the install again.It did like you see below. it change it all see above file script and below. Result is the same.Unable to connect to databaseserver! . I check the database and on my sql is working.The techsupport uploaded on the site a test folder with PHP sript and db is there and working. Please go ahead and use this info to see what I am doing wrong.I will change pass and all after I get it working. <?php define('HTTP_SERVER', 'http://www.dianaciulei.com'); define('HTTPS_SERVER', 'http://www.dianaciulei.com'); define('ENABLE_SSL', false); define('HTTP_COOKIE_DOMAIN', 'www.dianaciulei.com'); define('HTTPS_COOKIE_DOMAIN', 'www.dianaciulei.com'); define('HTTP_COOKIE_PATH', '/'); define('HTTPS_COOKIE_PATH', '/'); define('DIR_WS_HTTP_CATALOG', '/'); define('DIR_WS_HTTPS_CATALOG', '/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/'); define('DIR_FS_CATALOG', '/hermes/bosweb/web087/b878/sl.dianaciulei/public_html/dianaciulei/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); define('DB_SERVER', 'dianaciulei.startlogicmysql.com '); define('DB_SERVER_USERNAME', 'dianaonline'); define('DB_SERVER_PASSWORD', 'upgrade'); define('DB_DATABASE', 'dianaonline'); define('USE_PCONNECT', 'false'); define('STORE_SESSIONS', 'mysql'); ?> also go ...www.dianaciulei.com/test and use the above info. Thank you Adrian Link to comment Share on other sites More sharing options...
easytech Posted November 5, 2008 Share Posted November 5, 2008 Thank You for replays, The error is: Unable to connect to database server! . I try to install and it goes trough the setup without errors.It gets at the end where you have catalog and admintool.When I click catalog or admin I get same error Unable to connect to Database server. I did like suggested and I deleted the Config .php from live server and then I run the install again.It did like you see below. it change it all see above file script and below. Result is the same.Unable to connect to databaseserver! . I check the database and on my sql is working.The techsupport uploaded on the site a test folder with PHP sript and db is there and working. Please go ahead and use this info to see what I am doing wrong.I will change pass and all after I get it working. <?php define('HTTP_SERVER', 'http://www.dianaciulei.com'); define('HTTPS_SERVER', 'http://www.dianaciulei.com'); define('ENABLE_SSL', false); define('HTTP_COOKIE_DOMAIN', 'www.dianaciulei.com'); define('HTTPS_COOKIE_DOMAIN', 'www.dianaciulei.com'); define('HTTP_COOKIE_PATH', '/'); define('HTTPS_COOKIE_PATH', '/'); define('DIR_WS_HTTP_CATALOG', '/'); define('DIR_WS_HTTPS_CATALOG', '/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/'); define('DIR_FS_CATALOG', '/hermes/bosweb/web087/b878/sl.dianaciulei/public_html/dianaciulei/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); define('DB_SERVER', 'dianaciulei.startlogicmysql.com '); define('DB_SERVER_USERNAME', 'dianaonline'); define('DB_SERVER_PASSWORD', 'upgrade'); define('DB_DATABASE', 'dianaonline'); define('USE_PCONNECT', 'false'); define('STORE_SESSIONS', 'mysql'); ?> also go ...www.dianaciulei.com/test and use the above info. Thank you Adrian Please tell us what application you are using to upload your files to the live server. Thanks Link to comment Share on other sites More sharing options...
AdianC Posted November 5, 2008 Author Share Posted November 5, 2008 I am using FileZila for FTP. Thank You Link to comment Share on other sites More sharing options...
pyramids Posted November 5, 2008 Share Posted November 5, 2008 I tried your site and got this error: Could not connect: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) The fix may be here: http://www.tech-recipes.com/rx/762/solve-c...t-tmpmysqlsock/ Link to comment Share on other sites More sharing options...
AdianC Posted November 5, 2008 Author Share Posted November 5, 2008 I tried your site and got this error:Could not connect: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) The fix may be here: http://www.tech-recipes.com/rx/762/solve-c...t-tmpmysqlsock/ Thank you for advice I went to the above link and i do not get the idea .I don't know where to go to edit the line in MySql. Thank you Link to comment Share on other sites More sharing options...
pyramids Posted November 5, 2008 Share Posted November 5, 2008 I was able to acces your database test page using: DB_SERVER = dianaciulei.startlogicmysql.com:/var/lib/mysql/mysql.sock Link to comment Share on other sites More sharing options...
AdianC Posted November 5, 2008 Author Share Posted November 5, 2008 I was able to access your database test page using: DB_SERVER = dianaciulei.startlogicmysql.com:/var/lib/mysql/mysql.sock Thank you, That did the trick.Now I will know what to do for the future. Many thanks for all of you that took the time to replay and help. Respectfully Adrian Ciulei Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.