Overview
You may find the MGR GUI not working correctly when the MGR is up and running. You could also see
Not Found
The requested URL was not found on this server.
This article provides information on the possible root cause of this issue and how to make sure that the issue is related to the supposed root cause. Moreover, it provides the steps to resolve this issue.
Root Cause
- This issue is usually caused by a dead MGR subprocess.
- This issue could also be caused by the Apache HTTP server's ability to bind to a socket:
Diagnosis
To confirm if the root cause of the issue is a dead MGR subprocess, follow the steps below:
- Run the following command as the root user:
systemctl status mgr
- Check if the MGR status is inactive (dead). Please see the example output below.
mgr.service - MGR - An OAM element Loaded: loaded (/etc/systemd/system/mgr.service; enabled; vendor preset: disabled) Active: inactive (dead) since Thu 2020-02-20 09:55:29 CET; 1 weeks 4 days ago Process: 19153 ExecStop=/usr/TextPass/bin/tp_mgr_stop (code=exited, status=0/SUCCESS) Process: 20045 ExecStart=/usr/TextPass/bin/tp_mgr_start (code=exited, status=0/SUCCESS) Process: 20031 ExecStartPre=/usr/TextPass/bin/tp_mgr_stop (code=exited, status=0/SUCCESS) Main PID: 20086 (code=exited, status=0/SUCCESS)
If the inactive (dead) status is shown despite the MGR being active, there is a dead subprocess. Please continue with the resolution by following the steps provided in the next section. - Check the output logs in the result of the status check
Oct 03 07:10:33 vlielandvm1 tp_mgr_stop[7293]: All processes finished.
Oct 03 07:10:33 vlielandvm1 tp_mgr_start[7309]: Starting with clean XML cache
Oct 03 07:10:35 vlielandvm1 tp_mgr_start[7309]: No peerfserver defined in '/...'
Oct 03 07:10:35 vlielandvm1 tp_mgr_start[7309]: Continuing as stand-alone Master
Oct 03 07:10:48 vlielandvm1 tp_mgr_start[7309]: (98)Address already in use: ...0
Oct 03 07:10:48 vlielandvm1 tp_mgr_start[7309]: (98)Address already in use: ...0
Oct 03 07:10:48 vlielandvm1 tp_mgr_start[7309]: no listening sockets availab...n
Oct 03 07:10:48 vlielandvm1 tp_mgr_start[7309]: AH00015: Unable to open logs
Oct 03 07:10:48 vlielandvm1 tp_mgr_start[7309]: Could not start apache with ....
Oct 03 07:10:48 vlielandvm1 systemd[1]: Started MGR - An OAM element.
Resolution
- Stop all the MGR processes by running the following command as the root user:
/usr/TextPass/bin/tp_mgr_stop
- Wait for the "All processes finished" message, which indicates that all the processes are shut down.
- Restart the MGR service and all the subprocesses by executing the following command:
systemctl start mgr
- If you still see the errors regarding the "Address already in use" perform the below steps as root user.
-
Identify the Process Using Port 80: You can use the following command to identify the exact process using port 80 (Replace
80
with the specific port if different. This will show which process is occupying the port.)lsof -i :80
This will show you the process and its PID (process ID) associated with port 80.
-
Stop the Conflicting Process: Once you identify the process from the output of the
lsof
command, you can stop it by killing the processes or stopping the httpd service:systemctl stop httpd
-
Check if Port 80 is Free: After killing the process or stopping the service, rerun the
netstat
command to verify that port 80 is no longer in use:netstat -tuln | grep :80
-
Restart MGR: Now that port 80 is available, try restarting the MGR service:
systemctl restart mgr
- This should allow MGR to bind to port 80 successfully and resolve the "Address already in use" issue.
-
Confirmation
- Recheck the MGR status by running the following command as the root user:
systemctl status mgr
- Check if the MGR status is active (running). Please see the example output below.
mgr.service - MGR - An OAM element
Loaded: loaded (/etc/systemd/system/mgr.service; enabled; vendor preset: disabled)
Active: active (running) since Fri 2024-10-04 08:02:33 -04; 2 days ago
Process: 8180 ExecStop=/usr/TextPass/bin/tp_mgr_stop (code=exited, status=0/SUCCESS)
Process: 8222 ExecStart=/usr/TextPass/bin/tp_mgr_start (code=exited, status=0/SUCCESS)
Process: 8206 ExecStartPre=/usr/TextPass/bin/tp_mgr_stop (code=exited, status=0/SUCCESS)
Main PID: 8271 (/usr/sbin/httpd)
CGroup: /textpass_oam.slice/mgr.service
├─ 8271 /usr/sbin/httpd -f /var/TextPass/MGR/conf/MGR.conf -DSSL
├─ 8272 /usr/sbin/rotatelogs /var/TextPass/MGR/logs/mgr_error_log ...
├─ 8374 /usr/sbin/rotatelogs /var/TextPass/MGR/logs/mgr_ssl_reques...
├─13352 /usr/sbin/httpd -f /var/TextPass/MGR/conf/MGR.conf -DSSL
└─31529 /usr/sbin/httpd -f /var/TextPass/MGR/conf/MGR.conf -DSSL
Oct 04 08:02:11 vlielandvm1 tp_mgr_stop[8206]: Stopping MGR Device Poller...
Oct 04 08:02:11 vlielandvm1 tp_mgr_stop[8206]: Stopping App Quota Manager...
Oct 04 08:02:11 vlielandvm1 tp_mgr_stop[8206]: All processes finished.
Oct 04 08:02:11 vlielandvm1 tp_mgr_start[8222]: Starting with clean XML cache
Oct 04 08:02:13 vlielandvm1 tp_mgr_start[8222]: No peerfserver defined in '/...'
Oct 04 08:02:13 vlielandvm1 tp_mgr_start[8222]: Continuing as stand-alone Master
Oct 04 08:02:28 vlielandvm1 tp_mgr_start[8222]: MGR started...
Oct 04 08:02:33 vlielandvm1 systemd[1]: Started MGR - An OAM element. - Check if the MGR GUI works properly.