Forgot nagiosna password

This support forum board is for support questions relating to Nagios Network Analyzer, our network traffic and bandwidth analysis solution.
Locked
dais
Posts: 9
Joined: Fri Jul 20, 2018 5:02 am

Forgot nagiosna password

Post by dais »

I've tried to login to http://localhost/nagiosna/login
But I forgot password and tried to reset,

It keeps loading after giving Username nna and it shows:
Screenshot from 2018-08-04 16-08-03.png
I've entered correct Username. How to reset password?
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Forgot nagiosna password

Post by tgriep »

There is a script you can use to reset the password.
Login to the NNA server as root and go to this folder.

Code: Select all

/usr/local/nagiosna/scripts
Run this script below, replacing newpassword with your new password.

Code: Select all

./reset_nagiosadmin_password.sh -p newpassword
Then you should be able to login to the NNA GUI with the new password.
Be sure to check out our Knowledgebase for helpful articles and solutions!
dais
Posts: 9
Joined: Fri Jul 20, 2018 5:02 am

Re: Forgot nagiosna password

Post by dais »

tgriep wrote:There is a script you can use to reset the password.
Login to the NNA server as root and go to this folder.

Code: Select all

/usr/local/nagiosna/scripts
Run this script below, replacing newpassword with your new password.

Code: Select all

./reset_nagiosadmin_password.sh -p newpassword
Then you should be able to login to the NNA GUI with the new password.
It says:

Code: Select all

/usr/local/nagiosna/scripts# ./reset_nagiosadmin_password.sh -p passwd
./reset_nagiosadmin_password.sh: 35: [: passwd: unexpected operator
./reset_nagiosadmin_password.sh: 49: ./reset_nagiosadmin_password.sh: Bad substitution
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Forgot nagiosna password

Post by tgriep »

Your default shell may not be bash and we need to change the script to use it.

Edit the reset_nagiosadmin_password.sh script and change the top line from

Code: Select all

#!/bin/sh
to

Code: Select all

#!/bin/bash
Save it out and try and reset the password again.
Be sure to check out our Knowledgebase for helpful articles and solutions!
dais
Posts: 9
Joined: Fri Jul 20, 2018 5:02 am

Re: Forgot nagiosna password

Post by dais »

tgriep wrote:Your default shell may not be bash and we need to change the script to use it.

Edit the reset_nagiosadmin_password.sh script and change the top line from

Code: Select all

#!/bin/sh
to

Code: Select all

#!/bin/bash
Save it out and try and reset the password again.

The new password is set after modifying in reset_nagiosadmin_password.sh script from #!/bin/sh to #!/bin/bash.

Code: Select all

./reset_nagiosadmin_password.sh -p newpassword
It worked!
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Forgot nagiosna password

Post by tgriep »

That is good news. I'll close and lock the post as solved. Feel free to open a new post for any new issues.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked