Changing the command executed when pressing Suspend button

Robert McWilliam rmcw at
Wed Jan 2 02:11:10 UTC 2008

On 01/01/08 20:02:11, Giuseppe Torelli wrote:
> On Jan 1, 2008 6:31 PM, Robert McWilliam <rmcw at> wrote:
> > In /etc/acpi
> gt[xarchiver]$ ls /etc/acpi/suspend.d/
> Ehm, can you tell me which one I executed? And also what shall I
> change to have executed "sudo pm-suspend"?

I should point out that my understanding of this is a bit vague and comes from 
playing with it more than anything. As far as I've figured: apcid gets acpi 
events from the hardware, then looks for a matching event in /etc/acpi/events 
and that event file directs what to execute, which is usually one of the 
scripts in /etc/acpi 

As far as I can tell the contents of suspend.d/ are called from, 
which is used in and, so it isn't actually anything in 
there that you want to change. 

I'm not entirely sure what pm-suspend does but I suspect it replaces the 
existing suspend to RAM or disk procedure. Sleep is suspend to RAM and 
hibernate is suspend to disk so replace the contents of either or with a call to pm-suspend [1]. Alternatively you could probably 
put the call directly in the event file you want to trigger the pm-suspend 

Given that I am not entirely sure of this advice please be careful to keep 
backups of files before changing them so things can be put back if they break 
horribly :)


[1] I don't think you'll need the sudo

Robert McWilliam     rmcw at

We have enough youth. How about a fountain of smart?

More information about the xubuntu-devel mailing list