Page 1 of 1

URL was not found on this server

Posted: Sun Apr 18, 2021 11:39 am
by jenglish
Fresh kick of RHEL8 using offline installation instructions.
https://support.nagios.com/kb/article/n ... n-737.html
Capture.PNG

Code: Select all

[root@boyvlp-nonna01 nagiosna]# find / -name nagiosna -type d -ls
 25165954      4 drwxr-xr-x   7  root     root         4096 Apr 16 22:15 /tmp/nagiosna
 16797890      0 drwxr-xr-x   6  root     root           72 Mar 16 14:49 /tmp/nagiosna/nagiosna
   177817      0 drwxrwxr-x   7  nna      nnacmd        101 Apr 16 22:15 /usr/local/nagiosna
 16803898      4 drwx------   2  mysql    mysql        4096 Apr 18 16:00 /var/lib/mysql/nagiosna
      866      0 drwxr-xr-x   5  root     root           67 Apr 16 22:14 /var/www/html/nagiosna
134339523      0 drwxrwxr-x   2  nna      nnacmd          6 Apr 16 22:15 /store/backups/nagiosna

[root@boyvlp-nonna01 ~]# getenforce
Disabled

Re: URL was not found on this server

Posted: Mon Apr 19, 2021 9:58 am
by ssax
Please attach the full install.log from the system so we can see what occurred, it should be in the directory you ran ./fullinstall from.

What is the output of these commands?

Code: Select all

ls -l /var/www/html/nagiosna/application/controllers/install.php
ls -l /var/www/html/nagiosna/application/views/setup/install.php
Please run this command and attach the resulting /tmp/HTTPDFILES.zip file:

Code: Select all

zip -r /tmp/HTTPDFILES.zip /etc/httpd/conf/httpd.conf /etc/httpd/conf.d

Re: URL was not found on this server

Posted: Mon Apr 19, 2021 12:34 pm
by jenglish

Code: Select all

[jenglish@boyvlp-nonna01 ~]$ ls -l /var/www/html/nagiosna/application/controllers/install.php
-rw-r--r--. 1 root root 67877 Apr 16 18:14 /var/www/html/nagiosna/application/controllers/install.php
[jenglish@boyvlp-nonna01 ~]$ ls -l /var/www/html/nagiosna/application/views/setup/install.php
-rw-r--r--. 1 root root 6049 Apr 16 18:14 /var/www/html/nagiosna/application/views/setup/install.php
[jenglish@boyvlp-nonna01 ~]$

Re: URL was not found on this server

Posted: Mon Apr 19, 2021 4:54 pm
by gsmith
Hi,
Looking at the install.log it says
Error: Unable to find a match: python3-mysqlclient

Please install it using:
sudo yum install python3-mysqlclient

I also see you are missing nagiosna.conf from /etc/httpd.conf.d. I have attached one for you. Please
put it in place.

Let me know if doing those two things solves the problem.

Thanks

Re: URL was not found on this server

Posted: Tue Apr 20, 2021 10:09 am
by jenglish
I ran into that issue and addressed it already.

Code: Select all

[root@boyvlp-nonna01 conf.d]# yum info python3-mysqlclient
Updating Subscription Management repositories.
Red Hat Enterprise Linux 8 for x86_64 - BaseOS (RPMs)                                                   34 kB/s | 2.4 kB     00:00
Red Hat Satellite Tools 6.7 for RHEL 8 x86_64 (RPMs)                                                    30 kB/s | 2.1 kB     00:00
Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)                                                40 kB/s | 2.8 kB     00:00
epel-8                                                                                                  32 kB/s | 2.4 kB     00:00
Installed Packages
Name         : python3-mysqlclient
Version      : 1.4.6
Release      : 2.el8
Architecture : x86_64
Size         : 271 k
Source       : python-mysqlclient-1.4.6-2.el8.src.rpm
Repository   : @System
From repo    : OPM-EIS_EPEL_7_epel-8
Summary      : MySQL/mariaDB database connector for Python
URL          : https://github.com/PyMySQL/mysqlclient-python
License      : GPLv2
Description  : MySQLdb is an interface to the popular MySQL database server that provides
             : the Python database API.

[root@boyvlp-nonna01 conf.d]#
Weird. I have the nagiosna.conf here:

Code: Select all

[jenglish@boyvlp-nonna01 ~]$ unzip -l /tmp/HTTPDFILES.zip
Archive:  /tmp/HTTPDFILES.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
    11899  06-15-2020 07:49   etc/httpd/conf/httpd.conf
        0  04-16-2021 18:14   etc/httpd/conf.d/
      400  06-15-2020 07:55   etc/httpd/conf.d/README
     1618  11-08-2019 02:22   etc/httpd/conf.d/php.conf
     2926  06-15-2020 07:51   etc/httpd/conf.d/autoindex.conf
     1252  06-15-2020 07:49   etc/httpd/conf.d/userdir.conf
      516  06-15-2020 07:49   etc/httpd/conf.d/welcome.conf
     8720  06-15-2020 07:49   etc/httpd/conf.d/ssl.conf
      441  04-16-2021 18:14   etc/httpd/conf.d/nagiosna.conf
---------                     -------
    27772                     9 files
[jenglish@boyvlp-nonna01 ~]$

Re: URL was not found on this server

Posted: Tue Apr 20, 2021 5:00 pm
by ssax
I just labbed this up and it worked properly, your install.log looks good too.

Run this command as root and then try again:

Code: Select all

systemctl restart httpd php-fpm
Does it work if you go to this url? (https, try without https as well)

Code: Select all

https://X.X.X.X/nagiosna/
What is the output of this command?

Code: Select all

sestatus
Do you have any security software installed on the NNA server?

If you run this from an SSH session to the NNA server, what is the full output?

Code: Select all

curl -k -L -vvv 'http://127.0.0.1/nagiosna/'
curl -k -L -vvv 'http://127.0.0.1/nagiosna/install'
Run this command as root and leave it running:

Code: Select all

tail -Fn0 /var/log/httpd/error_log /var/log/httpd/ssl_error_log /var/log/php-fpm/error.log
Then reload the page in the web browser a couple times and send the full output of the still running tail command above.

Thank you!