LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-08-2013, 12:33 PM   #16
joe_2000
Senior Member
 
Registered: Jul 2012
Location: Aachen, Germany
Distribution: Void, Debian
Posts: 1,016

Rep: Reputation: 308Reputation: 308Reputation: 308Reputation: 308

Quote:
Originally Posted by jefro View Post
It might be possible to assign a function key to a macro but I'd go with shivaa alias or make a script.
I think the thread starter's problem is that the screen goes dark. You can't do anything useful with scripts or aliases when your screen is blank, because you don't even know if your terminal window has focus while your are typing. If there actually is an open terminal window in the first place ...
 
Old 07-09-2013, 03:54 PM   #17
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,976

Rep: Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623Reputation: 3623
That may be true. I assumed the lamp going out on a terminal would have little effect on keys pressed. If it went into some other fault then we can't guess.

I'd think about setting the power button to do a graceful shutdown if possible. Laptops may not have full support for acpi or apm to do this.
 
Old 07-09-2013, 04:10 PM   #18
Madhu Desai
Member
 
Registered: Mar 2013
Distribution: Rocky, Fedora, Ubuntu
Posts: 541

Rep: Reputation: 153Reputation: 153
If the screen is blank, then best way to safely reboot is to use
Code:
Alt + SysRq + reisub
http://www.howtogeek.com/119127/use-...evel-commands/
 
Old 07-09-2013, 06:53 PM   #19
selfprogrammed
Member
 
Registered: Jan 2010
Location: Minnesota, USA
Distribution: Slackware 13.37, 14.2, 15.0
Posts: 635

Rep: Reputation: 154Reputation: 154
CTRL-ALT-DEL works even when not logged in. I use it to shutdown after logging off all users.

Magic-sysreq is meant for developers who hang their machines. It is very low level, and is not easy to use.

If magic-sysreq is compiled into the kernel (it is not on Slackware), then the appropriate key presses are (you cannot do this with one hand, and is difficult even with two hands):

Alt+SysReq+e : end all processes
Alt+SysReq+i : kill all processes
Alt+SysReq+s : sync
Alt+SysReq+u : unmount
Alt+SysReq+o : shutdown computer

Last edited by selfprogrammed; 07-09-2013 at 07:04 PM.
 
Old 07-11-2013, 04:24 PM   #20
sayhello_to_the_world
Member
 
Registered: May 2013
Posts: 229

Original Poster
Rep: Reputation: Disabled
hi joe hi at all

many many thanks for all the hints and the tipps. GREAT to hear that.

Quote:
Originally Posted by joe_2000 View Post
I think the thread starter's problem is that the screen goes dark. You can't do anything useful with scripts or aliases when your screen is blank, because you don't even know if your terminal window has focus while your are typing. If there actually is an open terminal window in the first place ...
you hit the point. this is the problem. i would benefit with / through a shortcut that resets the whole system.
probably the notebook does not support those WAYS OF rebooting.

but i will dig deeper into all the hints you and all the great supporters made.

thx alot for all you did!
 
Old 07-11-2013, 07:12 PM   #21
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,573

Rep: Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142Reputation: 2142
I think the easiest thing would be to create a script to shut down the machine, something like "sudo shutdown -h now", after making the proper modifications to the sudoers file to allow you to run shutdown without a password.

Then you can use your desktop environment's tools to assign a specific keyboard combination to that script, something like ctrl+alt+s. If you can't find or don't like the DE's keyboard shortcut GUI, you can always use xbindkeys instead.
 
Old 07-11-2013, 11:48 PM   #22
sayhello_to_the_world
Member
 
Registered: May 2013
Posts: 229

Original Poster
Rep: Reputation: Disabled
hello dear suidicaleggroll

many many thanks - that sounds terriffic. i love this idea.

well how to implemnent -

first thing; i write the script.
secondly: i put it to the machine
third i choose and assign a shortcut key-combination

that should be the was...

well question: is the script very difficult.

probably it goes over my head. For any and all help i would be very very happy and thankful!!!11
 
Old 07-12-2013, 03:55 AM   #23
joe_2000
Senior Member
 
Registered: Jul 2012
Location: Aachen, Germany
Distribution: Void, Debian
Posts: 1,016

Rep: Reputation: 308Reputation: 308Reputation: 308Reputation: 308
I actually gave you the script and the subsequent steps already in my previous post :-)

EDIT: Not my previous post but this one.

Last edited by joe_2000; 07-12-2013 at 04:29 AM.
 
Old 07-16-2013, 04:40 PM   #24
sayhello_to_the_world
Member
 
Registered: May 2013
Posts: 229

Original Poster
Rep: Reputation: Disabled
hi there good day dear Joe

many many thanks!

Quote:
Originally Posted by joe_2000 View Post
I actually gave you the script and the subsequent steps already in my previous post :-)

EDIT: Not my previous post but this one.
you are great! - greetings

say
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Shortcuts to switch to open applications wogri Linux - Desktop 3 02-09-2010 06:49 AM
Can you switch on a linux machine using x10? bedazzled Linux - General 14 02-01-2010 07:07 AM
KDE custom shortcuts to switch between layots ?!! slashams Debian 1 02-24-2007 04:44 PM
networking my linux machine with my xp machine through a 3com switch chefkahuna Linux - Networking 1 07-06-2005 09:01 AM
How to switch workspaces in Fluxbox via keyboard shortcuts? oxblood Linux - Software 3 01-08-2004 11:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration