Skip to main content
Solved

App-DB-MSSQL-Sql

  • June 5, 2024
  • 4 replies
  • 322 views

Forum|alt.badge.img+1

Bonjour,

Je vous contacte, car je rencontre un problème assez bizarre, j’ai configuré un hôte et les services pour interroger un serveur Microsoft SQL (avec le pack de plugin). Les commandes sur le serveur centreon fonctionne correctement elles renvoient bien les bonnes valeurs.

par contre sur l’interface web de centreon, j’ai la fameuse erreur :

UNKNOWN: Cannot connect: OpenClient message: LAYER = (0) ORIGIN = (0) SEVERITY = (78) NUMBER = (44)
Server , database

Pourtant si je copie la commande que réalise centreon sur le shell elle fonctionne.

j’ai exporté les configurations, redémarrer le serveur rien ne se passe.

 

Auriez vous une idée d’où peut provenir le problème ou comment le corriger ?

 

Je vous remercie par avance,

Cordialement,

tom

 

Best answer by christophe.niel-ACT

Hello

let me know if english is an issue, but the community is asked to speak english :)

 

as you copy/pasted the command, is there any “\” in the command parameters, or “\\” (in the user name  for the domain for example)

if the login and password work in command line, it could that a \ is missing, your message clearly says the login is failed

(in the macro of the service you should have \\ for a single \ , there is an escaping being done somewhere) 

 

 

 

4 replies

Forum|alt.badge.img+17

Hello

let me know if english is an issue, but the community is asked to speak english :)

 

as you copy/pasted the command, is there any “\” in the command parameters, or “\\” (in the user name  for the domain for example)

if the login and password work in command line, it could that a \ is missing, your message clearly says the login is failed

(in the macro of the service you should have \\ for a single \ , there is an escaping being done somewhere) 

 

 

 


lpinsivy
Centreonian
Forum|alt.badge.img+21
  • Centreonian
  • June 6, 2024

HI @tomtom and please use ‘centreon-engine’ user to run your command instead of ‘root’


Forum|alt.badge.img+1
  • Author
  • Steward *
  • June 6, 2024

Hi !

Sorry for writing in French, the problem is solved, i put \\ in MSSQLUSERNAME arguments and it’s work

Thanks for your help :)

 


  • August 19, 2025

 there is an escaping being done somewhere) 

 

More like an escaping is NOT done somewhere. FYI I encountered the same issue with a backslash in the SQL query.

I can’t understand how a so obvious bug (or rather, let’s say, an “odd behavior”) is not considered as a major bug and fixed rapidly. If Centreon Engine needs an un-escaped value then Centreon Web should require an un-escaped value from the user. If escaping is needed internally, it should not be to the user to handle that.