Skip to main content
Solved

api : dependance add syntax

  • July 29, 2024
  • 2 replies
  • 25 views

Forum|alt.badge.img+4

Bonjour,

 

I want to add a dependace with the rest api.

It didn t work , i don t know why :

centreon -d -u admin -p 'PASSWORDXXX' -o DEP -a ADD -v "postgres_5022;postgres_5022;SERVICE;postgres_5022"

 

with “postgres_5022” an existing service.

Do you have an idea?

Thanks,

Mathias

 

 

Best answer by vcoum

Hello,

You need to precise the host name where the service is attached, like this

centreon -u admin -p 'passsword' -o DEP -a ADD -v "myDep;DepDescription;SERVICE;hostname,servicename"

Separate the hostname and the service name with a comma (,)

Hope it helps

2 replies

vcoum
Centreon Lord Commander
Forum|alt.badge.img+13
  • Centreon Lord Commander
  • Answer
  • July 30, 2024

Hello,

You need to precise the host name where the service is attached, like this

centreon -u admin -p 'passsword' -o DEP -a ADD -v "myDep;DepDescription;SERVICE;hostname,servicename"

Separate the hostname and the service name with a comma (,)

Hope it helps


Forum|alt.badge.img+4
  • Author
  • Steward **
  • July 30, 2024

That s it !

Thanks for your help

😄