From nobody Sat Feb 03 15:24:48 2024 X-Original-To: ports@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TRxK64lKcz59Z8c; Sat, 3 Feb 2024 15:24:58 +0000 (UTC) (envelope-from ml@netfence.it) Received: from soth.netfence.it (mailserver.netfence.it [78.134.96.152]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mailserver.netfence.it", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4TRxK53wB9z4HhN; Sat, 3 Feb 2024 15:24:57 +0000 (UTC) (envelope-from ml@netfence.it) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=netfence.it header.s=202401 header.b=O0CJ6XN4; dmarc=pass (policy=none) header.from=netfence.it; spf=pass (mx1.freebsd.org: domain of ml@netfence.it designates 78.134.96.152 as permitted sender) smtp.mailfrom=ml@netfence.it Received: from [10.1.2.18] (alamar.local.netfence.it [10.1.2.18]) (authenticated bits=0) by soth.netfence.it (8.17.2/8.17.1) with ESMTPSA id 413FOmRa031594 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NO); Sat, 3 Feb 2024 16:24:49 +0100 (CET) (envelope-from ml@netfence.it) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netfence.it; s=202401; t=1706973889; bh=9cve/VWFwUCoWmeS77QuEvdzD3Kle1AFjopXhm4mYAQ=; h=Date:To:Cc:From:Subject; b=O0CJ6XN4Z4z3I7CU7NodtMCytZF8KgtB5upHK3GDn9Db3W7cDpTQ/TLpu1ZhBXgUz woTj1D8h/ez9ochBnLjn9yVq0DWKuPA6Uf9n6KDJZfGchvLCk8dl7At4U4sFzSBptb GbXZfLWxWIJR7AC4+aa2XrHB3MNXCPAGEY/6Y/Ng= X-Authentication-Warning: soth.netfence.it: Host alamar.local.netfence.it [10.1.2.18] claimed to be [10.1.2.18] Message-ID: <954b15e9-7522-439a-a9e0-188f7b0056c9@netfence.it> Date: Sat, 3 Feb 2024 16:24:48 +0100 List-Id: Porting software to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-ports List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: elastic@FreeBSD.org Cc: ports@freebsd.org From: Andrea Venturoli Subject: Troubles with Kibana Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.99 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-1.000]; DMARC_POLICY_ALLOW(-0.50)[netfence.it,none]; R_SPF_ALLOW(-0.20)[+ip4:78.134.96.152]; R_DKIM_ALLOW(-0.20)[netfence.it:s=202401]; MIME_GOOD(-0.10)[text/plain]; XM_UA_NO_VERSION(0.01)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; ASN(0.00)[asn:35612, ipnet:78.134.0.0/17, country:IT]; ARC_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_COUNT_ONE(0.00)[1]; RCVD_TLS_ALL(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; MLMMJ_DEST(0.00)[ports@freebsd.org,elastic@FreeBSD.org]; FROM_HAS_DN(0.00)[]; HAS_XAW(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; TO_DN_NONE(0.00)[]; DKIM_TRACE(0.00)[netfence.it:+] X-Rspamd-Queue-Id: 4TRxK53wB9z4HhN Hello. I've got a 13.2p9/amd64 server where I have a jail dedicated to ElasticSearch+Kibana and I'm having troubles starting and stopping the latter. > # pkg info | grep -E "(elastic|kibana)" > elasticsearch8-8.11.3 Distributed, RESTful search and analytics engine > kibana8-8.11.3 Browser based analytics and search interface to ElasticSearch > py39-elasticsearch-7.17.9 Official Python low-level client for Elasticsearch > py39-elasticsearch-dsl-7.3.0 High level Python client for Elasticsearch > # cat /etc/rc.conf > #cron_enable="NO" > kibana_enable="YES" > kibana_syslog_output_enable="YES" > elasticsearch_enable="YES" First problem When I start the jail (with "ezjail-admin start") Elastic starts, but Kibana does not. syslog shows: > [2024-02-03T16:14:21.861+01:00][INFO ][root] Kibana is starting > [2024-02-03T16:14:21.939+01:00][INFO ][root] Kibana is shutting down > [2024-02-03T16:14:21.939+01:00][FATAL][root] Reason: EACCES: permission denied, open '/var/run/kibana.pid' > Error: EACCES: permission denied, open '/var/run/kibana.pid' > > FATAL Error: EACCES: permission denied, open '/var/run/kibana.pid' Same happens if I try "service kibana start" afterwards from inside the jail. I can get around this with: > # touch /var/run/kibana.pid > # chown www /var/run/kibana.pid > # service kibana start However this must be done manually everytime I need to restart the server or jail. Second problem When I try to stop Kibana, it just hangs indefinitely: > # service kibana stop > Stopping kibana. > Waiting for PIDS: 28179 syslog reports: > [2024-02-03T16:20:22.309+01:00][INFO ][root] SIGTERM received - initiating shutdown > [2024-02-03T16:20:22.309+01:00][INFO ][root] Kibana is shutting down > [2024-02-03T16:20:22.311+01:00][INFO ][plugins-system.standard] Stopping all plugins. > [2024-02-03T16:20:22.314+01:00][INFO ][plugins.monitoring.monitoring.kibana-monitoring] Monitoring stats collection is stopped > [2024-02-03T16:20:22.323+01:00][INFO ][plugins-system.standard] All plugins stopped. > [2024-02-03T16:20:22.324+01:00][WARN ][environment] Detected an unhandled Promise rejection: Error: EACCES: permission denied, unlink '/var/run/kibana.pid' > at unlinkSync (node:fs:1883:3) > at process. (/usr/local/www/kibana8/node_modules/@kbn/core-environment-server-internal/src/write_pid_file.js:49:24) > at process. (/usr/local/www/kibana8/node_modules/lodash/before.js:31:21) > at Object.onceWrapper (node:events:632:26) > at process.emit (node:events:529:35) > at process.emit (/usr/local/www/kibana8/node_modules/source-map-support/source-map-support.js:516:21) > at process.exit (node:internal/process/per_thread:192:15) > at Root.onRootShutdown [as onShutdown] (/usr/local/www/kibana8/node_modules/@kbn/core-root-server-internal/src/bootstrap.js:136:11) > at Root.shutdown (/usr/local/www/kibana8/node_modules/@kbn/core-root-server-internal/src/root/index.js:96:12) > at processTicksAndRejections (node:internal/process/task_queues:95:5) > [2024-02-03T16:20:23.026+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:26.024+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:29.024+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:32.023+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:35.022+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:38.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:41.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:44.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:47.022+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:50.022+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:53.023+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:56.022+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:20:59.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:02.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:05.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:08.022+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:11.023+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:14.022+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:17.021+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections > [2024-02-03T16:21:20.020+01:00][ERROR][plugins.taskManager] Failed to poll for work: NoLivingConnectionsError: There are no living connections This goes on until I kill -9 the process. This is particularly problematic in case power goes missing and the UPS tries to shutdown the server, which will hang, instead. Any hint? bye & Thanks av.