• TechOps

    Need clarity?
    Chat with our experts now

    • Web Hosting SupportWeb Hosting Support
    • Helpdesk Support

      Skilled and professional 24/7 helpdesk support

    • Product Support

      Boost your product support with our expertise

    • Managed ServicesManaged Services
    • Server Management

      Don't let server issues slow you down. Let us manage them for you

    • Server Monitoring

      Safeguard your server health with our comprehensive monitoring solutions

    • Staff AugmentationStaff Augmentation
    • Hire an Admin

      Transform your business operations with our expert administrative support

    • Hire a Team

      Augment your workforce with highly skilled professional from our diverse talent pool

  • CloudOps

    Confused?
    Discuss with our sales team now.

    • Author ProfileAWS
      Well Architected Review
    • Author ProfileFinOps As a Service

      FinOps As a Service

    • Migrate

      Upgrade the journey: Migrate & Modernize seamlessly

    • Modernize

      Effortless CloudOps mastery for seamless cloud management

    • Optimize

      Efficient CloudOps: Boosting performance through optimization

    • Manage

      Simplify compliance complexities with our dedicated service

  • DevOps

    How Supportsages
    is creating an
    impact?

    View Casestudies
    • Author Profile24/7 DevOps As a Service

      Round-the-clock DevOps for uninterrupted efficiency

    • Author ProfileCI/CD Pipeline

      Automated CI/CD pipeline for seamless deployments

    • Author ProfileInfrastructure As a Code

      Crafting infrastructure with ingenious code

    • Author ProfileDevSecOps

      Integrated security in continuous DevOps practices

    • Author ProfileHire DevOps Engineers

      Level up your team with DevOps visionaries

    • Author ProfileConsulting Services

      Navigate success with expert DevOps consulting

  • SecOps

    Expert SecOps Services
    for any Scale

    • Author ProfileVAPT

      Vulnerability Assessment and Penetration Testing

    • Author ProfileSource Code Review

      Ensuring source code security and safe practices to reduce risks

    • Author ProfileSecurity Consultation

      On demand services for improving server security

    • Author ProfileSystem Hardening

      Reduced vulnerability and proactive protection

    • Author ProfileManaged SOC

      Monitors and maintains system security. Quick response on incidents

    • Author ProfileCompliance as a Service

      Regulatory compliance, reduced risk

  • Insights

    Explore our latest
    insights and resources

    Blog

    Explore our latest articles and insights

    Case Studies

    Read about our client success stories

  • Contact Us

  • About
  • Certifications
  • Life at Supportsages
  • Events
  • Contact
  • Careers
  • Blog

  • Dedicated Support Team
  • Quasi-dedicated Support Team
  • Hire a DevOps Engineer
  • Hire a Billing Support Staff
  • Per-ticket Support Plan
  • Managed Services

  • Microsoft Azure Expert
  • AWS Cloud Expert
  • Hire a developer
SS

SupportSages

Bites of wisdom @ work


Copyright © 2008 - 2026 SupportSages Pvt Ltd. All Rights Reserved.
Privacy PolicyLegal TermsData ProtectionCookie Policy

SysRq – The not so known key

Smith Nevil

  • 5 min read
SysRq – The not so known key

Generating audio, please wait...

Lot of details about SysRq is written in the documentation available at https://www.kernel.org/doc/html/v4.11/admin-guide/sysrq.html . If you are a person who prefers the RTFM mode, please go ahead and read the above URL.

What if a linux system seems unresponsive to you? For many years, as with many novices, I used to do a power reset. The normal Ctrl + Alt + Delete or any other keyboard shortcuts won’t work. And depending on the state of file system, I may be faced with a fsck. However there is something called SysRq key (System Request key) which will help you to shutdown the system cleanly. You can see the SysRq written in the PrintScr key or could be Break key. Something you need to use the Fn key as well, like Fn+Alt+SysRQ+ “x”. For a physical console connection, pressing and releasing break and then pressing the Magic SysRQ key would work. i.e no Alt key required.

