At wits ends with Wordpress database error
-
- Posts: 6
- Joined: 2017/02/15 06:49:17
At wits ends with Wordpress database error
Really hoping someone has a new idea. I've read literally everything on Google and everything on the forums and can't figure out why I still get the database connection error.
Fresh mysql database created and fresh Wordpress install, but everytime I try url/wp-admin/install.php I get the "cannot connect to database" error.
I feel like this is maybe a host issue. I always have it set to localhost in wp-config.php, but I can't tell if my mysql server is using that.
Any advice at all? I really have no idea what is wrong.
Thank you!
Fresh mysql database created and fresh Wordpress install, but everytime I try url/wp-admin/install.php I get the "cannot connect to database" error.
I feel like this is maybe a host issue. I always have it set to localhost in wp-config.php, but I can't tell if my mysql server is using that.
Any advice at all? I really have no idea what is wrong.
Thank you!
Re: At wits ends with Wordpress database error
Installed on the hosting management system?
1. Check the username and password.
2. Try to connect to the old database using test script writing you.
3. Try to create a new database, and connect to the new database using a test script writing you.
4. Try to install WP to create a new database during installation.
1. Check the username and password.
2. Try to connect to the old database using test script writing you.
3. Try to create a new database, and connect to the new database using a test script writing you.
4. Try to install WP to create a new database during installation.
Re: At wits ends with Wordpress database error
Did you tell selinux that it should allow database connections from httpd to mysql? Look at getsebool -a | grep httpd for a list of the various booleans that can be set that influence things like this. To set the one you need you need to run setsebool -P httpd_can_network_connect_db 1
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Re: At wits ends with Wordpress database error
You don't need set 'httpd_can_network_connect_db 1'. just set correct selinux permission on WordPress directory. Or disable temporary selinux during installation. To correct work WordPress with selinux, you have to set right permission 'httpd_sys_rw_content_t'.
Re: At wits ends with Wordpress database error
He says "everytime I try url/wp-admin/install.php I get the "cannot connect to database" error" and to do that he will need to set the selinux boolean.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
-
- Posts: 6
- Joined: 2017/02/15 06:49:17
Re: At wits ends with Wordpress database error
Hi. Thank you so much for your help.
When I run getsebool -a | grep httpd
result is: getsebool: SELinux is disabled
Do you recommend enabling it?
When I run getsebool -a | grep httpd
result is: getsebool: SELinux is disabled
Do you recommend enabling it?
Re: At wits ends with Wordpress database error
Well... I don't recommend *disabling* it. But if it is disabled then it is not the source of your current problems.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
-
- Posts: 6
- Joined: 2017/02/15 06:49:17
Re: At wits ends with Wordpress database error
Okay. Thanks. I don't even seem to have a selinux config file anywhere. No selinux folder under sysconfig either.
Could there be something else that is preventing mysql from communicating with the Wordpress install? I'm sorry, I have no idea what I'm talking about.
Could there be something else that is preventing mysql from communicating with the Wordpress install? I'm sorry, I have no idea what I'm talking about.
-
- Posts: 6
- Joined: 2017/02/15 06:49:17
Re: At wits ends with Wordpress database error
Update: Set up a fresh database and now I'm just getting white page of death on the main ip as well as install.php.
Re: At wits ends with Wordpress database error
List last 20 line of error and access of apache/nginx log of this website.
Your php work correctly ?
Your php work correctly ?