Roundcube Community Forum

Release Support => Release Discussion => Topic started by: chinaman on October 13, 2007, 07:47:25 AM

Title: php.dist
Post by: chinaman on October 13, 2007, 07:47:25 AM
Dear All,

i just installed Roundcube and doing my first steps.
First of all I need to say that a very nice tool, something I've been searching for a long time already. Thanks to everybody who's working on it.

I ot some trouble when opening the first page it says:

"DATABASE ERROR: CONNECTION FAILED!

Unable to connect to the database!
Please contact your server-administrator."

I found something in this forum and set a link to db.inc.php.dist
ln -n db.inc.php.dist db.inc.phpAfterwords I could see the login page but wasn't able to login
So I did the same for main.inc.php.dist
ln -n main.inc.php.dist main.inc.phpNow I could login and everything seems running fine.

Did I missed something or is this a well know issue?

Best regards
Thomas
Title: Re: php.dist
Post by: SKaero on October 13, 2007, 05:04:00 PM
From the INSTALL document.
INSTALLATION
============

1. Decompress and put this folder somewhere inside your document root
2. Make sure that the following directories (and the files within)
  are writable by the webserver
  - /temp
  - /logs
3. Create a new database and a database user for RoundCube (see DATABASE SETUP)
4. Create database tables using the queries in file 'SQL/*.initial.sql'
  (* stands for your database type)
5. Rename the files config/*.inc.php.dist to config/*.inc.php
6. Modify the files in config/* to suit your local environment
7. Done!
Title: Re: php.dist
Post by: chinaman on October 20, 2007, 01:24:21 AM
Quote from: SKaero From the INSTALL document.
INSTALLATION
============
[...]
5. Rename the files config/*.inc.php.dist to config/*.inc.php
[...]

Thanks to wake me up!
Sometimes it might be better to read those documents more carefully.
Title: Re: php.dist
Post by: josh007 on November 30, 2007, 12:47:25 AM
QuoteFrom the INSTALL document.
============
Database Configuration

First thing we need to do is decide what database backend we'll use. The most common is mySQL but others are PostgreSQL and SQLite. So once you decide, think about the username and password you want to use, as well as a name for a database to use. Once you've decided that, write it out like this:

backend://username:password@domain.com/database

An example would be "mysql://demouser:password@mydomain.com/roundcube". Now, take that and in the "db.inc.php.dist" file find the line that starts with: $rcmail_config['db_dsnw']and replace the string that is currently there with the one we've come up with. Save that file as "db.inc.php" (note that we dropped the "dist" off the name).

If you are using MySQL, be sure to flush the users privileges when you add a new user or you will get a database connection error: FLUSH PRIVILEGES;

DONE! But i dont quite understand the last part that contains the FLUSH PRIVILEDGES. I dont know exactly how to do this.

QuoteDatabase Setup

While we're uploading (or after we're done) we have one final step to do before we can start using Roundcube. We need to set up our database. Open your website control panel. You first need to create a database and user with the information we decided earlier. Then add that user to the database. Next we execute the SQL file found in the "/SQL/" directory in Roundcube that is named: "*.initial.sql" where * is your database backend type (mySQL, PostgreSQL, SQLite).

For example with mysql enter the following code on the command line:

mysql --user=(your_db_user_name) -p (your_db_name) < mysql.initial.sql

1. Then add that user to the database. << How do u add a user to the Mysqladmin Panel?
2. mysql --user=(your_db_user_name) -p (your_db_name) < mysql.initial.sql << Where exactly the command line in the Mysqladmin shall i run this?

I have completed everything except the parts about the database. I would appreciate it so much if u can help me complete this installation.

The only way i can access my database is mysqladmin panel.