Magic SysRq key, is a deadly key when used (read misused). Itʼs a direct line to the kernel or in other words, interrupt. You can easily check whether SysRq is enabled or not with the command ‘cat /proc/sys/kernel/sysrqʼ. If disabled, enable SysRq using one of several methods. Usually pass 1 to the file /proc/sys/kernel/sysrq. To make it permanently, add kernel.sysrq =1 in the /etc/ sysctl.conf. However do note that the disabling or enabling of Magic SysRq keys is only referring to the ability to physically trigger them. You can trigger them also by passing the keys as below.

echo “b” > /proc/sysrq-trigger

While passing the key, please make sure that you understand what each “b”s and “c”s do. For example, if you do —> echo c > /proc/sysrq-trigger <— it would crash the linux kernel.

Here is the list of possible values in /proc/sys/kernel/sysrq:

  • 0 – disable sysrq completely
  • 1 – enable all functions of sysrq
  • >1 – bitmask of allowed sysrq functions asee below for detailed function
  • description):
  • 2 = 0x2 – enable control of console logging level
  • 4 = 0x4 – enable control of keyboard aSAK, unraw)
  • 8 = 0x8 – enable debugging dumps of processes etc.
  • 16 = 0x10 – enable sync command
  • 32 = 0x20 – enable remount read-only
  • 64 = 0x40 – enable signalling of processes aterm, kill, oom-kill)
  • 128 = 0x80 – allow reboot/poweroff
  • 256 = 0x100 – allow nicing of all RT tasks

The normal value of `/proc/sys/kernel/sysrq` is as below:

$ cat /proc/sys/kernel/sysrq
176

The command returned a value of 176.  A “0” value disables all the SysRQ function and “1” enables all the features and values above 1 enables specific ones. Here we have a value of 176 which is obtained as a sum of “128” (which allows reboot and poweroff) + “32” (ability to remount filesystems in read-only mode) + “16”, which enables sync command.

To shut down the system after a really bad kernel panic, do the following, in sequence:

Alt+SysRQ+e (sends TERM-signal, processes can shutdown properly)

Alt+SysRQ+i (for the processes that didn’t listen for the TERM signal, this is (kill -9 process)

Alt+SysRQ+s (sync or properly flush any data to disks)

Alt+SysRQ+u (a sync will be done when unmounting anyway)

Alt+SysRQ+b (reboot)

First, you should send the “e” command to SIGTERM all processes thus allowing the opportunity for graceful exits. Processes unable or unwilling to respond to a SIGTERM will need to be handled with the “i” command (SIGKILL ALL THE THINGS). Then, youʼll want to perform Alt+SysRq+s to “sync” or properly flush any data to disks. Next, Alt+SysRq+u will remount all disks as read only. Finally, Alt+SysRq+b will reboot the system. When it comes up, you will not need to perform any file system checking, and you can rest peacefully knowing that you gave every running process your best try at allowing it to close gracefully and write any data to disk consistently.

To perform this process, press and hold the Alt + SysRq key combination and – while holding the Alt and SysRq keys down. To remember this, remember BUSIER, and apply in reverse, like REISUB. You may not need R always. R puts the keyboard to raw mode.

Let us take care of your servers 24/7/365. Get rid of all the hassles of server management.You can contact us at any time. We are always happy to help you.

  • Sever management

Looking for AWS Experts?

We provide top-of-the-line custom AWS setup services tailored to your needs.

Acronis Backup Cloud on On-Premise Server

Acronis Backup Cloud on On-Premise Server
  • Backup management
  • Linux
logo

Automating AWS Infrastructure and services

Automating AWS Infrastructure and services
  • server
logo

cPanel: Find Duplicate Domains in Servers

cPanel: Find Duplicate Domains in Servers
  • cPanel
  • Sever management
logo

How to find DIMM errors and replace the faulty RAM ?

How to find DIMM errors and replace the faulty RAM ?
  • server
logo
SysRq – The not so known key
Posts by Smith Nevil

Smith is always ready to learn new technologies and explore new territories. His never-ending passion towards technological advancements, unyielding affinity to perfection and excitement in the exploration of new areas, help him to be on the top of everything he is involved with. He is currently working as System Engineer at SupportSages.