Nagios /nagvis - SSO

Hello,

I would like to setup a unified authenfication between Nagios and Nagvis.
(to avoid to login twice when you move from Nagios to Nagvis)

In the Nagvis documentation, it is not clear how to do;

Could you explain me how to do it?
Do you have an example?

Thanks

Didier :?

if you only use nagiosadmin: nagvis.org/docs/general/faq#anchor2

the solutions :

" mod_rewrite
The following mod_rewrite config maps the user “nagiosadmin” to NagVis:

RewriteEngine on
RewriteLock var/log/rewrite.lck
RewriteLog /dev/null
RewriteLogLevel 0

The following line is the really important step,

it tells the webserver that the user “nagiosadmin” has

successfully authenticated and is sending the request,

regardless who is sending it really.

RewriteRule /nagvis/ - [E=REMOTE_USER:nagiosadmin]"

[size=150]===> Question: in which file, you insert these lines???[/size]

".htaccess
A second way to “disable” the authentication is setting the variable REMOTE_USER via .htaccess file. Place a file called .htaccess with the following content in the NagVis root directory:

SetEnv REMOTE_USER nagiosusername"

[size=150]===> I have inserted this line in the .htaccess file in Nagvis root directory. Nagvis still need an authentification.[/size]

Any ideas???

Thanks

check your apache documentation.

.htaccess can work if they are enabled in the apache configuration file which is where you should put the lines in the first part, files which you have configured to enable nagvis…

in debian the confgi files are located in the /etc/apache2/sites-available directory

Hope this helps.

I have included the following lines in /etc/apache2/sites-available/default:

<Directory "/usr/local/nagvis">
    SetEnv REMOTE_USER nagiosusername
    Order Deny,Allow
    Deny from ALL
</Directory>

Now I don’t need to login but I don’t see my maps !!!

Any ideas???

Attached a screenshot!

Honestly it looks like you don’t know what you are trying to do…

SetEnv REMOTE_USER nagiosusername

nagiosusername probably needs to be substituted with nagiosadmin.

I realy hope you have a backup of your old config files.

You are right.
That was not clear for a novice

but now it works

Thanks

I’d recommend you look back at the configurations for nagios and nagvis (an dmaybe look for an intro to the apache config files) so you get a better idea of what you changed and why it works as it does now :slight_smile:

“Breaking” stuff is way too easy on these systems :slight_smile: