Menu

#5542 Scheduled Backup Fail During MySQL Backup Virtualmin 6.17 After Adding 2nd MySQL Server

1.984
closed-fixed
nobody
None
5
2022-02-02
2022-01-27
Eric
No

Hi,

We have been running full backups no problem but today we got an error after yesterday we added a remote MySQL server to virtualmin for some domains and some domains use the localhost. Below is there error that happens during the backup from the localhost domains. Webmin can access both localhost fine using root and the remote server MySQL. MySQL 5.7.36

The remote server MySQL DB's backp fine it is only the domains that are on the Default localhost that yield the same error.

.. dump failed! mysqldump: Got error: 1045: Access denied for user 'root'@'localhost' (using password: YES) when trying to connect

But webmin and in Virtualmin if we goto the domain itself and click edit databases it shows on localhost and we can click on manage and that works.

So the only item messed up is the backup script when it tries to do a scheduled backup?

Now we just tried again to backup in foreground using backup now and it worked?? Very puzzling

The MySQL in webmin shows the correct password but we do in fact see it tried with wrong password?

Just looking for other places to check where it could have wrong password?

mysql.log error
2022-01-27T01:01:27.530049Z 4172 [Note] Access denied for user 'root'@'localhost' (using password: YES)

Thank You,

Related

Bugs: #5542

