unable to log in with nagiosadmin - new install

This support forum board is for support questions relating to Nagios Log Server, our solution for managing and monitoring critical log data.
Post Reply
sfarrell
Posts: 14
Joined: Tue Apr 20, 2021 12:02 pm

unable to log in with nagiosadmin - new install

Post by sfarrell »

New install of Nagios Logserver using the latest version. When try to log in with "nagiosadmin" I get error "Invalid username or password".

I've tried resetting the password using "/usr/local/nagioslogserver/scripts/reset_nagiosadmin_password.sh --password newpassword" but it still fails. I'm not using any special character just letters and numbers.

I have tried the following with no luck

Code: Select all

curl -XPUT 'http://localhost:9200/nagioslogserver/user/2' -d '{"username":"nagiosadmin","username_lower":"nagiosadmin","name":"Nagios Administrator","password":"280d44ab1e9f79b5cce2dd4f58f5fe91f0fbacdac9f7447dffc318ceb79f2d02","auth_type":"admin","email":"[email protected]","language":"default","apiaccess":"1","apikey":"721d387b623e725076b68b4760489ead197ddb7b","created":"2021-06-14 12:10:14","created_by":0,"default_dashboard":"/dashboard/elasticsearch/AXoLSc8Q5hxpyzbmI-kt"}'

Then

Code: Select all

curl -XGET http://localhost:9200/nagioslogserver/user/2
With output

Code: Select all

{"_index":"nagioslogserver","_type":"user","_id":"2","_version":8,"found":true,"_source":{"username":"nagiosadmin","username_lower":"nagiosadmin","name":"Nagios Administrator","password":"280d44ab1e9f79b5cce2dd4f58f5fe91f0fbacdac9f7447dffc318ceb79f2d02","auth_type":"admin","email":"[email protected]","language":"default","apiaccess":"1","apikey":"721d387b623e725076b68b4760489ead197ddb7b","created":"2021-06-14 12:10:14","created_by":0,"default_dashboard":"/dashboard/elasticsearch/AXoLSc8Q5hxpyzbmI-kt"}}

jsimon
Posts: 339
Joined: Wed Aug 23, 2023 11:27 am

Re: unable to log in with nagiosadmin - new install

Post by jsimon »

Hi @sfarrell,

I would recommend retrying the curl call from your post with a userid of 1 instead of 2. The default admin account should be getting created with an ID of 1, so it is likely you're taking the right steps but on the wrong account. Let us know if you run into any further issues with this.
sfarrell
Posts: 14
Joined: Tue Apr 20, 2021 12:02 pm

Re: unable to log in with nagiosadmin - new install

Post by sfarrell »

Thank you for your response. I changed the curl command to use user 1 instead of user 2 but I'm still having the same problem.

Is there a way to put this in debug mode so i can see a more detailed error message?
Last edited by sfarrell on Thu Dec 05, 2024 11:39 am, edited 1 time in total.
sfarrell
Posts: 14
Joined: Tue Apr 20, 2021 12:02 pm

Re: unable to log in with nagiosadmin - new install

Post by sfarrell »

I am able to log in to the gui using

Code: Select all

http://nagiosadmin:newpassword@[IPADDRESS}/nagioslogserver/
However if i log out and try to log in thru the regular login screen i get the invalid username/password error.
sfarrell
Posts: 14
Joined: Tue Apr 20, 2021 12:02 pm

Re: unable to log in with nagiosadmin - new install

Post by sfarrell »

It seems like something "clicked" and I'm now able to log in via the GUI.

Thanks for your help!
Post Reply