Ad Widget

Collapse

Change Trigger Severity Names

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ke_sheng_jie
    Member
    • Aug 2011
    • 40

    #1

    Change Trigger Severity Names

    Does anyone know a way to change the trigger severities? We're moving from Nagios to Zabbix and would prefer to rename the High severity to Critical to match what we're used to.

    I tried looking in the database, but the severity is stored as a number. I searched through the code for the web GUI, but wasn't sure what needed to change and if it would change it throughout the system (including in emails sent).

    This would be a nice feature addition to the web GUI.
    4
    Yes
    75.00%
    3
    No
    25.00%
    1
    Don't Care
    0.00%
    0
  • CeeEss
    Senior Member
    Zabbix Certified Specialist
    • Nov 2007
    • 103

    #2
    Originally posted by ke_sheng_jie
    Does anyone know a way to change the trigger severities? We're moving from Nagios to Zabbix and would prefer to rename the High severity to Critical to match what we're used to.

    I tried looking in the database, but the severity is stored as a number. I searched through the code for the web GUI, but wasn't sure what needed to change and if it would change it throughout the system (including in emails sent).

    This would be a nice feature addition to the web GUI.
    Edit the appropriate locale file in (zabbix_web_root)/include/locales/[your_locale).inc.php and redefine the severity variable mapping to something that more closely matches how you use severities: Changes will be reflected throughout Zabbix immediately (perhaps after a page refresh). In include/locales/en_gb.inc.php, they are set by default to:

    'S_NOT_CLASSIFIED'=> 'Not classified',
    'S_INFORMATION'=> 'Information',
    'S_WARNING'=> 'Warning',
    'S_AVERAGE'=> 'Average',
    'S_HIGH'=> 'High',
    'S_DISASTER'=> 'Disaster',

    I change them to something more meaningful (to me).

    'S_NOT_CLASSIFIED'=> 'Not classified',
    'S_INFORMATION'=> 'Information',
    'S_WARNING'=> 'Attention',
    'S_AVERAGE'=> 'Warning',
    'S_HIGH'=> 'High',
    'S_DISASTER'=> 'Critical',

    "DISASTER" in particular seems a little "over the top" .

    BTW: There are other definitions in the locale files that can achieve some form of UI personalisation, such as replacing instances of Zabbix with your company name.if you're exposing the UI to partners/clients. Be sure to make a note of any changes as the locale files will be overwritten when you upgrade the frontend along with server in the future.
    Last edited by CeeEss; 11-10-2011, 13:43.

    Comment

    • ke_sheng_jie
      Member
      • Aug 2011
      • 40

      #3
      Thanks!

      That was just what I needed.

      Comment

      • qix
        Senior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • Oct 2006
        • 423

        #4
        On the ZabConf I believe Alexei or Richlv noted that this will be easily configurable in Zabbix 2.0 via the Webgui.
        With kind regards,

        Raymond

        Comment

        • ke_sheng_jie
          Member
          • Aug 2011
          • 40

          #5
          Email Severities

          This doesn't seem to change the severity names in emails sent when using the {trigger.severity} macro. Any idea how to change that?

          Looking forward to the feature in 2.0.

          Comment

          • ke_sheng_jie
            Member
            • Aug 2011
            • 40

            #6
            Work Around

            Originally posted by ke_sheng_jie
            This doesn't seem to change the severity names in emails sent when using the {trigger.severity} macro. Any idea how to change that?

            Looking forward to the feature in 2.0.
            Found the work around in the source code in src/libs/zbxcommon/str.c, the severities are at lines 2550-2563. So far, I haven't seen any issues caused by changing this and recompiling, but your mileage may vary.

            Does the 2.0 feature allow for the change to include the email notifications sent?

            Comment

            Working...