No database is installed by default.
You need to install something like MySQL or Oracle or Postgres.
Installing MySql on Ubuntu
Open a terminal window, and use the following command:
sudo apt-get install mysql-server
To check whether the MySQL server is running:
sudo netstat -tap | grep mysql
When you run this command, you should see the following line or something similar:
tcp 0 0 localhost.localdomain:mysql : LISTEN -
If the server is not running correctly, you can type the following command to start it:
sudo /etc/init.d/mysql restart
Configuration
You can edit the /etc/mysql/my.cnf file to configure the basic settings -- log file, port number, etc. For example, to configure MySQL to listen for connections from network hosts, change the bind_address directive to the server's IP address:
bind-address = 192.168.0.5
Replace 192.168.0.5
with the appropriate address.
After making a change to /etc/mysql/my.cnf the mysql daemon will need to be restarted:
sudo /etc/init.d/mysql restart
If you are running PHP you will also need to install the php module for mysql 5:
sudo apt-get install php5-mysql
To create a new database, use the mysqladmin command:
mysqladmin create
Installing Oracle 10g XE on Ubuntu
Oracle provides a debian repository at http://oss.oracle.com/debian, containing only Oracle 10g Express Edition (XE) packages. To see these packages, add this line to /etc/apt/sources.list
file:
deb http://oss.oracle.com/debian unstable main non-free
Next, you will need to add the GPG key.
wget http://oss.oracle.com/el4/RPM-GPG-KEY-oracle -O- | sudo apt-key add -
sudo apt-get update
To install the XE database server:
apt-get 'oracle-xe-universal' or 'oracle-xe' (Western European support only).
apt-get install oracle-xe-universal
If you only need the XE client, type
apt-get install oracle-xe-client