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

Changing hostname from fog broken

Scheduled Pinned Locked Moved
FOG Problems
3
19
1.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.
  • S
    Sebastian Roth Moderator
    last edited by May 25, 2021, 7:24 AM

    @dejv The Apache log seems to be very recent (“May 24”). Depending on log rotation the errors might be in an older log file. See what you have in /var/log/apache/… Or make sure the fog-client is still trying to access the server. In that case we should still see more recent errors in the logs.

    The PHP-FPM log looks very old on the other hand. No idea why the log ends in October 2020?!

    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

    D 1 Reply Last reply May 25, 2021, 10:50 AM Reply Quote 0
    • D
      dejv @Sebastian Roth
      last edited by dejv May 25, 2021, 4:54 AM May 25, 2021, 10:50 AM

      @sebastian-roth If I redownload Fog and reinstall it will it fix the issue? (hopefully it will keep all settings)

      1 Reply Last reply Reply Quote 0
      • S
        Sebastian Roth Moderator
        last edited by May 25, 2021, 7:38 PM

        @dejv said in Changing hostname from fog broken:

        If I redownload Fog and reinstall it will it fix the issue?

        Well, without further information we don’t know what is causing the problem. Therefore I can’t tell you if re-installing will help either.

        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
        • D
          dejv
          last edited by May 26, 2021, 10:45 AM

          Tried redownloading and installing fog as its pretty easy and straightforward however still same issue.

          [Tue May 25 00:00:04.404259 2021] [mpm_prefork:notice] [pid 801] AH00163: Apache/2.4.41 (Ubuntu) OpenSSL/1.1.1f configured -- resuming normal operations
          [Tue May 25 00:00:04.404282 2021] [core:notice] [pid 801] AH00094: Command line: '/usr/sbin/apache2'
          [Wed May 26 00:00:06.516283 2021] [mpm_prefork:notice] [pid 801] AH00171: Graceful restart requested, doing restart
          AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
          
          [Mon May 24 00:00:07.495210 2021] [mpm_prefork:notice] [pid 801] AH00163: Apache/2.4.41 (Ubuntu) OpenSSL/1.1.1f configured -- resuming normal operations
          [Mon May 24 00:00:07.495231 2021] [core:notice] [pid 801] AH00094: Command line: '/usr/sbin/apache2'
          [Tue May 25 00:00:03.853271 2021] [mpm_prefork:notice] [pid 801] AH00171: Graceful restart requested, doing restart
          AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
          
          [Thu May 20 00:00:07.690477 2021] [mpm_prefork:notice] [pid 801] AH00163: Apache/2.4.41 (Ubuntu) OpenSSL/1.1.1f configured -- resuming normal operations
          [Thu May 20 00:00:07.690497 2021] [core:notice] [pid 801] AH00094: Command line: '/usr/sbin/apache2'
          [Thu May 20 14:46:05.550377 2021] [proxy:error] [pid 901639] (111)Connection refused: AH00957: FCGI: attempt to connect to 127.0.0.1:9000 (*) failed
          [Thu May 20 14:46:05.556623 2021] [proxy_fcgi:error] [pid 901639] [client 192.168.0.254:49042] AH01079: failed to make connection to backend: 127.0.0.1
          [Thu May 20 14:46:05.575487 2021] [proxy:error] [pid 901622] (111)Connection refused: AH00957: FCGI: attempt to connect to 127.0.0.1:9000 (*) failed
          [Thu May 20 14:46:05.575640 2021] [proxy_fcgi:error] [pid 901622] [client 192.168.0.254:49043] AH01079: failed to make connection to backend: 127.0.0.1
          [Thu May 20 14:46:07.616286 2021] [proxy:error] [pid 901620] (111)Connection refused: AH00957: FCGI: attempt to connect to 127.0.0.1:9000 (*) failed
          [Thu May 20 14:46:07.616353 2021] [proxy_fcgi:error] [pid 901620] [client 192.168.0.254:49065] AH01079: failed to make connection to backend: 127.0.0.1
          [Thu May 20 14:46:08.280219 2021] [mpm_prefork:notice] [pid 801] AH00169: caught SIGTERM, shutting down
          [Thu May 20 14:46:42.725606 2021] [mpm_prefork:notice] [pid 801] AH00163: Apache/2.4.41 (Ubuntu) OpenSSL/1.1.1f configured -- resuming normal operations
          [Thu May 20 14:46:42.760133 2021] [core:notice] [pid 801] AH00094: Command line: '/usr/sbin/apache2'
          [Thu May 20 15:49:43.614999 2021] [proxy_fcgi:error] [pid 1133] [client 192.168.0.93:49784] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught Error: Call to a member function isValid() on null in /var/www/html/fog/lib/fog/host.class.php:305\nStack trace:\n#0 /var/www/html/fog/lib/fog/fogbase.class.php(1832): Host->save()\n#1 /var/www/html/fog/lib/client/fogclient.class.php(179): FOGBase->sendData()\n#2 /var/www/html/fog/service/register.php(32): FOGClient->__construct()\n#3 {main}\n  thrown in /var/www/html/fog/lib/fog/host.class.php on line 305'
          [Thu May 20 15:56:04.356205 2021] [proxy_fcgi:error] [pid 1896] [client 192.168.0.95:49766] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught Error: Call to a member function isValid() on null in /var/www/html/fog/lib/fog/host.class.php:305\nStack trace:\n#0 /var/www/html/fog/lib/fog/fogbase.class.php(1832): Host->save()\n#1 /var/www/html/fog/lib/client/fogclient.class.php(179): FOGBase->sendData()\n#2 /var/www/html/fog/service/register.php(32): FOGClient->__construct()\n#3 {main}\n  thrown in /var/www/html/fog/lib/fog/host.class.php on line 305'
          [Fri May 21 00:00:10.688815 2021] [mpm_prefork:notice] [pid 801] AH00171: Graceful restart requested, doing restart
          AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message
          
          
          

          I found some other files that were compressed please find above.

          The php7.4 log is all the same as posted before

          1 Reply Last reply Reply Quote 0
          • S
            Sebastian Roth Moderator
            last edited by May 27, 2021, 5:35 AM

            @dejv said in Changing hostname from fog broken:

            AH01071: Got error ‘PHP message: PHP Fatal error: Uncaught Error: Call to a member function isValid() on null in /var/www/html/fog/lib/fog/host.class.php:305\nStack trace:\n#0 /var/www/html/fog/lib/fog/fogbase.class.php(1832): Host->save()\n#1 /var/www/html/fog/lib/client/fogclient.class.php(179): FOGBase->sendData()\n#2 /var/www/html/fog/service/register.php(32): FOGClient->__construct()\n#3 {main}\n thrown in /var/www/html/fog/lib/fog/host.class.php on line 305’

            That might be a first hint on what might be causing the problem. But on the other hand I am wondering why it’s calling register.php. Is this client registered in FOG already or not?

            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

            D 1 Reply Last reply May 27, 2021, 10:27 AM Reply Quote 0
            • D
              dejv @Sebastian Roth
              last edited by May 27, 2021, 10:27 AM

              @sebastian-roth

              yes client was registered already

              1 Reply Last reply Reply Quote 0
              • S
                Sebastian Roth Moderator
                last edited by May 28, 2021, 11:28 AM

                @dejv Found some time to look into this and I think I was on the wrong track. I looked through the code and I don’t think that part can be triggered by a registered client. It does not match what we see in the fog-client log file. As well the logs posted last (that include the register.php call) are from May 20. But the fog-client log posted earlier is from May 21. Just doesn’t match.

                So let’s try to tackle this from a different angle. What happens if you open the URL http://fog/fog/service/getversion.php?clientver&newService&json in your browser on a normal work PC?

                I ask because in the fog-client log we see that URL request triggered a HTTP 502 Bad Gateway error and I am wondering if you see that when opening the URL manually as well.

                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

                D 1 Reply Last reply May 28, 2021, 12:38 PM Reply Quote 0
                • D
                  dejv @Sebastian Roth
                  last edited by dejv May 28, 2021, 6:40 AM May 28, 2021, 12:38 PM

                  @sebastian-roth

                  Thanks 🙂

                  I am getting the below number when accessesing the following link: http://192.168.0.58/fog/service/getversion.php?clientver&newService&json

                  0.12.0

                  1 Reply Last reply Reply Quote 0
                  • S
                    Sebastian Roth Moderator
                    last edited by May 29, 2021, 10:29 AM

                    @dejv said in Changing hostname from fog broken:

                    I am getting the below number when accessesing the following link: http://192.168.0.58/fog/service/getversion.php?clientver&newService&json
                    0.12.0

                    While this sounds like it does work as it should the version number is different to what we saw in the fog-client log. When you re-installed the FOG server did you use the latest dev-branch version?

                    Possibly you are hitting a different error now. Please post the latest fog-client fog.log here so we see if it’s still the same problem or a different one.

                    Are your FOG server and the client machine in the same subnet? No router, gateway or maybe proxy server in between? I ask because we had someone with very strange fog-client issues that were caused by a proxy server. The fog-client seems to be using the global Windows proxy settings.

                    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

                    D 1 Reply Last reply Jun 4, 2021, 1:28 PM Reply Quote 0
                    • D
                      dejv @Sebastian Roth
                      last edited by Jun 4, 2021, 1:28 PM

                      @sebastian-roth

                      I downloaded from : https://github.com/FOGProject/fogproject.
                      Fog server and clients are on different subnets however have been like this for around 2years, I have a sophos utm router, without proxy server

                      ------------------------------------------------------------------------------
                      ----------------------------------UserTracker---------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:24:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:24:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:24:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:24:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:24:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                       6/4/2021 3:24:23 PM Service Sleeping for 60 seconds
                       6/4/2021 3:25:23 PM Middleware::Communication URL: http://fog/fog/management/index.php?sub=requestClientInfo&configure&newService&json
                       6/4/2021 3:25:23 PM Middleware::Communication ERROR: Could not contact FOG server
                       6/4/2021 3:25:23 PM Middleware::Communication ERROR: The remote server returned an error: (502) Bad Gateway.
                       6/4/2021 3:25:23 PM Middleware::Response Success
                       6/4/2021 3:25:23 PM Service ERROR: Invalid promptTime, using default
                       6/4/2021 3:25:23 PM Middleware::Communication URL: http://fog/fog/management/index.php?sub=requestClientInfo&mac=74:D0:2B:35:33:6B&newService&json
                       6/4/2021 3:25:23 PM Middleware::Communication ERROR: Could not contact FOG server
                       6/4/2021 3:25:23 PM Middleware::Communication ERROR: The remote server returned an error: (502) Bad Gateway.
                       6/4/2021 3:25:23 PM Middleware::Response Success
                       6/4/2021 3:25:23 PM Middleware::Communication URL: http://fog/fog/service/getversion.php?clientver&newService&json
                       6/4/2021 3:25:23 PM Service ERROR: Unable to get cycle data
                       6/4/2021 3:25:23 PM Service ERROR: The remote server returned an error: (502) Bad Gateway.
                       6/4/2021 3:25:23 PM Middleware::Response Success
                      
                      ------------------------------------------------------------------------------
                      ---------------------------------ClientUpdater--------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                      
                      ------------------------------------------------------------------------------
                      ----------------------------------TaskReboot----------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                      
                      ------------------------------------------------------------------------------
                      --------------------------------HostnameChanger-------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                      
                      ------------------------------------------------------------------------------
                      ---------------------------------SnapinClient---------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                      
                      ------------------------------------------------------------------------------
                      --------------------------------PrinterManager--------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                      
                      ------------------------------------------------------------------------------
                      --------------------------------PowerManagement-------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                      
                      ------------------------------------------------------------------------------
                      ----------------------------------UserTracker---------------------------------
                      ------------------------------------------------------------------------------
                       6/4/2021 3:25:23 PM Client-Info Client Version: 0.11.19
                       6/4/2021 3:25:23 PM Client-Info Client OS:      Windows
                       6/4/2021 3:25:23 PM Client-Info Server Version: 1.5.9
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Unable to get subsection
                       6/4/2021 3:25:23 PM Middleware::Response ERROR: Object reference not set to an instance of an object.
                       6/4/2021 3:25:23 PM Service Sleeping for 60 seconds
                      
                      1 Reply Last reply Reply Quote 0
                      • S
                        Sebastian Roth Moderator
                        last edited by Jun 4, 2021, 1:48 PM

                        @dejv In the fog.log we see the hostname fog in the URL - http://fog/fog/management/… Does this hostname resolve to the IP 192.168.0.58?

                        Do you have just one FOG server (master node) or other FOG storage nodes as well?

                        Please run ls -al /var/www/{,html} as terminal command on your FOG server and post the full output here.

                        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

                        D 1 Reply Last reply Jun 8, 2021, 1:04 PM Reply Quote 0
                        • D
                          dejv @Sebastian Roth
                          last edited by dejv Jun 8, 2021, 7:05 AM Jun 8, 2021, 1:04 PM

                          @sebastian-roth said in Changing hostname from fog broken:

                          http://fog

                          http://fog/fog/management/ - doesnt seem to open
                          http://192.168.0.58/fog/management - works

                          however when I ping fog I get a reply

                          I only got 1 fog server

                          Command as requested:

                          root@fog:~# ls -al /var/www/{,html}
                          /var/www/:
                          total 16
                          drwxr-xr-x  4 root     root     4096 Jan 29  2019 .
                          drwxr-xr-x 15 root     root     4096 Jan 29  2019 ..
                          drwxr-xr-x 11 www-data www-data 4096 Jan 29  2019 fog
                          drwxr-xr-x  3 root     root     4096 Mej 26 12:24 html
                          
                          /var/www/html:
                          total 28
                          drwxr-xr-x  3 root     root      4096 Mej 26 12:24 .
                          drwxr-xr-x  4 root     root      4096 Jan 29  2019 ..
                          drwxr-xr-x 10 www-data www-data  4096 Mej 26 12:26 fog
                          -rw-r--r--  1 root     root     10918 Jan 29  2019 index.html
                          -rw-r--r--  1 www-data www-data    52 Ott  8  2020 index.php
                          root@fog:~#
                          
                          T 1 Reply Last reply Jun 8, 2021, 1:33 PM Reply Quote 1
                          • T
                            Tom Elliott @dejv
                            last edited by Sebastian Roth Jun 8, 2021, 2:53 PM Jun 8, 2021, 1:33 PM

                            @dejv Can you please run:

                            sudo -i
                            mv /var/www/fog{,_back}
                            ln -s /var/www/html/fog /var/www/fog
                            

                            This should help fix the fact that your environment sees 2 separate fog instances (one in /var/www/fog and one in /var/www/html/fog with the one in /var/www/html being the newest version.)

                            The commands I give will move the /var/www/fog to /var/www/fog_back (you can simply delete this if you feel comfortable to do so.)

                            Thank you,

                            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

                            D 1 Reply Last reply Jun 10, 2021, 9:30 AM Reply Quote 0
                            • D
                              dejv @Tom Elliott
                              last edited by Jun 10, 2021, 9:30 AM

                              @tom-elliott I tested on another computer and its working.

                              on this particular pc its not working. I will try and uninstall fog client from the pc and reinstall it again and will see if it works.

                              IF it still doesnt work will try to remove from fog server and re add

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

                              193

                              Online

                              12.0k

                              Users

                              17.3k

                              Topics

                              155.2k

                              Posts
                              Copyright © 2012-2024 FOG Project