How to I change my login username??

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
psyllex
Posts: 129
Joined: Thu Dec 20, 2012 2:18 pm

How to I change my login username??

Post by psyllex »

I have other people who are logging in as admin so I would just like to have one universal username and password for those who need to log into Nagios.

I tried going to:

Code: Select all

/usr/local/nagios/etc/htpasswd.users
And change the user name from there but when i changed it....it didn't allow me to actually view my network...it said I needed to change the cgi file.

Is there a simply way to do this?
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: How to I change my login username??

Post by sreinhardt »

Code: Select all

htpasswd /usr/local/nagios/etc/htpasswd.users [NewUserHere]
Running the htpasswd command again without -c should allow you add or modify users and their passwords that have access to nagios. This is all you should need to do to add more users within core.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
lesnikov
Posts: 28
Joined: Sat Jan 19, 2013 10:40 pm
Location: Slovenia

Re: How to I change my login username??

Post by lesnikov »

hi.
i had the same problem. this is how i make it work

Code: Select all

htpasswd /usr/local/nagios/etc/htpasswd.users NEWUSER
and then add these lines to cgi.cfg and restart nagios

Code: Select all

authorized_for_system_information=NEWUSER
authorized_for_configuration_information=NEWUSER
authorized_for_system_commands=NEWUSER
authorized_for_all_services=NEWUSER
authorized_for_all_hosts=NEWUSER
authorized_for_all_service_commands=NEWUSER
authorized_for_all_host_commands=NEWUSER
I dont know if it is the right way but it works :P
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: How to I change my login username??

Post by slansing »

Thanks for the input lesnikov :) He should be able to get it changed between these two posts.
Locked