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

    Setting up fog password fails on clean new CentOS 7 install

    Scheduled Pinned Locked Moved Solved
    Bug Reports
    5
    9
    5.3k
    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.
    • S
      Sebastian Roth Moderator
      last edited by Sebastian Roth

      Trying to setup FOG from scratch in a complete new VM with CentOS 7 (fully updated) the installer failed with:

       * Setting up fog user.........................................OK
       * Setting up fog password.....................................Failed!
      

      Looking into what’s going on I found that passwd seams to be unhappy with reading the password input from a file. At first I thought this might be an issue because I am running the script via SSH but trying the same on the console is still giving me the same error:

      $ cat tmppass 
      mypassword
      mypassword
      $ passwd fog <tmppass 
      Changing password for user fog.
      New password: Password change aborted.
      New password: Password change aborted.
      New password: Password change aborted.
      passwd: Have exhausted maximum number of retries for service
      

      So far I have no idea why it works when running it through a pipe instead of reading it straight vom stdin… anyone an idea?

      $ cat tmppass | passwd fog
      Changing password for user fog.
      New password: BAD PASSWORD: The password fails the dictionary check - it is based on a dictionary word
      Retype new password: passwd: all authentication tokens updated successfully.
      

      Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

      Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

      1 Reply Last reply Reply Quote 0
      • george1421G
        george1421 Moderator
        last edited by george1421

        The only thing that comes to mind is that there is unprintable characters in the text file that cat is either removing (or adding) to allow the passwd to accept. I’m thinking LF vs CR LF characters.

        This IS an interesting situation.

        The question would be is this a centos 7 specific issue or is this a passwd problem.

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

        1 Reply Last reply Reply Quote 0
        • S
          Sebastian Roth Moderator
          last edited by Sebastian Roth

          Is anyone able to verify this on his/her CentOS system?? Doing the same thing on Debian is working like a charm… both ways!

          $ passwd fog <tmppass 
          Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully
          $ cat tmppass | passwd fog
          Enter new UNIX password: Retype new UNIX password: passwd: password updated successfully
          

          Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

          Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

          Tom ElliottT 1 Reply Last reply Reply Quote 0
          • Tom ElliottT
            Tom Elliott @Sebastian Roth
            last edited by

            @Sebastian-Roth I’m not using a CentOS fog server right now, but I am using Fedora and not seeing any issues. I’ll see if I can replicate on my CentOS 7 box though.

            Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

            Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

            Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

            1 Reply Last reply Reply Quote 0
            • george1421G
              george1421 Moderator
              last edited by

              I have both centos 6 and 7 I can test one give me a minute to finish my first cup of coffee.

              Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

              1 Reply Last reply Reply Quote 1
              • george1421G
                george1421 Moderator
                last edited by george1421

                Here is on centos 7

                $ uname -a
                Linux turbodog 3.10.0-327.10.1.el7.x86_64 #1 SMP Tue Feb 16 17:03:50 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
                $ vi tmppass
                $ passwd gof <tmppass
                Changing password for user gof.
                New password: Retype new password: passwd: all authentication tokens updated successfully.
                $ cat tmppass | passwd gof
                Changing password for user gof.
                New password: Retype new password: passwd: all authentication tokens updated successfully.
                
                

                Here is for centos 6.7

                $ uname -a
                Linux mudbug 2.6.32-573.18.1.el6.x86_64 #1 SMP Tue Feb 9 22:46:17 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
                $ vi tmppass
                $  passwd gof <tmppass
                Changing password for user gof.
                New password: Retype new password: passwd: all authentication tokens updated successfully.
                $ cat tmppass | passwd gof
                Changing password for user gof.
                New password: Retype new password: passwd: all authentication tokens updated successfully.
                

                In both cases it appears to work as intended.

                Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

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

                  Centos7 storage node test

                  [root@fogstoragenode ~]# useradd test
                  [root@fogstoragenode ~]# nano password
                  [root@fogstoragenode ~]# passwd test <password
                  Changing password for user test.
                  New password: BAD PASSWORD: The password fails the dictionary check - it is based on a dictionary word
                  Retype new password: passwd: all authentication tokens updated successfully.
                  [root@fogstoragenode ~]# cat password | passwd test
                  Changing password for user test.
                  New password: BAD PASSWORD: The password fails the dictionary check - it is based on a dictionary word
                  Retype new password: passwd: all authentication tokens updated successfully.
                  

                  I tried it again after that in case it would have trouble overwriting the old password, but that gave the same output.

                  1 Reply Last reply Reply Quote 0
                  • S
                    Sebastian Roth Moderator
                    last edited by Sebastian Roth

                    Screw this !!! I think this was happening because I haven’t properly disabled SElinux on that machine! Really strange that this would cause such a weird thing.

                    setenforce 0 and now both ways work for me as well. Thanks a lot for testing and your answers!

                    Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                    Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                    Wayne WorkmanW 1 Reply Last reply Reply Quote 2
                    • Wayne WorkmanW
                      Wayne Workman @Sebastian Roth
                      last edited by Wayne Workman

                      @Sebastian-Roth
                      https://wiki.fogproject.org/wiki/index.php?title=CentOS_7
                      😉

                      Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!
                      Daily Clean Installation Results:
                      https://fogtesting.fogproject.us/
                      FOG Reporting:
                      https://fog-external-reporting-results.fogproject.us/

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

                      153

                      Online

                      12.0k

                      Users

                      17.3k

                      Topics

                      155.2k

                      Posts
                      Copyright © 2012-2024 FOG Project