Regarding MySQL Auth + server change. HELP!!

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • AsylumN
    Confirmed User
    • Mar 2003
    • 625

    #1

    Regarding MySQL Auth + server change. HELP!!

    Guys, I need a quick answer, so I thought I would give this a shot as it might be faster than my host!

    Ok, I had MySQL Auth set up on my server for my password management for a paysite that is with NATS, and I just moved that paysite to another server today, and I uploaded my htaccess file for MySQL Auth to the new server, and I assumed it would work right because none of the structure of the site has changed (such as the domain or the location of the folders), only the server has changed!

    Well, nowwhen I click on the link to go to the members section of the paysite, it gives me a 500 internal server error.

    What do i need to change on the htaccess file (if thats the problem)? Here is how it is now:

    AuthName "Members Only"
    AuthType Basic
    AuthGroupFile /dev/null
    AuthMySQLHost localhost
    AuthMySQLDB dreamland
    AuthMySQLUser nats
    AuthMySQLPassword *****
    AuthMySQLUserTable members
    AuthMySQLNameField username
    AuthMySQLPasswordField password
    AuthMySQLPwEncryption none
    AuthMySQLUserCondition "status=1 AND siteid=3"
    require valid-user

    Now before the site was on the same server as my authmysql database, so since it has moved, maybe I am supposed to change the AuthMySQLDB? Is thats what causing the problem?
    SexSearch
  • jayme_
    Confirmed User
    • Jan 2005
    • 158

    #2
    "AuthMySQLHost localhost"

    mke sure that is where the DB is (in this case localhost)

    Comment

    • directfiesta
      Too lazy to set a custom title
      • Oct 2002
      • 30135

      #3
      You could have use the WHM panel ( or your host could have) to tranfer the whole site in one shot .... Looks like you need to restore your database and/or create it. Not familiar with Nats.
      I know that Asspimple is stoopid ... As he says, it is a FACT !

      But I can't figure out how he can breathe or type , at the same time ....

      Comment

      • JFPdude
        Confirmed User
        • Jan 2002
        • 4027

        #4
        Also is mod_auth_mysql module installed in apache ?

        Comment

        • modF
          Confirmed User
          • Aug 2002
          • 1888

          #5
          I see you don't have AuthMySQLEnable On

          Also, is a generic .htaccess file enabled on the new host?

          I do things
          skype:themodF

          Comment

          • AsylumN
            Confirmed User
            • Mar 2003
            • 625

            #6
            Originally posted by jayme_
            "AuthMySQLHost localhost"

            mke sure that is where the DB is (in this case localhost)
            Well, thats where it was before and it was working...
            the database is still in the same place, the onyl thing that has changed is that the paysite has been moved from the server where the database used to be and is now on its own server.

            so should the DB place not be localhost anymore?
            SexSearch

            Comment

            • modF
              Confirmed User
              • Aug 2002
              • 1888

              #7
              If the nats database is on a different server, you need to create a user on the databse server to allow the ip of the new server to connect to it. Then change the AuthMySQLHost to the ip (I prefer ip).

              Login to the shell of your new box, and try to access the database server using:

              mysql -u user -p -h database ip/hostname database name

              I do things
              skype:themodF

              Comment

              • jayme_
                Confirmed User
                • Jan 2005
                • 158

                #8
                Originally posted by AsylumN
                Well, thats where it was before and it was working...
                the database is still in the same place, the onyl thing that has changed is that the paysite has been moved from the server where the database used to be and is now on its own server.

                so should the DB place not be localhost anymore?
                it should be the ip address or the hostname of the mysql server.

                Comment

                • AsylumN
                  Confirmed User
                  • Mar 2003
                  • 625

                  #9
                  Originally posted by JFPdude
                  Also is mod_auth_mysql module installed in apache ?

                  yes, everything was working before, it was installed correctly, and it worked, it only stopped working when I put the paysite ona different server than where the whole NATS instalaltion and mod_auth_mysql was.

                  So in non-tech jargon, basically I suspect the reason its not working is because on the htaccess file I am specifying the location of where the database is, but I havent taken into account the new paysite server location.

                  So I suspect that I should change localhost to something else?
                  SexSearch

                  Comment

                  • jayme_
                    Confirmed User
                    • Jan 2005
                    • 158

                    #10
                    and what modF said^ also

                    Comment

                    • AsylumN
                      Confirmed User
                      • Mar 2003
                      • 625

                      #11
                      ok, wow, im amazed how fast you can get answers on GFY, faster than my host. Guys, I really appreciate it, JFPdude, modF, jayme, thanks so much.
                      SexSearch

                      Comment

                      • JFPdude
                        Confirmed User
                        • Jan 2002
                        • 4027

                        #12
                        Originally posted by modF
                        If the nats database is on a different server, you need to create a user on the databse server to allow the ip of the new server to connect to it. Then change the AuthMySQLHost to the ip (I prefer ip).

                        Login to the shell of your new box, and try to access the database server using:

                        mysql -u user -p -h database ip/hostname database name

                        yup

                        Comment

                        • Nathan
                          Confirmed User
                          • Jul 2003
                          • 3108

                          #13
                          Originally posted by AsylumN
                          ok, wow, im amazed how fast you can get answers on GFY, faster than my host. Guys, I really appreciate it, JFPdude, modF, jayme, thanks so much.

                          If you still need help, let us know please.
                          "Think about it a little more and you'll agree with me, because you're smart and I'm right."
                          - Charlie Munger

                          Comment

                          Working...