For some of my hosts the rescue part in ping_cockpit_service in app/models/concerns/foreman_cockpit/host_extensions.rb did not catch an error ('network unreachable') which leads to Foreman displaying an error message instead of just skipping the cockpit display on that host.
I had to add the error Errno::ENETUNREACH to the rescue list to make it work.
For some of my hosts the rescue part in
ping_cockpit_service
inapp/models/concerns/foreman_cockpit/host_extensions.rb
did not catch an error ('network unreachable') which leads to Foreman displaying an error message instead of just skipping the cockpit display on that host.I had to add the error
Errno::ENETUNREACH
to the rescue list to make it work.