Posts tagged ‘mysql’

Short how-to:

root@215003:~# mysql -u root -p
Enter password:
mysql> CREATE DATABASE s_db;
mysql> GRANT ALL PRIVILEGES ON s_db.* to 's_user'@'localhost' IDENTIFIED BY '12345678';
mysql> FLUSH PRIVILEGES;
mysql>exit
mysql -u s_user -p s_db < database.sql
<
code>

Here it is ( with user name, password, database host and db name ) :
mysql -uuser_name -ppassword -hmysql_host_server_.domain.com -Ddatabase_name < database_commands.sql

When I tried to restart mysql
sudo /etc/init.d/mysql restart
it failed with
* Stopping MySQL database server mysqld [ OK ]
* Starting MySQL database server mysqld [fail]

Continue reading ‘Quick fix problem with mySQL starting on Ubuntu 9.10’ »