After upgradind centreon from 21.10 to 22.10.2, I ‘ve got an error in the web interface (and when I execute the command directrly from the server)
![](https://uploads-eu-west-1.insided.com/centreon-en/attachment/0270b9c8-ed74-4d34-b7db-3192cef15d53.png)
How can I solve this error?
Thanks for your help
After upgradind centreon from 21.10 to 22.10.2, I ‘ve got an error in the web interface (and when I execute the command directrly from the server)
How can I solve this error?
Thanks for your help
Hi, can you show the command, and what is returned when you run it as centreon-engine on your monitoring server?
same exact issue, i’ve just imported ova version
Hey, I’m having the same issue. I tried to follow the steps here but still ran into some problems.
I changed the host name of central to “Iocalhost”. Then I added „--ssh-username=centreon“ and „--ssh-port=xxx“ to the EXTRAOPTIONS macro, since we use a custom ssh port.
Now when I try to connect from centreon-engine, it asks for the passphrase, which is fine for the first time.
So I try to persist it:
Which fails, since apparently the environment variables aren’t set for the connection. Well alright, let’s fix that:
Ok, now the ssh key should remembered unless a restart occurs. And the logon works:
However, when I try to run the plugin from root or the console I get:
And also when I re-log to centreon-engine, it asks for the passphrase again.
PS: Also the forum really does seem to have a problem when trying to post something containing Iocalhost with an l instead of I. I’ve had my whole post deleted and had to re-write it twice.
Hey, I had the same issue, and I managed to solve it using the next steps:
To create a passphraseless ssh-key, just press “Enter” when prompted for passphrase (which corresponds to “empty for no passphrase” as you can see in the previous capture).
I did not have to edit the configuration of the “Broker-Stats” service (it was suggested in previous answers to add “--remote --ssh-option='-l=centreon'” to the “EXTRAOPTIONS” parameter).
My configuration is the following:
Hi,
have you try ?
/usr/lib/centreon/plugins//centreon_centreon_central.pl --plugin=apps::centreon::local::plugin --hostname=****** --mode=broker-stats --broker-stats-file='/var/lib/centreon-engine/*-module*-stats.json' --filter-name='' --warning-speed-events='' --critical-speed-events='' --warning-queued-events='' --critical-queued-events='' --warning-unacknowledged-events='' --critical-unacknowledged-events='' --warning-status='' --critical-status='%{type} eq "output" and %{queue_file_enabled} =~ /true|yes/i' --verbose --sshcli-option='-l=centreon-engine'
Hi everyone,
I’ve migrate my centreon 22.04 centos 7 to 23.04 on alma 9,
i’ve the same issue “UNKNOWN: Command error: Host key verification failed.”, i’ve following this https://docs.centreon.com/pp/integrations/plugin-packs/procedures/applications-monitoring-centreon-central/ for the ssh key exchange, but still have this error, my command : /usr/lib/centreon/plugins//centreon_centreon_central.pl --plugin=apps::centreon::local::plugin --hostname=127.0.0.1 --mode=broker-stats --broker-stats-file='/var/lib/centreon-broker/central-broker-master-stats.json' --broker-stats-file='/var/lib/centreon-broker/central-rrd-master-stats.json' --broker-stats-file='/var/lib/centreon-engine/central-module-master-stats.json' --filter-name='' --warning-speed-events='' --critical-speed-events='' --warning-queued-events='' --critical-queued-events='' --warning-unacknowledged-events='' --critical-unacknowledged-events='' --warning-status='' --critical-status='%{type} eq "output" and %{queue_file_enabled} =~ /true|yes/i' --verbose
someone have any idea ?
Kélian
Bonjour, j’ai le même problème : UNKNOWN: Command error: Host key verification failed.
Seulement j’ai suivis les consigne indiquer sur cette page pour l’échange de clé ssh :https://docs.centreon.com/pp/integrations/plugin-packs/procedures/applications-monitoring-centreon-central/#ssh-key-exchange
J’ai également changer l’extra option : --verbose --ssh-username=centreon.
Mais mon problème reste le même.
Quelqu’un peut m’aider ?
Merci d’avance.
Kélian et MHEN56, avez vous essayé la solution dont je parle plus haut ?
J’ai divergé des consignes données sur le site de Centreon, en faisant l’échange de clé avec l’utilisateur centreon-engine et non l’utilisateur centreon.
Si cela ne marche toujours pas, pourriez vous indiquer précisément quelles ont été les commandes utilisées svp ? (pour la génération des clés, pour l’échange, et sous quel utilisateur)
su - centreon-engine
ssh-keygen -t ed25519 -a 100
ssh-copy-id -i ~/.ssh/id_ed25519.pub centreon@localhost
j’utilise actuellement un poller qui est lui même sur le même serveur que mon application WEB Centreon
(je n’ai qu’un serveur pour toute ma supervision et mon application web et en générale pour tout si jamais j’ai oublier quelque chose)
et ma ligne EXTRA OPTION a comme valeur : --verbose --ssh-username=centreon
car si j’utilise les valeurs : --verbose --remote --ssh-option='-l=centreon'
J’ai une erreur qui ressemble a cela : Unknown option: remote at /usr/lib/centreon/plugins//centreon_centreon_central.pl line 2248.
[ cat -n /usr/lib/centreon/plugins//centreon_centreon_central.pl | grep 2248
= 2248 warn "Unknown option: $option" if ($warn_message == 1); ]
je n’arrive pas a cerner ce qui ne fonctionne pas, sachant que j’ai suivis la procédure a la lettre :(
Encore merci a vous.
Hello everyone,
If you only have the Centreon central server (standalone), you just need to add [ --hostname=’’ ] without the square brackets in the 'EXTRAOPTIONS' macro of the 'Broker-Stats' service itself, and this will solve the problem. This will bypass Host Key verification. I have personally tested it, and it works.
However, the best practice is to have the central server monitored by a poller.
Hi
If anyone is still having this issue when monitoring the central’s broker from the central’s poller, then follow this https://docs.centreon.com/pp/integrations/plugin-packs/procedures/applications-monitoring-centreon-central/#overview :
The best practice is to have the central server monitored by a poller if you have one. If not, you will need to add the
--hostname=''
option to the host'sEXTRAOPTIONS
macro to avoid host key verification issues.
Sorry for not posting it here earlier...
I just download the OVA file, same problem:
/usr/lib/centreon/plugins/centreon_centreon_central.pl --plugin=apps::centreon::local::plugin --hostname=localhost --mode=broker-stats --broker-stats-file='/var/lib/centreon-broker/central-broker-master-stats.json' --broker-stats-file='/var/lib/centreon-broker/central-rrd-master-stats.json' --broker-stats-file='/var/lib/centreon-engine/central-module-master-stats.json' --filter-name='' --warning-speed-events='' --critical-speed-events='' --warning-queued-events='' --critical-queued-events='' --warning-unacknowledged-events='' --critical-unacknowledged-events='' --warning-status='' --critical-status='%{type} eq "output" and %{queue_file_enabled} =~ /true|yes/i' --verbose --ssh-username='centreon'
UNKNOWN: Command error: Host key verification failed.
I just download the OVA file, same problem:
/usr/lib/centreon/plugins/centreon_centreon_central.pl --plugin=apps::centreon::local::plugin --hostname=localhost --mode=broker-stats --broker-stats-file='/var/lib/centreon-broker/central-broker-master-stats.json' --broker-stats-file='/var/lib/centreon-broker/central-rrd-master-stats.json' --broker-stats-file='/var/lib/centreon-engine/central-module-master-stats.json' --filter-name='' --warning-speed-events='' --critical-speed-events='' --warning-queued-events='' --critical-queued-events='' --warning-unacknowledged-events='' --critical-unacknowledged-events='' --warning-status='' --critical-status='%{type} eq "output" and %{queue_file_enabled} =~ /true|yes/i' --verbose --ssh-username='centreon'
UNKNOWN: Command error: Host key verification failed.
HI,
Please add
--hostname=''
in the host
EXTRAOPTIONS
macro.
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.