I need to detect user inactivity on my Linux system, to poweroff it (quite headless wife, and quite expensive electric bills... :-).
I need to schedule the script (in crontab), so no X-depending tool will work, I suppose (no $DISPLAY available).
Any thoughts?
UPDATE
For "user inactivity" I mean user input inactivity (mouse and keyboard).
Xautolock may the right tool for you. It allows you to specify a amount of minutes of inactivity after which a command should get triggered.