[Nut-upsdev] nut vs. ModemManager and device stealing

Charles Lepple clepple at gmail.com
Wed Jan 20 13:44:38 UTC 2010


On Jan 20, 2010, at 8:25 AM, Michal Hlavinka wrote:

> I'd like to know your opinion for bug
> http://bugzilla.redhat.com/show_bug.cgi?id=544121
>
> Recently serial connected UPSes stopped working because ModemManager  
> steals
> tty devices (it tries to open every tty device to check if there is  
> modem
> sitting there), this means device is blocked for about 10 seconds.  
> This
> prevents nut daemon to start. I've reassigned bug against  
> ModemManager because
> I think it's its fault, but ModemManager maintainer says it nut  
> fault, because
> nut should not give up to open device and it should retry later.  
> What do you
> think? Some more details can be found in the bug comments.

If ModemManager probes serial devices, IMHO it should be optional, and  
easy to disable. At the very least, there should be an option to block  
ModemManager from using a specific port.

Sending AT commands to an UPS is not well-defined. Some UPSes may  
handle this gracefully, but I think that if someone has an UPS  
connected to a system, the uptime requirements of the system are  
probably more important than the convenience of auto-detecting a modem.

We have auto-reconnect code for some USB devices (only after the  
device has been opened successfully, IIRC) and it is a mess. I  
personally don't think we should add similar complexity to the serial  
side of NUT, and if we do, it should be disabled by default.

-- 
Charles Lepple



More information about the Nut-upsdev mailing list