4.8. Setup for MySQL

Set up for a database system to be used on XooNIps:

[root@xoonips-server ~]# vi /etc/my.cnf

← Config file editing.

Add the following two lines in the section of [mysqld].



4.8.1. MySQL startup and automatic startup.

[root@xoonips-server ~]# /etc/init.d/mysqld start

← MySQL server startup.

[root@xoonips-server ~]# chkconfig mysqld on

← MySQL automatic startup

4.8.2. Set a MySQL password and delete unnecessary data.

[root@xoonips-server ~]# mysql -uroot

← Log into the MySQL server as root user.

Define the password for root user. (Example: mysqlroot@pass)

mysql > set password for root@localhost=password('mysqlroot@pass');

mysql > delete from mysql.user where user='';

← Delete anonymous users.

mysql > drop database test;

← Delete test database.

4.8.3. Create a database for XooNIps.

Create a database for XooNIps and name it xoonipsdb.

mysql > create database xoonipsdb character set ujis;

Create it with the user name: xoonipsuser, the password: xoonips@pass to access xoonipsdb.

mysql > grant all privileges on xoonipsdb.* to xoonipsuser@localhost identified by'xoonips@pass';

mysql > exit

← Log out of MySQL server.

Last updated