1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129
|
Horde Database Installation Guide horde/scripts/db/README
=--------------------------------------------------------------------------=
$Horde: horde/scripts/db/README,v 1.2.2.5 2002/07/17 20:19:29 jon Exp $
Purpose of this file
~~~~~~~~~~~~~~~~~~~~
This file will hopefully ease the installation and configuration of your
database for use with Horde. The scope of the document deals primarily
with using your database with Horde and should not be considered a
resource for general database tasks.
Requirements for Horde
~~~~~~~~~~~~~~~~~~~~~~
Horde currently supports 4 databases:
- MySQL http://www.mysql.com/
- PostgreSQL http://www.postgresql.org/
- Oracle http://www.oracle.com/
- Sybase http://www.sybase.com/
MySQL and PostgreSQL are regularly used by the development team, and will
work with no problems. Oracle and Sybase were reported working in the
previous version of Horde/IMP by some of our users, and are assumed to
still work... but that hasn't been verified recently.
Before You Begin
~~~~~~~~~~~~~~~~
You will need to have your database preconfigured and working on your
system before you even get to this stage. For help with this, please
consult your database specific help files.
Before using any of the scripts listed below, please look over them to
ensure that any system-specific settings (or personal choices) are set
to your desired settings (eg. 'username', etc.).
Please NOTE that the database configuration steps listed below MUST
match what is configured within Horde.
Specifically, if you change the database name, user, or password while
configuring the database (below), you will need to make the same changes
to your Horde configuration files as well.
MySQL
~~~~~
The mysql_create.sql script will create a database called "horde", and a
user called "horde" (with password "horde") that has full rights
to the database. This script needs to be run as the MySQL root user
(which is NOT the same as the UNIX/Linux root user):
$ mysql --user=root --password=<MySQL-root-passwd> < mysql_create.sql
After running this script, it's a good idea to restart your MySQL
server:
$ mysqladmin --user=root --password=<MySQL-root-passwd> reload
To check that this is working, the following command should connect
without errors:
$ mysql --user=horde --password=horde horde
Type "quit" to quit MySQL.
If you need to uninstall the database, you can do so with:
$ mysql --user=root --password=<MySQL-root-passwd> < mysql_drop.sql
This will delete all your user data!
PostgreSQL
~~~~~~~~~~
# su - postgres (or whatever your database runs as... usually postgres)
$ psql -d template1 -f pgsql_create.sql
This script will create a "horde" database and a "horde" user. You
should set a password for this user with this command (if you didn't
uncomment the one in pgsql_create.sql):
$ psql -qc "ALTER USER horde WITH PASSWORD 'pass';" template1 postgres
Then create the tables within the "horde" database:
$ psql -d horde -f auth.sql
$ psql -d horde -f prefs.sql
$ psql -d horde -f category.sql
These scripts will also grant the "horde" user the necessary privileges to
each of the tables.
Oracle
~~~~~~
Run 'sqlplus'. Login, then [we need instructions for creating the
database and user here].
That should be it. Restart Oracle just to be sure, and try it. Then
create the tables within the "horde" database:
[Also need those instructions here.]
Sybase
~~~~~~
To create the database, from 'isql' run:
create database horde
Next, you should (recommended) create a login to use with this database.
The 'isql' command for this is:
sp_addlogin <username> <password>
Next you need to change the ownership of the database to this new user. The
'isql' command for this is:
sp_changedbowner <username>
After that, you just need to set up your tables within the database. To do
that, just run this command from the command line:
isql -i auth.sql -U<username> -P<password>
isql -i prefs.sql -U<username> -P<password>
Additional Notes
~~~~~~~~~~~~~~~~
This is by far not a complete HOWTO. This is just a compiled list of what
people have contributed so far. If you have tips, ideas, suggestions or
anything else that you think could help others in setting up their database
for use with Horde, please let us know. <dev@lists.horde.org>
|