Automatic reboot for UI-limited machines

Bug #400018 reported by Will Uther
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
unattended-upgrades (Ubuntu)
Fix Released
Low
Michael Vogt

Bug Description

Binary package hint: update-manager

Summary:

  At the moment on my Jaunty box I have automatic security updates selected, and mostly that works fine. Sometimes the machine needs to reboot for these updates to be effective. In this case it brings up a dialog informing me that a reboot is required and giving me the option to do so. I would like an option to reboot automatically.

I notice that an option like this is already in the https://wiki.ubuntu.com/auto-update-blueprint , but there are some extra tweaks that would be useful for me.

Details:

  I'm running a mythtv box. This is a home media server that uses the 'lirc' infra-red controller package as its main form of input - I have no keyboard or mouse available for normal use. Auto-update is good, but at the moment when I get the "restart required" dialog I have to go dig out the keyboard or mouse to make the dialog go away.

  There are a couple of potential solutions here:

  - Make the dialog lirc aware, or
  - Make the system reboot automatically, or
  - Make the system reboot automatically, but only when the machine is idle.

The first two would both work, but I think the third is the best option. Detecting 'idle'ness really depends upon what the machine is used for. For me, there are three indicators:

  - The X DPMS system has the display dimmed, and
  - noone is logged in to the samba server on the machine (which happens automatically - the machine is used for Apple Time Machine backups).

The first of those is the most relevant. I don't want the system rebooting while I'm watching a movie, even though the mouse, which is not readily accessible, hasn't moved in weeks. I'd be happy if there was a way to script your own idleness detector, with a simple, sensible, default.

I don't know if this bug belongs in the update-notifier package instead.

Revision history for this message
Michael Vogt (mvo) wrote :

Thanks for your bugreport.

I commited this to bzr and it will be part of the next karmic upload. I attach the patch, feedback/testing is welcome.

affects: update-manager (Ubuntu) → unattended-upgrades (Ubuntu)
Changed in unattended-upgrades (Ubuntu):
assignee: nobody → Michael Vogt (mvo)
importance: Undecided → Low
status: New → Fix Committed
Revision history for this message
Michael Vogt (mvo) wrote :
Revision history for this message
Will Uther (willu-mailinglists) wrote :

That is great. I might play with it myself. I'd like to add the extra options so that it doesn't reboot if I'm watching TV.

if /usr/X11R6/bin/xset -display :0 -q | grep -q "Monitor is On"

and for samba something involving:

net RAP session -I localhost

but I'll have to turn those into Python.

Without these checks I'm not sure I'd want to actually turn that on.

My other issue is that it isn't very discoverable. So thanks! I might also have a play myself.

Revision history for this message
Will Uther (willu-mailinglists) wrote :

I just re-read my last comment and realised it sounded sarcastic. It wasn't meant to. I really am grateful for the fast response.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unattended-upgrades - 0.52ubuntu1

---------------
unattended-upgrades (0.52ubuntu1) karmic; urgency=low

  * Add new option "Unattended-Upgrade::Automatic-Reboot" that
    will automatically reboot without confirmation if the upgrade
    requires a reboot (off by default) LP: #400018
  * fix typo in filename (LP: #397810)

 -- Michael Vogt <email address hidden> Mon, 20 Jul 2009 13:36:14 +0200

Changed in unattended-upgrades (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.