This forum is no longer active. Please post your questions to our new community site

Forums WordPress

new wordpress database

Subscribe to new wordpress database 6 post(s), 2 voice(s)

 
Avatar pressforward 13 post(s)

How do I direct “bitnami wordpress” to load a different wordpress mysql database install? I tried changing the database name using the wp-config.php file, but an error appears.

Thanks in advance,

Bill

 
Avatar Beltrán Rueda Administrator 3,714 post(s)

What is the error? Is the database exists? Has this database permissions for the bitnami user?

 
Avatar pressforward 13 post(s)

What is the error? Blank screen appears for page: http://localhost/wordpress/

What did I change inside of wp-config.php: define(‘DB_USER’, ‘newdatabase’);

Does the db exist? Yes

The database permissions are the same except for the wildcard setting. The new database uses “database-specific”. How do I set? See below:

User Host Type Privileges Grant Action
bitnami localhost wildcard: bitnami_wordpress ALL PRIVILEGES No Edit Privileges
root 127.0.0.1 global ALL PRIVILEGES Yes Edit Privileges
root localhost global ALL PRIVILEGES Yes Edit Privileges
root production.mysql.com global ALL PRIVILEGES Yes Edit Privileges

Thanks for your review. Bill

 
Avatar pressforward 13 post(s)

This is the error showing for page: http://localhost/wordpress/wp-admin/

Can’t select database

We were able to connect to the database server (which means your username and password is okay) but not able to select the DB_NAME database.

  • Are you sure it exists?
  • Does the user bitnami have permission to use the DB_NAME database?
  • On some systems the name of your database is prefixed with your username, so it would be like username_DB_NAME. Could that be the problem?

If you don’t know how to setup a database you should contact your host. If all else fails you may find help at the WordPress Support Forums.

 
Avatar Beltrán Rueda Administrator 3,714 post(s)

Do you have more than one MySQL databases? Try the following, go to your command prompt (on windows) or to a terminal (on linux or OS X) and type:


cd <installation_directory>
mysql/bin/mysql -u root -p   <----  [use the same password that you type during the installation]
show databases;
GRANT ALL PRIVILEGES ON <your_database>.* TO 'bitnami_user'@localhost IDENTIFIED BY 'bitnami_password';
flush privileges;

And try now.

 
Avatar pressforward 13 post(s)

Thank you.

Couldn’t connect with your example. Hence, I used ‘mysql> grant all privileges on . to someusr@”%”
> identified by ‘passwrd’; ’ to access db.

Forums WordPress