I have exactly the same problem. In fact it gets worse. If I force the shut down I find that on restart a full file system check is forced and I am getting file system corruption!!!
My workaround is to log off before I shutdown. I log off and get a message that an unknown program is running and I force the logoff. Then I shut down. This seems to avoid the problem of file system corruption. However it means that shutdown has an annoying 2 minute wait (for the program to be terminated during logon) then I have to shut down. Another workaround is to press the restart button on the computer. If I do this there is no annoying 2 minute wait and no file system corruption. It amazes me that hitting the red button is less problematic than doing an orderly shutdown. So there are several problems here 1. I run kalarm and terminate it correctly. This results in a problem shutting the system down and at best a 2 minute delay. Problem #1. 2. The name of the offending program that is delaying the shutdown is not displayed. You only get "unknown". Problem number #2. 3. There is a 2 minute delay after you choose to force termination of the program. Problem #3 4. File system check forced on restart. Problem #4. 5. File system corruption detected on restart. Problem #5. This is the flakiest linux install since Slackware with Linux 0.99 which was flaky mainly due to the X driver. -- You received this bug notification because you are a member of Desktop Packages, which is subscribed to gnome-session in Ubuntu. https://bugs.launchpad.net/bugs/1053783 Title: Ubuntu 12.04 - Stalled shutdown after having had KAlarm opened; with package info. Status in “gnome-session” package in Ubuntu: Confirmed Bug description: In Ubuntu 12.04, the shutdown is stalling - for about 2 minutes - but only on occasions when I have opened - and then quit - KAlarm. A window pops up Stating that, 'A Program is still running'; Unknown (not responding); and, there are 3 buttons to choose: 'Lock Screen', 'Cancel' and 'Shutdown Anyway'. Initial report was Bug #1053779 but had no package information. ProblemType: Bug DistroRelease: Ubuntu 12.04 Package: gnome-session-bin 3.2.1-0ubuntu8 ProcVersionSignature: Ubuntu 3.2.0-30.48-generic-pae 3.2.27 Uname: Linux 3.2.0-30-generic-pae i686 NonfreeKernelModules: nvidia ApportVersion: 2.0.1-0ubuntu13 Architecture: i386 Date: Fri Sep 21 13:22:35 2012 ExecutablePath: /usr/bin/gnome-session InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Release i386 (20120423) ProcEnviron: LANGUAGE=en_AU:en PATH=(custom, no user) LANG=en_AU.UTF-8 SHELL=/bin/bash SourcePackage: gnome-session UpgradeStatus: No upgrade log present (probably fresh install) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/gnome-session/+bug/1053783/+subscriptions -- Mailing list: https://launchpad.net/~desktop-packages Post to : [email protected] Unsubscribe : https://launchpad.net/~desktop-packages More help : https://help.launchpad.net/ListHelp

