• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    MySQL Problem, What Am I Doing Wrong?

    Scheduled Pinned Locked Moved
    FOG Problems
    3
    6
    3.0k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • SaxxAppealS
      SaxxAppeal
      last edited by

      Hello all, I’m trying to figure out a very frustrating issue with my FOG setup. I set up Ubuntu 14 Server from scratch (VirtualBox), and generally followed the instructions [URL=‘http://community.spiceworks.com/how_to/show/78110-fog-1-0-0-on-ubuntu-server-14-04’]here[/URL]. Once FOG 1.0.1 finishes installing, I am able to access it via a web browser, and I everything seems to work fine. After 4-7 minutes, I get the “Cannot connect to database.” message. I’ve been using FOG 0.32 for quite some time, and I’ve triple checked all of the locations where the MySQL password should be, all is well… Is there another location I am missing that also needs to be updated, or can this be another issue entirely?

      I re-tried the installation about 20 times in the past 2 days, all with the same result. I’ve tried different versions of Ubuntu as well, same problem. I have FOG 0.32 running successfully on another VirtualBox, so I know it works for me virtually.

      Can anyone shed some light, PLEASE???

      Thanks everyone!!

      1 Reply Last reply Reply Quote 0
      • SaxxAppealS
        SaxxAppeal
        last edited by

        Update on my own post:
        For whatever reason, if I run ‘sudo service mysql stop’, then ‘sudo service mysql start’, everything works perfectly until next reboot. I can add the stop and start to a startup script for my server if need be. Is anyone else experiencing this bug?

        1 Reply Last reply Reply Quote 0
        • S
          silverado
          last edited by

          “Is anyone else experiencing this bug?”
          Yes, I am experiencing exactly the same bug. I am also using Ubuntu server 14.04. Restarting MySQL helps.

          1 Reply Last reply Reply Quote 0
          • R
            Reuben Bannister
            last edited by

            Im also having the same problem’s. I’ve reinstalled my Ubuntu about 20 times on site on Friday pulling my hair out!

            Hopefully they will get this sorted asap as this was my first time using the software and Im clueless about Linux as well so having to install Ubuntu Workstation then think it was something i was doing wrong to then install Server and find the same issues. Watched the install videos over and over.

            This seems to happen after every reboot btw.

            1 Reply Last reply Reply Quote 0
            • SaxxAppealS
              SaxxAppeal
              last edited by

              I’m currently working on different workarounds to resolve this issue. It might be one of those infamous MySQL bugs that sneaks into their releases… Or it might have something to do with the way FOG or the Ubuntu server is loading up services. As far as I can see, a file is being locked from access, and as soon as FOG can’t see it, the “Unable to connect to database” message pops up.

              Reuben (and anyone else reading), if you need any help with any of your setup, let me know, I’m glad to help. I’ve set FOG up in a number of different networking environments, and on a few different operating systems…

              1 Reply Last reply Reply Quote 0
              • SaxxAppealS
                SaxxAppeal
                last edited by

                Okay, here’s my crude but functional workaround…

                Since I figured the problem is that the mysql service was being locked out of a file it needed, and restarting the service completely fixes the issue, I changed my Ubuntu server to stop and start the mysql service after boot up. Fairly simple procedure, just do the following:

                [CODE]sudo nano /etc/rc.local
                [/CODE]

                In this file, above “exit 0”, type “service mysql restart” (no quotes).

                Ctrl X to exit, Y to save, Enter to save to same file.

                From that point forward, every time your server reboots, it will automatically bring down and up the SQL service, solving the “Unable to connect to database” error.

                Hope this helps someone out there, let me know if anything is unclear!

                1 Reply Last reply Reply Quote 0
                • 1 / 1
                • First post
                  Last post

                149

                Online

                12.0k

                Users

                17.3k

                Topics

                155.2k

                Posts
                Copyright © 2012-2024 FOG Project