Jump to content
Sign in to follow this  
gesp

Transfered a website to new host - DB connect error 1045

Recommended Posts

Hi there,

I have recently transferred my Processwire to a different host. I have created a database and imported to the new host server and have transferred all the files Processwire. I have also created a database user and updated the config.php file with the necessary information and I am getting the following error in debug mode:
 

Fatal error: Exception: DB connect error 1045 - Access denied for user 'admin'@'192.249.113.81' (using password: YES) (in /home/admin/public_html/wire/core/ProcessWire.php line 96) #0 /home/admin/public_html/wire/core/ProcessWire.php(45): ProcessWire->load(Object(Config)) #1 /home/admin/public_html/index.php(183): ProcessWire->__construct(Object(Config)) #2 {main} in/home/admin/public_html/index.php on line 214
This error message was shown because site is in debug mode ($config->debug = true; in /site/config.php). Error has been logged.

Any clues of what is happening? Can anyone please help me?

 

Thanks

Share this post


Link to post
Share on other sites

Check if your new database is really consistent with your old one.

You should migrate database tables only.

Write permissions are ok ? Make sure that the files/folders in the assets folder are writable.

What about your root .htaccess file, rewrite base, etc. ?

You can find classical migration problems solved many times before in the forum.

https://processwire.com/talk/topic/4199-exporting-importing-database-error-access-denied-for-user-user-namelocalhost-to-database-database-name/

https://processwire.com/talk/topic/3113-how-to-transfer-processwire-from-local-installation-to-online/

https://processwire.com/talk/topic/8792-403-forbidden-when-saving-homepage/

https://processwire.com/talk/topic/1211-impossible-to-login-after-migration/

  • Like 1

Share this post


Link to post
Share on other sites

Also, make sure the host part for the user matches the web server IP (or is "%" as a wildcard).

select user, host from mysql.user;

lists all configured users and their allowed source hosts.

If that matches, check your user's permissions.

show grants for 'admin'@'192.249.113.81';

(or 'admin'@'%' if you specified a wildcard, whatever the user table showed). Check the exact database naming and, if all that fails, also reset the password.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By DooM
      Hello guys,
      I'm trying to figure out how to sync fields and templates between staging and production environments.
      I've found Migrations module by Lostkobrakai, but with use of it all the fields and templates must be created by API, which is kind of uncomfortable.
      I also tried ProcessDatabaseBackups module which can export only certain tables, but I don't think it's the best practice to do that.
      How do you guys solve this problem? It's very annoying to setup everything three times (dev, staging, production).
      Thanks a lot :)
    • By VeiJari
      Hello forum. I'm trying to figure out how to detect if current form has errors after saving it in pw admin page. This is so that our event location isn't added in database if we detect errors. But I can't seem to find a correct way to detect errors? I only found the wire()->errors() and it always triggers even if I don't have any errors. 
      How can I detect errors in a form?
      By error I mean $page->error('this is the red error');
    • By iipa
      Hi everybody!
      I have been reading about Multisite, but it kinda bugs me that every topic talks about having both admin and database same for multiple sites.
      I have a project where customer tests it by adding content to the site, while I still need to do some changes here and there in code, maybe some in database. If something crashes for a while, customer can't keep testing, which is a bit problematic.
      Is there any way that I could have two separate versions of one site ("production" and development) that share the same database, but are otherwise independent? Just the thought of having to migrate database every time I want to show client something new gives me anxiety 😁
    • By Falk
      Hi!
      After temporarily using Module Image Extra, which I completely removed, I had some troubles with my imagefield (unused table columns).
      So I just imported a previous version of this column via PHPmyAdmin, which worked pretty well.
      Anyways, in Processwire Backend all image tags are gone, although they are OK in the database.
      Other image related things work (thumbnail, title etc are OK).
      Is there any way to recreate all the images or something? Or may this be an cache-related issue?
       
      Thanks in advance 😃
       
    • By DevCat
      Hi,
      I'm trying to install ProcessWire on XAMPP localhost. I extracted the zip and put the files from master folder to website directory folder and when I go there with Firefox it says 404 page not found (no site configuration or install.php available). At least install.php surely is there. I'm doing WordPress installations on localhost almost every day and no problems. Does anyone here know what is cause for this error?
×
×
  • Create New...