[Bug 270997] net-mgmt/netdata: sometimes not running when expected, sometimes running but http://localhost:19999 not responding
Date: Thu, 20 Jul 2023 02:10:43 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=270997 --- Comment #22 from Graham Perrin <grahamperrin@freebsd.org> --- (In reply to Graham Perrin from comment #11) > Without attempting to diagnose what's wrong, is there some way that I can > simply start afresh? > > Without preferences/config/settings. > > If it's also necessary to lose data, … Abandoning hope of diagnosis … I stopped netdata, uninstalled, removed /usr/local/etc/netdata, then: root@mowa219-gjp4-8570p-freebsd:~ # du -hs /var/cache/netdata 252M /var/cache/netdata root@mowa219-gjp4-8570p-freebsd:~ # du -hs /var/db/netdata 141K /var/db/netdata root@mowa219-gjp4-8570p-freebsd:~ # du -hs /var/log/netdata 27M /var/log/netdata root@mowa219-gjp4-8570p-freebsd:~ # ls -hln /var/log/netdata total 27131 -rw-r--r-- 1 302 302 2.7M Jul 9 00:32 access.log -rw-r--r-- 1 302 302 14M Jul 19 06:44 collector.log -rw-r--r-- 1 302 302 0B Jul 28 2021 debug.log -rw-r--r-- 1 302 302 562M Jul 19 06:44 error.log -rw-r--r-- 1 302 302 5.9M Jul 19 06:43 health.log root@mowa219-gjp4-8570p-freebsd:~ # du -hs /var/mail/netdata 5.6M /var/mail/netdata root@mowa219-gjp4-8570p-freebsd:~ # ls -hln /var/mail/netdata -rw--w---- 1 302 6 88M Jul 19 02:39 /var/mail/netdata root@mowa219-gjp4-8570p-freebsd:~ # rm -r /var/cache/netdata root@mowa219-gjp4-8570p-freebsd:~ # rm -r /var/db/netdata root@mowa219-gjp4-8570p-freebsd:~ # rm -r /var/log/netdata root@mowa219-gjp4-8570p-freebsd:~ # rm -r /var/mail/netdata root@mowa219-gjp4-8570p-freebsd:~ # file /usr/local/etc/netdata /usr/local/etc/netdata: cannot open `/usr/local/etc/netdata' (No such file or directory) root@mowa219-gjp4-8570p-freebsd:~ # pkg install --yes netdata Updating FreeBSD repository catalogue... FreeBSD repository is up to date. Updating poudriere repository catalogue... Fetching meta.conf: 100% 163 B 0.2kB/s 00:01 Fetching packagesite.pkg: 100% 672 B 0.7kB/s 00:01 The provides database is up-to-date. Processing entries: 100% poudriere repository update completed. 1 packages processed. All repositories are up to date. pkg: Cannot get an advisory lock on a database, it is locked by another process root@mowa219-gjp4-8570p-freebsd:~ # service cron stop Stopping cron. Waiting for PIDS: 2564. … root@mowa219-gjp4-8570p-freebsd:~ # pkg install --yes netdata Updating FreeBSD repository catalogue... FreeBSD repository is up to date. Updating poudriere repository catalogue... Fetching meta.conf: 100% 163 B 0.2kB/s 00:01 Fetching packagesite.pkg: 100% 672 B 0.7kB/s 00:01 The provides database is up-to-date. Processing entries: 100% poudriere repository update completed. 1 packages processed. All repositories are up to date. The following 1 package(s) will be affected (of 0 checked): New packages to be INSTALLED: netdata: 1.40.1 [FreeBSD] Number of packages to be installed: 1 The process will require 32 MiB more space. 9 MiB to be downloaded. [1/1] Fetching netdata-1.40.1.pkg: 100% 9 MiB 4.7MB/s 00:02 Checking integrity... done (0 conflicting) [1/1] Installing netdata-1.40.1... ===> Creating groups. Using existing group 'netdata'. ===> Creating users Using existing user 'netdata'. ===> Creating homedir(s) [1/1] Extracting netdata-1.40.1: 100% ===== Message from netdata-1.40.1: … pkg: Package database is busy while closing! root@mowa219-gjp4-8570p-freebsd:~ # pkg delete --quiet --yes netdata ==> You should manually remove the "netdata" user. ==> You should manually remove the "netdata" group root@mowa219-gjp4-8570p-freebsd:~ # pkg install --quiet --yes netdata The provides database is up-to-date. ===> Creating groups. Using existing group 'netdata'. ===> Creating users Using existing user 'netdata'. ===> Creating homedir(s) ===== Message from netdata-1.40.1: -- Quick start for local-only use: 1. sysrc netdata_enable="YES" 2. service netdata start 3. Go to http://localhost:19999/ 4. <Optional> Connect to Netdata Cloud using the netdata-claim.sh script: https://learn.netdata.cloud/docs/agent/claim#claiming-script root@mowa219-gjp4-8570p-freebsd:~ # date ; uptime Thu Jul 20 03:00:05 BST 2023 3:00AM up 17:46, 5 users, load averages: 1.26, 1.35, 1.38 root@mowa219-gjp4-8570p-freebsd:~ # sysrc netdata_enable="YES" netdata_enable: NO -> YES root@mowa219-gjp4-8570p-freebsd:~ # tail -n 5 /var/log/messages Jul 20 02:37:37 mowa219-gjp4-8570p-freebsd kscreenlocker_greet[55341]: in _pam_exec(): pam_sm_setcred: pam_get_authtok(): authentication token not available Jul 20 02:37:37 mowa219-gjp4-8570p-freebsd kernel: hdaa0: Pin sense: nid=3 sense=0xffffffff (connected, ELD valid) Jul 20 02:57:26 mowa219-gjp4-8570p-freebsd pkg[12002]: netdata-1.40.1 installed Jul 20 02:58:50 mowa219-gjp4-8570p-freebsd pkg[12313]: netdata-1.40.1 deinstalled Jul 20 02:59:52 mowa219-gjp4-8570p-freebsd pkg[12502]: netdata-1.40.1 installed root@mowa219-gjp4-8570p-freebsd:~ # service netdata start Starting netdata. root@mowa219-gjp4-8570p-freebsd:~ # -- You are receiving this mail because: You are the assignee for the bug.