# Nagios - admin password



## BartSimpson

hi all

I am running sues linux install nagios and i cant log in to web interface. Is there a way to find what is the admin user name and password is? I have the acess to the root system and i have been search in the nagios folder but haven't any luck so far.

Thanks advance


----------



## Venkatesh.av

For Nagios 3.0b7 (development) :

Install the Nagios web config file in the Apache conf.d directory.

make install-webconf

[This step is done when you install nagios from source. If you are not clear with this, please follow the Web site link below for installing Nagios from scratch]

To create a nagiosadmin account for logging into the Nagios web interface. Remember the password you assign to this account 

htpasswd2 -c /usr/local/nagios/etc/htpasswd.users nagiosadmin

Restart Apache to make the new settings take effect.

service apache2 restart
-------------------------

Here is the link that describes how to install Nagios on OpenSuSe

http://nagios.sourceforge.net/docs/3_0/quickstart-opensuse.html

Follow the mentioned steps carefully u will get Nagios worked. Use Nagios 3.0b7 (development) - sounds better than Nagios 2.10 (stable)


----------



## BartSimpson

Hi

thanks for reply . I already install and forget the password log into the admin. Is there anyway i can find out what is the password and username is

Thanks


----------



## Venkatesh.av

Yes, of course, we can find such information in the file 'htpasswd.users' file located in the following directory '/usr/local/nagios/etc'. The file contains the user name, but u will find the password in encrypted form. Do you know any method to decrypt the password or does decrypting the password will help you to retrieve the actual password? I am not aware about it. 

Anyway here is the method to create another user for the Nagios web interface

Please try this 

At shell prompt as root user, 

htpasswd2 -c /usr/local/nagios/etc/htpasswd.users nagiosadmin

Set a new user called 'nagiosadmin', when you run this command it will ask you to set a password for the user 'nagiosadmin' . set the new password and you are done.


Note: htpasswd2 is a command, sometime linux will say 'htpasswd2:command not found' . In such case , use the command 'htpasswd'. That is like this 

htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin

Hope you will get it done now.

Good Luck

Thank You Very Much for your Response


----------



## BartSimpson

Venkatesh.av said:


> Yes, of course, we can find such information in the file 'htpasswd.users' file located in the following directory '/usr/local/nagios/etc'. The file contains the user name, but u will find the password in encrypted form. Do you know any method to decrypt the password or does decrypting the password will help you to retrieve the actual password? I am not aware about it.
> 
> Anyway here is the method to create another user for the Nagios web interface
> 
> Please try this
> 
> At shell prompt as root user,
> 
> htpasswd2 -c /usr/local/nagios/etc/htpasswd.users nagiosadmin
> 
> Set a new user called 'nagiosadmin', when you run this command it will ask you to set a password for the user 'nagiosadmin' . set the new password and you are done.
> 
> 
> Note: htpasswd2 is a command, sometime linux will say 'htpasswd2:command not found' . In such case , use the command 'htpasswd'. That is like this
> 
> htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin
> 
> Hope you will get it done now.
> 
> Good Luck
> 
> Thank You Very Much for your Response



Hi

Thanks for reply again 

I tried to create another user, and i follow your instuction and the first one is not work...all dilay "usage" and the second keep said" htpasswd2: command not found"


is there another way to create user or did do anything wrong? i am running sues 10.2v


----------

