Bug 210622 - net-mgmt/telegraf: Config file includes non-ascii chars
Summary: net-mgmt/telegraf: Config file includes non-ascii chars
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Palle Girgensohn
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-27 12:05 UTC by Alexander Holte-Davidsen
Modified: 2016-08-05 14:17 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (girgen)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Holte-Davidsen 2016-06-27 12:05:54 UTC
telegraf.conf in /usr/local/etc/ contanins non-acsii chars that causes for example puppet to fail if the environment variable LANG is not set:

Error: invalid byte sequence in US-ASCII
Error: /Stage[main]/Telegraf::Config/File[/usr/local/etc/telegraf.conf]/content: change from {md5}5c812b6b344d2871127156bad533dc10 to {md5}2acf801f94443623297ab3bf1f8b0e13 failed: invalid byte sequence in US-ASCII


# pcregrep -n "[\x80-\xFF]" telegraf.conf
78:  ## Precision of writes, valid values are "ns", "us" (or "µs"), "ms", "s", "m", "h".
885:#   ## This collect all heap memory usage metrics.
891:#   ## This collect thread counts metrics.
897:#   ## This collect number of class loaded/unloaded counts metrics.

I believe these non-acsii chars should be removed from the configuration file. If that is not possible the telegraf.conf should be installed as telegraf.conf.sample and not telegraf.conf.

Let me know if more information is needed.
Comment 1 Palle Girgensohn freebsd_committer freebsd_triage 2016-08-05 09:31:04 UTC
seem easy enougth to just remove them, yes. I'll fix this.
Comment 2 commit-hook freebsd_committer freebsd_triage 2016-08-05 14:16:27 UTC
A commit references this bug:

Author: girgen
Date: Fri Aug  5 14:15:46 UTC 2016
New revision: 419688
URL: https://svnweb.freebsd.org/changeset/ports/419688

Log:
  Update to beta3

  Clean up telegraf.conf [1]

  PR:	210622 [1]

Changes:
  head/net-mgmt/telegraf/Makefile
  head/net-mgmt/telegraf/distinfo
  head/net-mgmt/telegraf/files/patch-telegraf-conf
Comment 3 Palle Girgensohn freebsd_committer freebsd_triage 2016-08-05 14:17:47 UTC
Fixed. Thanks.