Page 1 of 1

Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Thu Feb 08, 2024 4:55 pm
by NVESMM
Hello.

We are recently having issues logging into the Web GUI for our test environment for our nagios log server with all accounts including our nagiosadmin account. Just in case, we reset the nagiosadmin account via the reset script in /usr/local/nagiosxi/scripts/reset_nagiosadmin_password.php but we are still having issues logging into it. It keeps saying invalid password when attempting log on.

We do have access to SSH and that is allowing us to log onto it just fine.
Capture.PNG
Are there any troubleshooting steps or particular logs I should be looking into?

Thank you.

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Fri Feb 09, 2024 10:40 am
by swolf
Hi @NVESMM, thanks for reaching out.

Here are some steps to try:

1. If you haven't already, try resetting nagiosadmin's password to something that doesn't contain any whitespace or special characters. As much as this "shouldn't" be something that matters, the password you enter is going through a bash script and then into a NoSQL database that gives special treatment to whitespace, so it doesn't hurt to be safe.

2. If you're still having trouble, try rebooting the server and see if your login works immediately after that reboot.

3. If it does work after reboot, and then starts failing after a few hours, check your RAM and disk usage. When elasticsearch is low on either of these, it'll start giving bad results, which could be the cause of what you're seeing.

If you try these steps and they don't help, I'm going to recommend that you open a case so that our support team can help you troubleshoot your specific environment.

-Sebastian

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Tue Feb 13, 2024 5:01 pm
by NVESMM
Thank you!

I reset the password again using /usr/local/nagioslogserver/scripts/reset_nagiosadmin_password.sh --password newpasswordhere making sure there aren't any whitespace or special characters.

I also tried to reboot the server and attempted to log in immediately after it was up and no luck. None of our domain accounts are allowing us to log into the Web GUI either.

Do you have any other suggestions aside from the support case?

Thanks again!

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Wed Feb 14, 2024 3:13 pm
by jmichaelson
THe only thing I can think of is to have you log in to a shell on your log server and execute the following:

Code: Select all

curl http://192.168.0.74:9200/nagioslogserver/user/1
DO NOT post the output here, but notice the string of characters for the password.

Change the password using the script again to something different. Run the same command and see if the encrypted password changes. If it changes, you *should* be able to log in as nagiosadmin with that password.

If you still can't, then I'm afraid you'll have to contact support.

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Mon Apr 22, 2024 10:29 am
by riahc3
Nagios Log Server is bugged beyond use.

I recommend use using a ELK stack even though its harder.

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Mon Apr 22, 2024 1:22 pm
by jmichaelson
If there's a RAM issue with Elasticsearch in Nagios Log Server, there will be a RAM issue with any ELK stack. The good news on that front is that the Elasticsearch part is in the process of being replaced with Opensearch. We can't commit to a release date yet other than to say that its coming soon.

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Wed May 01, 2024 1:25 pm
by danderson
NVESMM wrote: Thu Feb 08, 2024 4:55 pm Hello.

We are recently having issues logging into the Web GUI for our test environment for our nagios log server with all accounts including our nagiosadmin account. Just in case, we reset the nagiosadmin account via the reset script in /usr/local/nagiosxi/scripts/reset_nagiosadmin_password.php but we are still having issues logging into it. It keeps saying invalid password when attempting log on.

We do have access to SSH and that is allowing us to log onto it just fine. Capture.PNG

Are there any troubleshooting steps or particular logs I should be looking into?

Thank you.
I also ran into this issue. Did this happen after any specific Log Server upgrade? Did you start encountering after a reboot or something similar?

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Wed May 01, 2024 2:53 pm
by danderson
After some investigation, I think I found a fix. I noticed a bug where the output of openssl was different on CentOS 9, leading to the reset script not working.

If you are willing to run some terminal commands on the log server machine, here's what you can do:

Code: Select all

newpass="examplepassword"

passhash=$(printf "$newpass" | openssl sha256 | awk '{printf $2}')

update="{\"doc\":{\"password\":\"$passhash\"}}"

curl -XPOST http://localhost:9200/nagioslogserver/user/1/_update -d "$update" > /dev/null 2>&1

curl -XPOST http://localhost:9200/nagioslogserver/_refresh > /dev/null 2>&1
This fixed the issue for me.

Re: Invalid password on Nagios Log Server Web GUI even after nagiosadmin password reset

Posted: Mon May 06, 2024 12:55 am
by Thiagoros
jmichaelson wrote: Mon Apr 22, 2024 1:22 pm If there's a RAM issue with Elasticsearch in Nagios Log Server, there will be a RAM issue with any ELK stack. The good news on that front is that the Elasticsearch part is in the process of being replaced with Opensearch. We can't commit to a release date yet other than to say that its coming soon.
It's reassuring to hear that Nagios Log Server is addressing potential RAM issues by transitioning to Opensearch, a promising development for ELK stack users. While a specific release date remains uncertain, the anticipation of this update brings hope for improved performance and reliability in the near future.