# How to adjust the graphite background color

**URL:** <https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172>\
**Category:** Icinga Web Modules\
**Tags:** graphite\
**Created:** [January 10, 2020, 8:01am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172 "2020-01-10T08:01:02Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jqrun](https://community.icinga.com/letter_avatar_proxy/v4/letter/j/858c86/32.png) [@jqrun](https://community.icinga.com/u/jqrun)\
**Post date:** [January 10, 2020, 8:01am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172/1 "2020-01-10T08:01:02Z")

</div>

![image](https://community.icinga.com/uploads/default/original/2X/b/bd307b73a4352d4bfa237c51b0097127e7e11eb6.png)  
I show black here, I want to set it to white

---

<div class="post-metadata">

**Author:** ![dnsmichi](https://community.icinga.com/user_avatar/community.icinga.com/dnsmichi/32/7721_2.png) [@dnsmichi](https://community.icinga.com/u/dnsmichi)\
**Post date:** [January 10, 2020, 8:05am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172/2 "2020-01-10T08:05:43Z")

</div>

Hi,

please always include more details about your setup, e.g. which module and integration are you using, which versions are involved and more. You can find hints for this in the [FAQ](https://community.icinga.com/faq). This helps everyone to understand your question.

Please continue to do so in your other topics and replies.

Cheers,  
Michael

---

<div class="post-metadata">

**Author:** ![jqrun](https://community.icinga.com/letter_avatar_proxy/v4/letter/j/858c86/32.png) [@jqrun](https://community.icinga.com/u/jqrun)\
**Post date:** [January 10, 2020, 8:16am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172/3 "2020-01-10T08:16:58Z")

</div>

ii icinga2-bin 2.11.1-1.xenial  
docker pull graphiteapp/graphite-statsd  
version 1.1x maybe 1.16

> **[Icinga/icingaweb2-module-graphite](https://github.com/Icinga/icingaweb2-module-graphite)**
>
> The Graphite module for displays data stored in Graphite directly in the Icinga Web 2 interface. - Icinga/icingaweb2-module-graphite

graphite it’s defaults to black. I want to set it to white.

 ![image](https://community.icinga.com/uploads/default/original/2X/f/f50c367375ee7a1dd5525282bf2385f22bafb61a.png)

---

<div class="post-metadata">

**Author:** ![dnsmichi](https://community.icinga.com/user_avatar/community.icinga.com/dnsmichi/32/7721_2.png) [@dnsmichi](https://community.icinga.com/u/dnsmichi)\
**Post date:** [January 10, 2020, 8:35am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172/4 "2020-01-10T08:35:18Z")

</div>

Hi,

ah, so the Docker container changes that to black as background color by default, interesting.

There’s two ways of influencing this.

# Change Graphite default background color

Depending on your Graphite installation, the paths may differ.

```auto
vim /opt/graphite/conf/graphTemplates.conf

[default]
background = white
foreground = black

```

# Modify Icinga module templates to change the background color

Add the following `bgcolor` and `fgcolor` lines into the mentioned sections.

```auto
vim /etc/icingaweb2/modules/graphite/templates/default.ini

[default-host.urlparams]

bgcolor = "white"
fgcolor = "black"

[default-service.urlparams]

bgcolor = "white"
fgcolor = "black"

```

## References

- [https://graphite.readthedocs.io/en/latest/render\_api.html#bgcolor](https://graphite.readthedocs.io/en/latest/render_api.html#bgcolor)
- [https://graphite.readthedocs.io/en/latest/render\_api.html#fgcolor](https://graphite.readthedocs.io/en/latest/render_api.html#fgcolor)
- [https://icinga.com/docs/graphite/latest/doc/04-Templates/](https://icinga.com/docs/graphite/latest/doc/04-Templates/)
- [https://github.com/Icinga/icingaweb2-module-graphite/blob/master/templates/default.ini](https://github.com/Icinga/icingaweb2-module-graphite/blob/master/templates/default.ini)
- [https://github.com/Icinga/icingaweb2-module-graphite/issues/204#issuecomment-471988836](https://github.com/Icinga/icingaweb2-module-graphite/issues/204#issuecomment-471988836)

Cheers,  
Michael

---

<div class="post-metadata">

**Author:** ![jqrun](https://community.icinga.com/letter_avatar_proxy/v4/letter/j/858c86/32.png) [@jqrun](https://community.icinga.com/u/jqrun)\
**Post date:** [January 10, 2020, 8:46am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172/5 "2020-01-10T08:46:08Z")

</div>

thank you  
you are great  
I solved

---

<div class="post-metadata">

**Author:** ![dnsmichi](https://community.icinga.com/user_avatar/community.icinga.com/dnsmichi/32/7721_2.png) [@dnsmichi](https://community.icinga.com/u/dnsmichi)\
**Post date:** [January 10, 2020, 9:44am UTC](https://community.icinga.com/t/how-to-adjust-the-graphite-background-color/3172/6 "2020-01-10T09:44:09Z")

</div>

I had explained that too often in the past years, I have moved this into a PR for the official documentation now.

> <https://github.com/Icinga/icingaweb2-module-graphite/pull/228>

Cheers,  
Michael
