Not possible to link two templates that differ only by user macro

XMLWordPrintable

    • Type: Incident report
    • Resolution: Won't fix
    • Priority: Minor
    • None
    • Affects Version/s: 2.2.2
    • Component/s: Templates (T)
    • Environment:
      Linux (SuSE 11.2)

      I have several instances of the same service running on one server, differing only by TCP port number (think: several Apache/FTP/SSH instances, one instance listens on port X and second on port Y).
      I have created "parent" template with items/triggers/graphs to monitor one instance on port {$MY_PORT}.
      Then I create "child" template that links to "parent" template and sets macro {$MY_PORT} to a specific value.

      My idea is to have one place to add new items/triggers/graphs ("parent" template).
      For every instance I create "child" template and just set macro {$MY_PORT} to actual port value.

      Problem:
      when I try to link two "child" templates (which differ only by macro) to a host I get an error:
      Template "Perforce Replica 1110" with item key "p4.replica.files[{$MY_PORT}]" already linked to host.

      "Perforce Replica 1110" is one of child templates with macro set to port 1110

      What is the right way to monitor several instances of a service that differ only by port number?

            Assignee:
            Unassigned
            Reporter:
            Miotk Szymon
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: