Re: [systemd-devel] Bind key combination to isolate emergency mode
On Sat, 20.06.15 17:35, Thomas Meyer (tho...@m3y3r.de) wrote: > > Also don't forget the magic SysRq keys – Alt+SysRq+F will run the OOM > > killer in case of heavy swapping, Alt+SysRq+E/I will sigterm/sigkill > > all programs (systemd will restart gettys afterwards), and > > Alt+SysRq+N will renice high-priority processes. You need to enable > > this via sysctl.conf though. > > Hi Mantas, > > thanks for the hint. I will try this. > I remember that SysRq was once always enabled? It now seems to be > disabled in current Fedora releases. I think enabling F key should be > default. At least it shouldn't be possbile to do something bad with it, > or is it? well, it's an authenticated way to execute quite a few operations that are potentially risky, hence it's disabled by default. Executing potentially risky operations is fine, but only after auth. Lennart -- Lennart Poettering, Red Hat ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Bind key combination to isolate emergency mode
Am Samstag, den 20.06.2015, 18:01 +0300 schrieb Mantas Mikulėnas: > On Sat, Jun 20, 2015 at 5:26 PM, Thomas Meyer > wrote: > > Hi, > > > > Is it possible to bind a key combination in systemd to perform a > > switch into emergency mode or another target? > > > > And would this key binding also work in situations where the system > > is under heavy cpu load and heavy swapping? > Sort of. There's a single key combination (Alt+ArrowUp by default) > which maps to kbrequest.target, though it only works on the console > and not within Xorg & the likes. You can pull in emergency.target via > that. > > Also don't forget the magic SysRq keys – Alt+SysRq+F will run the OOM > killer in case of heavy swapping, Alt+SysRq+E/I will sigterm/sigkill > all programs (systemd will restart gettys afterwards), and > Alt+SysRq+N will renice high-priority processes. You need to enable > this via sysctl.conf though. Hi Mantas, thanks for the hint. I will try this. I remember that SysRq was once always enabled? It now seems to be disabled in current Fedora releases. I think enabling F key should be default. At least it shouldn't be possbile to do something bad with it, or is it? > > -- > Mantas Mikulėnas ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Bind key combination to isolate emergency mode
On Sat, Jun 20, 2015 at 5:26 PM, Thomas Meyer wrote: > Hi, > > Is it possible to bind a key combination in systemd to perform a switch > into emergency mode or another target? > > And would this key binding also work in situations where the system is > under heavy cpu load and heavy swapping? > Sort of. There's a single key combination (Alt+ArrowUp by default) which maps to kbrequest.target, though it only works on the console and not within Xorg & the likes. You can pull in emergency.target via that. Also don't forget the magic SysRq keys – Alt+SysRq+F will run the OOM killer in case of heavy swapping, Alt+SysRq+E/I will sigterm/sigkill all programs (systemd will restart gettys afterwards), and Alt+SysRq+N will renice high-priority processes. You need to enable this via sysctl.conf though. -- Mantas Mikulėnas ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Bind key combination to isolate emergency mode
Hi On Sat, Jun 20, 2015 at 4:26 PM, Thomas Meyer wrote: > Hi, > > Is it possible to bind a key combination in systemd to perform a switch into > emergency mode or another target? > > And would this key binding also work in situations where the system is under > heavy cpu load and heavy swapping? That's not implemented, no. You'd have to write a daemon which does this yourself. Thanks David ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel
[systemd-devel] Bind key combination to isolate emergency mode
Hi, Is it possible to bind a key combination in systemd to perform a switch into emergency mode or another target? And would this key binding also work in situations where the system is under heavy cpu load and heavy swapping? With kind regards Thomas ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel