Looking for a way to remotely power on the IP-KVM

I understand from reading this topic, Feature request: Add a real video toggle on the KVM for HDR setups that the ip-kvm hardware does not have the ability to control power to the HDMI input subsystem. I am using a Comet PoE.

I don’t believe any other IP-KVM supports this either. Which is unfortunate.

The reason that it’s unfortunate is that a typical use case has a computer connected to monitors, and the OS by default sets independent real estate for each monitor. So, if you connect the IP-KVM then usually it gets its own real estate, onto which windows can and will get lost.

The Comet series has a wonderful 4K resolution capability which I am a huge fan of. This means for most monitor setups we can make the IP-KVM’s screen share the real screen, so there is no longer any trouble with windows possibly being hidden and unfindable, and worse of the default monitor being the wrong one and so all windows spawn on the other monitor(s) and we have to try to use keyboard shortcuts to retrieve all our windows and so on.

I have a 4K 240Hz monitor and I’m able to configure it nicely to share the real estate with the Comet which runs 4K 30Hz and it’s no problem, the computer is still fully responsive.

But it has to drop HDR because the Comet of course cannot support HDR. I am also pretty sure no EDID can enable this either, so windows has to force SDR for compatibility. I do not know if Linux has the same limitation, I will have to test, but it might not. And besides HDR is not really needed there as much.

Given this state of affairs what I would like is to be able to just power down the Comet normally and have it come online when I need it, because shutting it down will hopefully power down the HDMI and cause the GPU to re-enable HDR on the main monitor again.

So the question becomes how can i remotely control the power? One idea is to put a power cut switch for what is powering the USB-C power in port on the Comet. I don’t see a way to power down the Comet from its web app interface, there is a Reboot action though. I assume it has been designed well and cannot corrupt itself by yanking the power. I’d pull the power and it will restore the full function of the computer’s main monitor, and then when i want to access it remotely, i use this out of band remote controlled power socket to power the Comet back on so it will reconnect, Windows will force HDR off automatically, and I can access the computer.

Is there a cleaner way to implement this?

Overall I’m not really sure that the complexity of this is worth it over just leaving it present as an extended desktop…

Hello,

Thank you for your feedback. In this situation, using smart sockets/switches to remotely control the power supply is a temporary solution.

Yeah I think it can work, but I am wary of pulling the plug on the Comet device.

In my past PiKVM devices I know that they come with a ro operating system, which makes doing that extremely safe. Does Comet have a readonly operating system?

Are we able to access Comet via command line? It surely runs linux. Can we access the command line so that we can run poweroff to shut it down?

I am not sure a shutdown operation is a safe option to have in the UI, because someone might trigger it accidentally and then realize they have to physically go in to replug the power to bring it back alive.

Hi,

What kind of power cable does the HDR use?

On Kickstarter for Comet pro I asked them to make a dc module, but instead I got told to buy a fingerbot which I still think is not a great option because you can't be 100% garantueed the condition was met... it could have been fallen down and maybe some device like HDR don't come with a power button, to me it was for nucs.

Do you think that could fit your situation?

If so then I want to request again for a dc module :slight_smile:

Maybe there are also other options, people already suggested smart plugs, but if your remote also has IR you could have various smart IR blasters to turn on or off, I know that some Aqara hubs can do this, but you cannot read the actual state but you could combine it with a smart plug to read the power, it depends on your needs and price too.

