Open thrashiii opened 6 days ago
Hi,
are automatic refreshes enabled?
You might also notice this because Web doesn't wait for Icinga to perform the check, it just refreshes 1s afterwards. If Icinga didn't perform the check fast enough, the refresh happens but has no effect.
Hi, thank you for your response. Yes, the automatic refreshes are enabled.
I think the refresh after 1 second no longer works properly. Normally, when I click on "Check now", the last check status is reset to a few seconds after one second. Now it's the case that after clicking on "Check now", it is no longer refreshed at all
I have the same issue, running the latest icinga2 and icingaweb2 with php8.3. I noticed this recently. Auto-refresh is enabled. I tried to toggle that off/on and even change the refresh to fast, but no joy. So, it refreshes fine in the left-hand list but not on the right-hand side where you click on "Check now."
The thing is, it works for me.
Do you have any modules enabled?
And please include a portion of the browser's console when you've clicked Check Now again. (e.g. Hit F12, select the Console tab, click Check Now, right click on any message and choose Save as…)
Hi, the only warning I could see is this:
Cookie “Icingaweb2” does not have a proper “SameSite” attribute value. Soon, cookies without the “SameSite” attribute or with an invalid value will be treated as “Lax”. This means that the cookie will no longer be sent in third-party contexts. If your application depends on this cookie being available in such contexts, please add the “SameSite=None“ attribute to it. To know more about the “SameSite“ attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite,
it is increasing regardless of the Check now.
See the attached screenshot with all the loaded modules and Icinga version details:
Hi, the only warning I could see is this:
Cookie “Icingaweb2” does not have a proper “SameSite” attribute value. Soon, cookies without the “SameSite” attribute or with an invalid value will be treated as “Lax”. This means that the cookie will no longer be sent in third-party contexts. If your application depends on this cookie being available in such contexts, please add the “SameSite=None“ attribute to it. To know more about the “SameSite“ attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite,
it is increasing regardless of the Check now.
See the attached screenshot with all the loaded modules and Icinga version details:
I updated director module and disabled the reactbundle module but still the same
Hmm, I think im onto something. Just to clarify, if you push Check Now, the text gets an outline and keeps it, right?
Hmm, I think im onto something. Just to clarify, if you push Check Now, the text gets an outline and keeps it, right?
Yes, it keeps the outline.
Here is a screenshot with loaded modules:
I can confirm too, that after on push "Check Now" the text keeps an outline.
Hi,
I have the same issue. I can confirm too, that after on push "Check Now" the text keeps an outline.
Auto refresh configuration:
And please include a portion of the browser's console when you've clicked Check Now again. (e.g. Hit F12, select the Console tab, click Check Now, right click on any message and choose Save as…)
The request after clicking 'Check now' is:
/monitoring/service/show?host=XXX&service=XXX
Request copied as curl:
curl 'https://xxx.domain.com/monitoring/service/show?host=xxx.host.com&service=Load%20average' \
-H 'accept: */*' \
-H 'accept-language: en-US,en;q=0.9,fr;q=0.8' \
-H 'content-type: application/x-www-form-urlencoded; charset=UTF-8' \
-H 'cookie: Icingaweb2=XXX; icingaweb2-remember-me=XXX; icingaweb2-tzo=3600-0; icingaweb2-session=XXX' \
-H 'origin: https://xxx.domain.com' \
-H 'priority: u=1, i' \
-H 'referer: https://xxx.domain.com/dashboard' \
-H 'sec-ch-ua: "Google Chrome";v="131", "Chromium";v="131", "Not_A Brand";v="24"' \
-H 'sec-ch-ua-mobile: ?0' \
-H 'sec-ch-ua-platform: "Linux"' \
-H 'sec-fetch-dest: empty' \
-H 'sec-fetch-mode: cors' \
-H 'sec-fetch-site: same-origin' \
-H 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36' \
-H 'x-icinga-accept: text/html' \
-H 'x-icinga-col1-state: /dashboard' \
-H 'x-icinga-col2-state: /monitoring/service/show?host=xxx.host.com&service=Load%20average' \
-H 'x-icinga-container: col2' \
-H 'x-icinga-windowid: longscebfxrp_rofnas' \
-H 'x-requested-with: XMLHttpRequest' \
--data-raw 'formUID=IcingaModuleMonitoringFormsCommandObjectCheckNowCommandForm&CSRFToken=XXX&btn_submit=Check+now'
This result in a 200OK response with an empty body:
< HTTP/2 200
< date: Wed, 27 Nov 2024 07:35:50 GMT
< server: Apache
< x-content-type-options: nosniff
< referrer-policy: strict-origin-when-cross-origin
< expires: Thu, 19 Nov 1981 08:52:00 GMT
< cache-control: no-store, no-cache, must-revalidate
< pragma: no-cache
< set-cookie: Icingaweb2=XXX; path=/; secure; HttpOnly
< x-icinga-redirect: %2Fmonitoring%2Fservice%2Fshow%3Fhost%3Dxxx.host.com%26service%3DLoad%2520average
< x-icinga-refresh: 1
< x-icinga-notification: success%20Scheduling%20check..
< vary: Accept-Encoding
< content-length: 0
< content-type: text/html; charset=UTF-8
@nilmerg Do you need more information ?
Thanks. Nope, I think I've reproduced it successfully.
Describe the bug
If the “Check now” link is clicked in a host or service check, the page does not refresh automatically. The page is only updated when you click on the link a second time.
To Reproduce
Expected behavior
if you click on the "Check now" link, a few seconds later the “last check” display should jump to 0 seconds
Your Environment
Include as many relevant details about the environment you experienced the problem in
icinga2 --version
): r2.14.3-1php --version
): PHP 7.4.33