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

    lightdm user detected, wont change hostname

    Scheduled Pinned Locked Moved Unsolved
    Linux Problems
    3
    12
    609
    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.
    • P
      pilipp_edv
      last edited by pilipp_edv

      We use FOG to deploy linux machines. After the image has been deployed, the FOG Service needs to change the hostname.
      This works perfectly fine on windows, on linux the lightdm user gets detected:

      ------------------------------------------------------------------------------
      ----------------------------------UserTracker---------------------------------
      ------------------------------------------------------------------------------
       04.10.2024 13:17:29 Client-Info Client Version: 0.13.0
       04.10.2024 13:17:29 Client-Info Client OS:      Linux
       04.10.2024 13:17:29 Client-Info Server Version: 1.5.10
       04.10.2024 13:17:29 Middleware::Response Success
       04.10.2024 13:17:29 Middleware::Communication URL: https://fog.lan/fog/service/usertracking.report.php?action=login&user=tcimagehost\lightdm&mac=<MAC>&newService&json
      

      this causes the hostname changer module to not change the hostname:

      ------------------------------------------------------------------------------
      --------------------------------HostnameChanger-------------------------------
      ------------------------------------------------------------------------------
       04.10.2024 13:15:54 Client-Info Client Version: 0.13.0
       04.10.2024 13:15:54 Client-Info Client OS:      Linux
       04.10.2024 13:15:54 Client-Info Server Version: 1.5.10
       04.10.2024 13:15:54 Middleware::Response Success
       04.10.2024 13:15:54 HostnameChanger Users still logged in and enforce is disabled, delaying any further actions
      ------------------------------------------------------------------------------
      

      In “FOG Configuration -> FOG Settings -> Active Directory Defaults” the checkmark is set by “ENFORCE HOST CHANGES”.

      In “FOG Configuration -> FOG Settings -> FOG Client - Task Reboot” the checkmarks are set by “Client Taskreboot enabled” and “Task Force Reboot”.

      Going to “Hosts -> <Host> -> Active Directory” and enabling “Name Change/AD Join Forced reboot?” fixes the issue, but I don’t know how to force this for all hosts by default, especially including new hosts.

      FOG Version 1.5.10
      FOG Client Version 0.13.0

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

        @pilipp_edv FOG Configuration Page -> FOG Settings -> FOG_ENFORCE_HOST_CHANGES will set this globally, though for existing hosts it may need to be enabled as well.

        If this is okay for all hosts, just create a group -> add all hosts to the group -> then set up things in the same way from the group to enable this setting for all hosts that already exist.

        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

        P 1 Reply Last reply Reply Quote 0
        • P
          pilipp_edv @Tom Elliott
          last edited by

          @Tom-Elliott thanks for the reply, but there is no “FOG_ENFORCE_HOST_CHANGES” in FOG Configuration -> FOG Settings, only “ENFORCE HOST CHANGES” under FOG Configuration -> FOG Settings -> Active Directory Defaults and that one is already ticked.
          Either that or I’m just blind.

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

            @pilipp_edv That’s the same thing.

            In the DB the actual name is FOG_ENFORCE_HOST_CHANGES, and for 1.5.x we tried to do some fancy things by replacing _ with and removed the first FOG

            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

            P 1 Reply Last reply Reply Quote 0
            • P
              pilipp_edv @Tom Elliott
              last edited by

              @Tom-Elliott but why is it not enforced despite that setting being enabled?

              Tom ElliottT AUTH IT CenterA 2 Replies Last reply Reply Quote 0
              • Tom ElliottT
                Tom Elliott @pilipp_edv
                last edited by Tom Elliott

                @pilipp_edv I don’t know. The hosts don’t have that thing checked. Maybe there’s a bug, but I don’t know.

                What I do know is that the individual host is supposed to have it checked. I thought the value there effectively worked as a global toggle.

                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

                AUTH IT CenterA 1 Reply Last reply Reply Quote 0
                • AUTH IT CenterA
                  AUTH IT Center @pilipp_edv
                  last edited by

                  @pilipp_edv

                  can you check the services tab on your dashboard? Is the hostname changer ticked?

                  f50e548f-5c38-4340-a0f7-4eca01ad666d-image.png

                  also how is the host created in the first place (manually, autoregister, api?)

                  P 1 Reply Last reply Reply Quote 0
                  • P
                    pilipp_edv @AUTH IT Center
                    last edited by

                    @AUTH-IT-Center the hostname changer is enabled, yes. The hosts are created via full registration and inventory. Using the group-based workaround provided by @Tom-Elliott works so far.

                    I think there are two problems here, the fog client detects the lightdm linux user and stops and the settings don’t get applied to clients from FOG Configuration -> FOG Settings -> Active Directory defaults.

                    Note that we don’t join the clients to our domain, we only change their hostname.

                    AUTH IT CenterA 1 Reply Last reply Reply Quote 0
                    • AUTH IT CenterA
                      AUTH IT Center @pilipp_edv
                      last edited by

                      @pilipp_edv

                      for the record the Active Directory is working only for the Windows clients as described in the FOG client repo but as you said you don’t want them to join only rename. Since we are discussing for linux clients maybe that is the clue for not being enabled by default.

                      The database cells hostUseAD and hostEnforce are the ones that enable the procedure to occur. Another test would be to add a host and check what value it has on the dB for hosts.hostUseAD and hosts.hostEnforce without adding the host to the group or changing anything from the dashboard.

                      Tom ElliottT 1 Reply Last reply Reply Quote 0
                      • Tom ElliottT
                        Tom Elliott @AUTH IT Center
                        last edited by

                        @AUTH-IT-Center hostEnforce falls under the UI for AD stuff because initially this was thought to only be required for Domain Joins (as hostname, restart, domain join, restart) would generally be the order of things. Then we extended the client to work on Mac OS and Linux. However, we just never moved the “enforce” changes.

                        Why? Domain joins for all systems also require reboots, so this “checkbox” is needed for both AD stuff and just baseline Hostname changes.

                        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 1
                        • AUTH IT CenterA
                          AUTH IT Center @Tom Elliott
                          last edited by

                          @Tom-Elliott

                          today I had to add some hosts (manually) and the force reboot was indeed checked when I added the hostname and mac address.

                          71deac24-92b1-49b1-acc4-bfd75dc53787-image.png

                          Is it possible that the registration from the FOS client doesn’t apply it on host creation?

                          Tom ElliottT 1 Reply Last reply Reply Quote 0
                          • Tom ElliottT
                            Tom Elliott @AUTH IT Center
                            last edited by

                            @AUTH-IT-Center That is correct. That’s what that FOG Settings item is meant to do. If that is checked, on registration it should set that flag on future registrations, but it doesn’t on existing hosts that were registered before it was checked. If after this is checked and a new host registers and this isn’t working, I would believe there to be a bug.

                            Though a workaround exists, so while, it would be a bug, it may not be the biggest concern to get fixed immediately over say actual imaging issues.

                            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 1
                            • 1 / 1
                            • First post
                              Last post

                            219

                            Online

                            12.0k

                            Users

                            17.3k

                            Topics

                            155.2k

                            Posts
                            Copyright © 2012-2024 FOG Project