Unable to login with nagiosadmin

This support forum board is for support questions relating to Nagios Log Server, our solution for managing and monitoring critical log data.
dfsocha
Posts: 14
Joined: Tue Aug 29, 2017 9:46 am

Re: Unable to login with nagiosadmin

Post by dfsocha »

Perry,

I'm doing the commands now and grabbing the files from the server and bringing them to my Windows machine and will send you a private message with the files.

FYI, the first command produced the following result:

Code: Select all

[root@NagiosLogServer scripts]# tar -czvf /tmp/logs.tar.gz /usr/local/nagioslogserver/var/auditlog.log /var/log/httpd/ /var/log/apache2/
tar: Removing leading `/' from member names
/usr/local/nagioslogserver/var/auditlog.log
/var/log/httpd/
/var/log/httpd/access_log-20211024
/var/log/httpd/error_log-20211128
/var/log/httpd/error_log-20211205
/var/log/httpd/access_log-20211209
/var/log/httpd/access_log-20211212
/var/log/httpd/error_log-20211212
/var/log/httpd/access_log-20211220
/var/log/httpd/access_log
/var/log/httpd/error_log-20211220
/var/log/httpd/error_log
tar: /var/log/apache2: Cannot stat: No such file or directory
tar: Exiting with failure status due to previous errors

Not sure if that's OK or not but I'll send the files I have. The 2nd command did create a large file so I will send them in a separate pm (one for each file) as requested.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Unable to login with nagiosadmin

Post by pbroste »

Hello @dfsocha

Thanks for following up, appears that we are missing a field and to create a user account looks like the following. In the example we are setting up a new user account reference number 3.

First, let's verify that another user account is already associated with 3; if so please make adjustments:

Code: Select all

curl -XGET http://localhost:9200/nagioslogserver/user/3
If the results are false then we are good to go to create new user account:

Code: Select all

curl -XPUT 'http://localhost:9200/nagioslogserver/user/3' -d '{"username":"nagiosadmin3","username_lower":"nagiosadmin3","name":"Nagios Administrator","password":"280d44ab1e9f79b5cce2dd4f58f5fe91f0fbacdac9f7447dffc318ceb79f2d02","auth_type":"admin","email":"dfsocha@nagios.com","language":"default","apiaccess":"1","apikey":"721d387b623e725076b68b4760489ead197ddb7b","created":"2021-06-14 12:10:14","created_by":0,"default_dashboard":"/dashboard/elasticsearch/AXoLSc8Q5hxpyzbmI-kt"}'
Make sure that you see the following results:
{"_index":"nagioslogserver","_type":"user","_id":"3","_version":1,"created":true}
Login with nagiosadmin3 with password: welcome

Thanks,
Perry
dfsocha
Posts: 14
Joined: Tue Aug 29, 2017 9:46 am

Re: Unable to login with nagiosadmin

Post by dfsocha »

That worked and I'm back in!

Thank you!
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Unable to login with nagiosadmin

Post by pbroste »

Excellent @dfsocha, that is good to hear. I will go ahead and lock this post.

Please let us know if there is anything further,
Perry
Locked