You can SSH into it root@<ipkvm_ip_or-hostname> - you can also experiment with sending a Wake-on-LAN packet to see it the KVM will respond to it (likely hardline Ethernet only, over WiFi it's rare to find a chipset that will stay connected even when powered off).

I just found this: https://www.reddit.com/r/GlInet/comments/1m8xt83/comment/n58cero/

You guys are GOATs! casually giving root shell access to the device. Bravo on such a polished and powerful product. I think that answers my question.

For posterity: Yeah we can just shell in and power the thing off. Once it’s powered off I’m sure it won’t lock the main monitor out of HDR anymore!

I will look into whether wake-on-lan works (i suspect it may!) but if not we may still need a power toggler plug in order for us to be able to remotely enable the IP-KVM.

This is also going to be elegant from the perspective of the IP-KVM not consuming power when not being used.

Sorry, I think you are misunderstanding what I’m talking about.

HDR is an advanced display mode feature. As a simplification, I can describe it generally as a display mode that supports 10 bitdepth colors, that is to say the brightest thing in the video stream could be 1024 times brighter than the dimmest possible non zero brightness level (for each of red, green, and blue). So, you can put your expensive monitor or TV in 4K, aka 3840x2160 resolution in 10 bit HDR mode or in 8 bit SDR (standard dynamic range) mode.

It is not some sort of hardware device that is being connected to the computer or whatever.

The limitation is simply that if you tell Windows to mirror the display output to 4K 120hz on your monitor and 4K 30Hz on the Comet IP-KVM, you can, and the monitor doesn’t drop down to 30Hz either, which is great, but because the IP-KVM’s HDMI-input hardware can only consume SDR input format, it means that if the Comet is powered on connected this way, mirroring the displays will cause windows to force HDR mode off on the main monitor.

It’s not some kind of big showstopper problem… but it does mean that I have to compromise something and i am searching for a workaround in order to use this very nice IP-KVM and keep it enabled to the same computer that I do high end gaming and media work on.

1 Like

It's really useful. I have a script that will install my own certs and expose an "API endpoint" reporting the current software version. I also think I need to add a reboot in the middle of the night, my WiFi-connected Comet Pros are currently disconnected and I'm not able to get physical access at the moment. A root cronjob to reboot at 2am seems like it should be able to recover them automatically!

Unfortunately when i run poweroff from the root shell this thing just boots right back up. @Thalia do you know if there is a way to power it down and keep it powered down, and hopefully I can bring it back up later with Wake on Lan?

Sorry for the inconvenience. Currently, the best way to remotely power on the device is through a smart switch.

OK I’ve done a bit of exploration on this which was possible due to having root access. In summary:

  1. A watchdog power cycles the device if it hangs for any reason
  2. The watchdog cannot be disarmed once opened. This guarantees that if watchdogd runs, poweroff eventually becomes a reboot.
  3. If the above is done, poweroff works, but:
  4. WoL does not work
  5. device halted in this state does not cut power to HDMI in (thus leaving HDMI connected to computer)

The Comet uses an appliance-style layout:

  • Base firmware /rom : read-only SquashFS.
  • Writable system overlay: ext4 on /userdata .
  • Logs: tmpfs/RAM-backed.
  • Main user/media storage: exFAT at /userdata/media .

This is reasonably resilient to accidental power loss because the base OS is read-only and the system overlay is journaling ext4.

However, /userdata/media is exFAT, which is not journaling. It is the main thing that should be cleanly unmounted before external power is removed.

The Comet has a Synopsys DesignWare hardware watchdog (dw_wdt): /usr/sbin/watchdogd.

It keeps /dev/watchdog open and feeds the hardware watchdog.

The important behavior is:

  • Once this watchdog is armed, it cannot be cleanly disarmed in software.
  • If Linux shuts down or watchdogd stops feeding it, the watchdog resets the board.
  • That means normal poweroff becomes a reboot after the watchdog timeout.

This was confirmed by stopping watchdogd : the Comet rebooted shortly afterward.

For a real halted state, watchdogd must not start after boot.

I came up with a whole "maximum safety" approach which broadly involves

  • disabling watchdog
  • creating a safe poweroff script which ensures media is unmounted before powering off
  • powering off and then yanking power externally to the device after we're sure it's off
  • start it back up by reconnecting power

But this has the drawback of disabling the watchdog which makes the system less resilient than it's supposed to be.

I am still thinking through the implications, but I think the sane approach is just to install a safe-poweroff script on the Comet device which:

  • attempts to ensure the media is not being used and unmounts it
  • instead of issuing a poweroff command, instead makes the call to the externally controlled system to cut power to itself

No need to disable the watchdog or do any other manipulation on the device.

The tradeoff is that you have to keep track of:

  • externally managed power system, whether that's a PoE with switchable power (if using Comet PoE) or a switchable power plug
  • keep track of which one of these is connected to the power in of Comet

Thanks for your feedback and suggestions!

This feature was not originally included in the product design. It doesn't support a complete power cutoff via software. To achieve remote power control, we suggest using a smart switch to control the power supply.