skip to Main Content

I have created a wordpress VM in GCP and all works perfectly. After the creation it is recommended that you change the temp passwords (makes sense). When I change the temp password on phpmyadmin the wordpress vm loses it’s host. When i change the password back again to the original temp password the wordpress site comes back up again.

So I assume there is a connection between myphpadmin credentials and the wordpress host but I don’t know where this relationship resides in the database and how to change both sets of credentials so that i can change the phpmyadmin password and maintain the connection to the wordpress site.

Happy to provide more info – im actually sure this is a very basic issue but struggling to find articles to help.

Cheers

2

Answers


  1. Chosen as BEST ANSWER

    I just wanted to update my own question in case someone else is a new as me. I am also sure there are more efficient ways to achieve the answer but this is how I did it.

    My struggle was that I did not know how to access wp.config.php file which contained the password of my wordpress data base. So I was changing myphpadmin password and then losing the data base as the credentials were different. Then I was at a loss as to how to actually change the wp.config file to match the new password.

    To do this I did a number of steps. I will also add helpful links to resources below.

    1. I installed an FTP client and established a connection with my google cloud vm.
    2. I located the wp.config file, in my case this was /var/www/html
    3. I exported the file and updated the password to match myphpadmin password.
    4. I re-imported but as I didn't have permissions to re-import to the same location (never did figure this out) I re-imported to the user folder found /home/
    5. I then went back to my googlecloud console, SSH in and as the root user moved the file from the folder I re-imported to the correct folder as mentioned above (/var/www/html). This then overwrote the existing file and updated my password.

    Helpful resources

    1. Setting up FTP: https://onepagezen.com/google-cloud-ftp-filezilla-quick-start/
    2. Moving files through SSH: https://www.siteyaar.com/fix-sftp-ftp-permission-denied-on-google-cloud/#solutions
    3. FTP error handling: https://onepagezen.com/fix-ftp-permission-errors-google-cloud/

    I hope this is helpful later down the line for someone else. Also please if you are reading this and are able to help other users (as well as myself) cut down on these steps, submit additional responses.


  2. The credentials you enter in phpmyadmin is actually not to access phpmyadmin itself, but rather for phpmyadmin to access the database. Then, the phpmyadmin is pointed to the same database as your wordpress site, so if use the same credentials for both and you change said credentials, you need to specify the new ones for both the phpmyadmin and wordpress.

    This is not specific to GCP.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search