How to add new language for Centreon BI reports

Hello,

centreonHere is a short article (because it is simple) to show you how to add a new local / language so that it is available in Centreon BI report generation. This method works with all versions of Centreon BI but only reports available in Centreon BI >= 1.6.x are listed here with there translation files.

I advice you to read this article talking about translation in BIRT before continuing. It is not mandatory to know how to translate reports using BIRT because you can just copy/paste flat files to your server and test them directly but you can also validate your translations using BIRT and then copy to Centreon BI server.

This is possible in 4 steps :

  • Check which “.properties” file have to be translated
  • Create new “.properties” files containing the translations and name this file using the standard localization (France = fr_FR , Brazil = pt_BR etc..). You can find the complete list here.
  • Upload these translation files to the right folder on your Centreon BI reporting server into the same folder as the original “.properties” files.
  • Refresh translation available through the interface

1- Check properties files to translate

Here are the files you always have to translate so start by translating them :

$ResourceFolder$/translation/common $ResourceFolder$/translation/components/common $ResourceFolder$/translation/component/L_masterpage $ResourceFolder$/translation/units $ResourceFolder$/translation/component/Inventory/L_inventory $ResourceFolder$/translation/master-page

*$ResourceFolder$: the default resources folder on Centreon BI reporting server is /usr/share/centreon-bi/Resources

Then here are the following translation files you have to translate regarding to the reports that you want to see translated, be careful, some reports are link to multiple translation files :

$ResourceFolder$/translation/component/Availability/L_availability

  • hostgroup-availability-2
  • hostgroup-host-availability-list
  • hostgroup-service-availability-list.rptdesign 
  • hostgroups-availability-1.rptdesign
  • hostgroup-host-event-list.rptdesign
  • host-detail-2.rptdesign

$ResourceFolder$/translation/traffic/Servicegroup-Bandwith-Usage-By-Interface

  • hostgroup-traffic-average-usage-by-interface.rptdesign
  • hostgroup-traffic-by-interface-and-bandwith-ranges.rptdesign

$ResourceFolder$/translation/forecast/forecast

  • hostgroup-capacity-planning-linear-regression.rptdesign

$ResourceFolder$/translation/component/Capacity/L_capacity

  • hostgroup-storage-capacity-2.rptdesign
  • hostgroup-storage-capacity-list.rptdesign
  • hostgroups-storage-capacity-1.rptdesign
  • host-detail-2.rptdesign

$ResourceFolder$/translation/component/Performance/L_performance

  • hostgroups-rationalization-of-resources-1.rptdesign
  • hostgroup-service-metric-performance-list.rptdesign

$ResourceFolder$/translation/graphs-report/graphs

  • host-graphs-v2.rptdesign
  • hostgroup-graphs-v2.rptdesign

$ResourceFolder$/translation/component/Incidents/L_incidents

  • hostgroup-host-event-list.rptdesign
  • hostgroup-service-event-list.rptdesign
  • hostgroups-incidents-1.rptdesign
  • host-detail-2.rptdesign

2 – Create “.properties” files

When you know what files you need to translate, juste create a _xx_XX.properties and copy/paste all the keys to translate. Fill all the key with the correct value in the language you want. Check this website to know what localization code to use.

3 – Upload the translation files to Centreon BI reporting server

Now that you have all your new “.properties” file with the correct localization code, just upload these file TO THE SAME folder as the original .properties file.

Give the right to centreonBI on the translation folder :

chown -R centreonBI.centreonBI /usr/share/centreon-bi/Resources/translation/

4 – Refresh the list of translations available 

By click on the following icon  Refresh Local icon the translation list will be refreshed and “Locale updated” will appear.

Refresh translation availables

Now I have my new translation to portuguese (Brasilian) available ! Easy right ?

If you have any questions, don’t hesitate to comment

 

Tags: , , , , ,

2 comments

  1. j’aimerai ajouetr une langue française sur centreon fan etj’ai besoin de votre aide svp

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.