Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 782856 - net-analyzer/netdata-1.30.1: broken /etc/netdata/edit-config
Summary: net-analyzer/netdata-1.30.1: broken /etc/netdata/edit-config
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Craig Andrews
URL: https://github.com/netdata/netdata/is...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-14 15:23 UTC by Ortwin Glueck
Modified: 2021-04-20 07:13 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ortwin Glueck 2021-04-14 15:23:39 UTC
# ./edit-config 

USAGE:
  ./edit-config FILENAME

  Copy and edit the stock config file named: FILENAME
  if FILENAME is already copied, it will be edited as-is.

  The EDITOR shell variable is used to define the editor to be used.

  Stock config files at: '/usr/lib/netdata/conf.d'
  User  config files at: '/etc/netdata'

  Available files in '/usr/lib/netdata/conf.d' to copy and edit:

./edit-config: line 34: cd: /usr/lib/netdata/conf.d: No such file or directory

because the package installs the conf.d files into /usr/lib64, which is plain wrong. Those files are not architecture specific and belong into /usr/lib.


Reproducible: Always
Comment 1 Craig Andrews gentoo-dev 2021-04-16 15:10:54 UTC
I can't reproduce this issue...
here's what happens when I run it:
---
# /etc/netdata/edit-config

USAGE:
  /etc/netdata/edit-config FILENAME

  Copy and edit the stock config file named: FILENAME
  if FILENAME is already copied, it will be edited as-is.

  The EDITOR shell variable is used to define the editor to be used.

  Stock config files at: '/usr/lib64/netdata/conf.d'
  User  config files at: '/etc/netdata'

  Available files in '/usr/lib64/netdata/conf.d' to copy and edit:
---

Do you have the NETDATA_STOCK_CONFIG_DIR environment variable set?
Comment 2 Ortwin Glueck 2021-04-16 15:29:30 UTC
No, NETDATA_STOCK_CONFIG_DIR is not set. That's why the script sets it:
[ -z "${NETDATA_STOCK_CONFIG_DIR}" ] && NETDATA_STOCK_CONFIG_DIR="/usr/lib/netdata/conf.d"

My systems have all been migrated to non-symlink /usr/lib:
# ls -dl /usr/lib /usr/lib64/
drwxr-xr-x  53 root root  36864 Apr 15 09:34 /usr/lib
drwxr-xr-x 113 root root 176128 Apr 16 11:38 /usr/lib64/
Comment 3 Ionen Wolkens gentoo-dev 2021-04-16 15:52:32 UTC
I can reproduce, and it seems that the tarball has a pre-sedded stale system/edit-config and installs this one instead of using edit-config.in

netdata-1.29.3 didn't have that
Comment 4 Ionen Wolkens gentoo-dev 2021-04-16 15:57:42 UTC
I didn't look much for the right fix, but this in src_prepare seems to work:
   rm system/edit-config || die
Comment 5 Craig Andrews gentoo-dev 2021-04-16 17:30:43 UTC
Reported upstream: https://github.com/netdata/netdata/issues/10986
Comment 6 Larry the Git Cow gentoo-dev 2021-04-19 01:16:48 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1ba56adfb43c54bf83935548b6b900b0b2edc2c4

commit 1ba56adfb43c54bf83935548b6b900b0b2edc2c4
Author:     Craig Andrews <candrews@gentoo.org>
AuthorDate: 2021-04-19 01:15:14 +0000
Commit:     Craig Andrews <candrews@gentoo.org>
CommitDate: 2021-04-19 01:16:43 +0000

    net-analyzer/netdata: make clean before compiling
    
    Closes: https://bugs.gentoo.org/782856
    Package-Manager: Portage-3.0.18, Repoman-3.0.3
    Signed-off-by: Craig Andrews <candrews@gentoo.org>

 net-analyzer/netdata/netdata-1.30.1-r1.ebuild | 144 ++++++++++++++++++++++++++
 net-analyzer/netdata/netdata-9999.ebuild      |   5 +
 2 files changed, 149 insertions(+)
Comment 7 Ortwin Glueck 2021-04-20 07:13:01 UTC
Yey, works in -r1 now. Thanks!