Discussion

  • Jamie Cameron

    Jamie Cameron - 2022-01-28

    Do the local and remote MySQL servers have different root password? The issue may be that Virtualmin isn't using different credentials when switching servers for a backup..

     
    • Eric

      Eric - 2022-01-28

      Hi,

      Yes in fact we set the remote server to a different username instead of root
      just in case of a clash in usernames to hopefully avoid that.

      Again the mysql work if we go to scheduled backups click backup and bubble
      only selected and select the 2 domains and click backup now on the localhost
      they backup perfectly.

      Just strange when it happens on the schedule? Is there a file I can check I
      would presume that virutalmin uses for mysql the credentials we set in the
      mysql module in webmin mysql section for root login?

      Thanks!

      From: Jamie Cameron [mailto:jcameron@users.sourceforge.net]
      Sent: Thursday, January 27, 2022 9:44 PM
      To: [webadmin:bugs]
      Subject: [webadmin:bugs] #5542 Scheduled Backup Fail During MySQL Backup
      Virtualmin 6.17 After Adding 2nd MySQL Server

      Do the local and remote MySQL servers have different root password? The
      issue may be that Virtualmin isn't using different credentials when
      switching servers for a backup..


      [bugs:#5542] https://sourceforge.net/p/webadmin/bugs/5542/ Scheduled
      Backup Fail During MySQL Backup Virtualmin 6.17 After Adding 2nd MySQL
      Server

      Status: open
      Group: 1.984
      Created: Thu Jan 27, 2022 04:27 PM UTC by Eric
      Last Updated: Thu Jan 27, 2022 04:27 PM UTC
      Owner: nobody

      Hi,

      We have been running full backups no problem but today we got an error after
      yesterday we added a remote MySQL server to virtualmin for some domains and
      some domains use the localhost. Below is there error that happens during the
      backup from the localhost domains. Webmin can access both localhost fine
      using root and the remote server MySQL. MySQL 5.7.36

      The remote server MySQL DB's backp fine it is only the domains that are on
      the Default localhost that yield the same error.

      .. dump failed! mysqldump: Got error: 1045: Access denied for user
      'root'@'localhost' (using password: YES) when trying to connect

      But webmin and in Virtualmin if we goto the domain itself and click edit
      databases it shows on localhost and we can click on manage and that works.

      So the only item messed up is the backup script when it tries to do a
      scheduled backup?

      Now we just tried again to backup in foreground using backup now and it
      worked?? Very puzzling

      The MySQL in webmin shows the correct password but we do in fact see it
      tried with wrong password?

      Just looking for other places to check where it could have wrong password?

      mysql.log error
      2022-01-27T01:01:27.530049Z 4172 [Note] Access denied for user
      'root'@'localhost' (using password: YES)

      Thank You,


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/webadmin/bugs/5542/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

       

      Related

      Bugs: #5542

  • Jamie Cameron

    Jamie Cameron - 2022-01-29

    Is the trigger a backup being run on schedule, or one that includes domains with databases on different servers?

    The credentials being used to connect to MySQL should be set in /etc/webmin/mysql/config and /etc/webmin/mysql-remotehost/config

     
    • Eric

      Eric - 2022-01-29

      Yes it is set to daily full backup of all domains.

      2 of the all domains are databases on the local server. The rest of the
      domains are on the remote server.

      This happens each time this runs automatically nightly.

      I was thinking of creating another separate full backup schedule and bubble
      only selected to see if it works ok and have 2 separate full scheduled
      backups.

      A nice feature would be "clone selected schedule" this is not available as
      far as I can tell on the scheduled backups page?

      Thanks

      From: Jamie Cameron [mailto:jcameron@users.sourceforge.net]
      Sent: Friday, January 28, 2022 5:11 PM
      To: [webadmin:bugs]
      Subject: [webadmin:bugs] #5542 Scheduled Backup Fail During MySQL Backup
      Virtualmin 6.17 After Adding 2nd MySQL Server

      Is the trigger a backup being run on schedule, or one that includes domains
      with databases on different servers?

      The credentials being used to connect to MySQL should be set in
      /etc/webmin/mysql/config and /etc/webmin/mysql-remotehost/config


      [bugs:#5542] https://sourceforge.net/p/webadmin/bugs/5542/ Scheduled
      Backup Fail During MySQL Backup Virtualmin 6.17 After Adding 2nd MySQL
      Server

      Status: open
      Group: 1.984
      Created: Thu Jan 27, 2022 04:27 PM UTC by Eric
      Last Updated: Fri Jan 28, 2022 05:43 AM UTC
      Owner: nobody

      Hi,

      We have been running full backups no problem but today we got an error after
      yesterday we added a remote MySQL server to virtualmin for some domains and
      some domains use the localhost. Below is there error that happens during the
      backup from the localhost domains. Webmin can access both localhost fine
      using root and the remote server MySQL. MySQL 5.7.36

      The remote server MySQL DB's backp fine it is only the domains that are on
      the Default localhost that yield the same error.

      .. dump failed! mysqldump: Got error: 1045: Access denied for user
      'root'@'localhost' (using password: YES) when trying to connect

      But webmin and in Virtualmin if we goto the domain itself and click edit
      databases it shows on localhost and we can click on manage and that works.

      So the only item messed up is the backup script when it tries to do a
      scheduled backup?

      Now we just tried again to backup in foreground using backup now and it
      worked?? Very puzzling

      The MySQL in webmin shows the correct password but we do in fact see it
      tried with wrong password?

      Just looking for other places to check where it could have wrong password?

      mysql.log error
      2022-01-27T01:01:27.530049Z 4172 [Note] Access denied for user
      'root'@'localhost' (using password: YES)

      Thank You,


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/webadmin/bugs/5542/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

       

      Related

      Bugs: #5542

      • Jamie Cameron

        Jamie Cameron - 2022-01-29

        I would be interested to know if two separate backups ever fail in the same way..

         
        • Eric

          Eric - 2022-02-01

          Hi,

          Confirmed we made 2 separate full scheduled backups.

          1 has the domains that have remote MySQL

          1 has the domains on the local MySQL

          Both backups completed without any errors.

          So it definitely is a bug when domains are mixed in 1 backup on local and
          remote mysql backups

          Thanks!!

          Eric

          From: Jamie Cameron [mailto:jcameron@users.sourceforge.net]
          Sent: Friday, January 28, 2022 5:24 PM
          To: [webadmin:bugs]
          Subject: [webadmin:bugs] Re: #5542 Scheduled Backup Fail During MySQL Backup
          Virtualmin 6.17 After Adding 2nd MySQL Server

          I would be interested to know if two separate backups ever fail in the same
          way..


          [bugs:#5542] https://sourceforge.net/p/webadmin/bugs/5542/ Scheduled
          Backup Fail During MySQL Backup Virtualmin 6.17 After Adding 2nd MySQL
          Server

          Status: open
          Group: 1.984
          Created: Thu Jan 27, 2022 04:27 PM UTC by Eric
          Last Updated: Sat Jan 29, 2022 01:10 AM UTC
          Owner: nobody

          Hi,

          We have been running full backups no problem but today we got an error after
          yesterday we added a remote MySQL server to virtualmin for some domains and
          some domains use the localhost. Below is there error that happens during the
          backup from the localhost domains. Webmin can access both localhost fine
          using root and the remote server MySQL. MySQL 5.7.36

          The remote server MySQL DB's backp fine it is only the domains that are on
          the Default localhost that yield the same error.

          .. dump failed! mysqldump: Got error: 1045: Access denied for user
          'root'@'localhost' (using password: YES) when trying to connect

          But webmin and in Virtualmin if we goto the domain itself and click edit
          databases it shows on localhost and we can click on manage and that works.

          So the only item messed up is the backup script when it tries to do a
          scheduled backup?

          Now we just tried again to backup in foreground using backup now and it
          worked?? Very puzzling

          The MySQL in webmin shows the correct password but we do in fact see it
          tried with wrong password?

          Just looking for other places to check where it could have wrong password?

          mysql.log error
          2022-01-27T01:01:27.530049Z 4172 [Note] Access denied for user
          'root'@'localhost' (using password: YES)

          Thank You,


          Sent from sourceforge.net because you indicated interest in
          https://sourceforge.net/p/webadmin/bugs/5542/

          To unsubscribe from further messages, please visit
          https://sourceforge.net/auth/subscriptions/

           

          Related

          Bugs: #5542

  • Jamie Cameron

    Jamie Cameron - 2022-02-02
    • status: open --> closed-fixed
     
  • Jamie Cameron

    Jamie Cameron - 2022-02-02

    Ok, I had a look and have found the cause of this issue - it will be fixed in the next Webmin release.

     

Log in to post a comment.