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

    [CentOS 7 + FOG1.5.5] Password MariaDB FOG + Password WEB

    Scheduled Pinned Locked Moved Solved
    FOG Problems
    2
    7
    614
    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.
    • G
      Guillaume.IT
      last edited by

      Hello to the FOG team,
      I just installed my FOG server version 1.5.5 on a CentOS 7.

      I am deploying a FOG server and I am having some difficulties that I am going to expose you.

      1. I would like to change the FOG password of the web interface. From which file can we make and which commands?
        I found on the wikifog: https: //wiki.fogproject.org/wiki/index.php? Title = Password_Central
        mysql -D fog
        INSERT INTO users (uName, uPass, uCreateDate, uCreateBy, uType, uDisplay, uAllowAPI, uAPitoken) VALUES (‘fog’, ‘00’, ‘localAdmin’, 0, ‘fog’, 1, ‘’);
        to leave

      Is there another method?

      1. I would like to add a password to the database via this execution sequence:
        mysql
        ALTER USER ‘root’ @ ‘localhost’ IDENTIFIED WITH mysql_native_password BY ‘’;

      You must know the password in two files: “define (” MYSQL_PASSWORD “,” “);”

      • /var/www/fog/commons/config.php. This file is missing in my server.
      • /opt/fog/service/etc/config.php. This file contains 1 line
        <? php define (‘WEBROOT’, ‘/ var / www / html / fog /’);

      So I think this method is not correct.

      On the net, I found this sequence to confirm that this one is the good one.

      To secure the DBMS, run the mysql_secure_installation command:
      mysql_secure_installation

      And answer the questions as follows:
      Enter the current password for root (enter for none): (press the Enter key directly on the keyboard)

      Set a root password? [Y / n] Y
      New password: MdpROOTsql
      Re-enter the new password: MdpROOTsql
      Delete anonymous users? [Y / n] Y
      Prohibit remote root connection? [Y / n] Y
      Delete the test database and access it? [Y / n] Y
      Reload the privilege tables now? [Y / n] Y

      Configuring the new FOG mysql root password
      Edit the file /opt/fog/.fogsettings and enter the password on line 21:
      nano /opt/fog/.fogsettings
      snmysqlpass = ‘MdpROOTsql’

      Edit the file /var/www/fog/lib/fog/config.class.php and enter the password on line 50:
      nano /var/www/fog/lib/fog/config.class.php
      define (‘DATABASE_PASSWORD’, “MdpROOTsql”);

      Thank you for your answers and help with my request.
      Guillaume

      1 Reply Last reply Reply Quote 0
      • Q
        Quazz Moderator
        last edited by

        You can change the password on the Web UI for any account, including fog from the users menu on the Web UI.

        As for the MySQL password, it says what to do

        Configuring the new FOG mysql root password
        Edit the file /opt/fog/.fogsettings and enter the password on line 21:
        nano /opt/fog/.fogsettings
        snmysqlpass = ‘MdpROOTsql’
        
        Edit the file /var/www/fog/lib/fog/config.class.php and enter the password on line 50:
        nano /var/www/fog/lib/fog/config.class.php
        define (‘DATABASE_PASSWORD’, “MdpROOTsql”);
        
        G 1 Reply Last reply Reply Quote 1
        • G
          Guillaume.IT @Quazz
          last edited by

          @Quazz Thank you for your answer. You resolve the first point. But for second point can you help me?

          Q 1 Reply Last reply Reply Quote 0
          • Q
            Quazz Moderator @Guillaume.IT
            last edited by

            @Guillaume-IT You need to edit two files

            /opt/fog/.fogsettings (edit snmysqlpass)
            

            and

            /var/www/fog/lib/fog/config.class.php (edit define (‘DATABASE_PASSWORD’, “MdpROOTsql”);)
            
            G 3 Replies Last reply Reply Quote 1
            • G
              Guillaume.IT @Quazz
              last edited by

              This post is deleted!
              1 Reply Last reply Reply Quote 0
              • G
                Guillaume.IT @Quazz
                last edited by

                This post is deleted!
                1 Reply Last reply Reply Quote 0
                • G
                  Guillaume.IT @Quazz
                  last edited by

                  @Quazz

                  Perfect,
                  You resolv my problems.

                  The first step OK :
                  Web Interface -> Users -> List ALL Users -> fog -> Change password

                  The second point OK :
                  Edit the file /var/www/fog/lib/fog/config.class.php:

                  nano /var/www/fog/lib/fog/config.class.php
                  define (‘DATABASE_PASSWORD’, “MdpROOTsql”);
                  

                  The FOG server is still functional in the Web and the database requires a password to enter!

                  Everything is good for this open ticket. I thank you for the efficiency of your response.

                  Continue like this.
                  Best regards.

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

                  229

                  Online

                  12.0k

                  Users

                  17.3k

                  Topics

                  155.2k

                  Posts
                  Copyright © 2012-2024 FOG Project