Operating System - HP-UX
1825667 Members
4224 Online
109686 Solutions
New Discussion

Re: Reboot from CDE Front Panel?

 
Matt Wardle
Advisor

Reboot from CDE Front Panel?

Is is possible to add an Option to reboot the workstation from the CDE front panel, like it is in Gnome (and most other desktops!!)

I don't think it's easy, but anyone any ideas?

Cheers,

Matt.

4 REPLIES 4
Pete Randall
Outstanding Contributor

Re: Reboot from CDE Front Panel?

Matt,

Sure, it's possible but you have to be root to issue the reboot or shutdown commands so you'll have to create an action on the front panel that invokes a suid script to accomplish this. As a general rule, suid scripts are considered security risks and you'll have to ask yourself if having a user be able to reboot his workstation at will is worth it.

I would have to ask why there is a need for this at all.


Pete

Pete
Marvin Strong
Honored Contributor

Re: Reboot from CDE Front Panel?

You could also just add the user to the shutdown.allow file on that workstation.

Matt Wardle
Advisor

Re: Reboot from CDE Front Panel?

Sorry - maybe I wasn't clear, I meant the CDE login screen. Maybe put something under the Options menu or a seperate button.

We need users to be able to reboot as we're 24/7 and w/s can only be rebooted at 7z and 20z, when shifts change. They need to reboot because the file table fills up due to our applications leaving some open - it's a gradual process. Yes I know we could fix the application! But that's development and not support.

Cheers.
Pete Randall
Outstanding Contributor

Re: Reboot from CDE Front Panel?

Matt,

I still wouldn't give the users the ability to reboot at will. I would set this up in root's crontab with the following entry:
00 07,20 * * * /usr/sbin/shutdown -r -y 60 1>/dev/null 2>&1

This will reboot the workstation every day at 0700 and 2000. You could set it to just weekdays with:

00 07,20 * * 1-5 /usr/sbin/shutdown -r -y 60 1>/dev/null 2>&1


Pete

Pete