Merge "Replace SYSRQ commands"
This commit is contained in:
commit
6b8ef9a854
@ -14,16 +14,13 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
# This script reboots by echoing into /proc/sysrq_trigger.
|
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
# Make sure all functions of sysrq is enabled.
|
# flush file system buffers
|
||||||
echo "1" > /proc/sys/kernel/sysrq
|
sync
|
||||||
|
|
||||||
echo "s" > /proc/sysrq-trigger
|
|
||||||
if [[ $1 = '-h' ]]; then
|
if [[ $1 = '-h' ]]; then
|
||||||
echo "o" > /proc/sysrq-trigger
|
poweroff
|
||||||
elif [[ $1 = '-r' ]]; then
|
elif [[ $1 = '-r' ]]; then
|
||||||
echo "b" > /proc/sysrq-trigger
|
reboot
|
||||||
fi
|
fi
|
||||||
|
7
releasenotes/notes/remove-sysrq-2c2804930180f408.yaml
Normal file
7
releasenotes/notes/remove-sysrq-2c2804930180f408.yaml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- Stop using SYSRQ when performing the in-band reboot or power off
|
||||||
|
because it has a similar effect to a hardware reset button/power
|
||||||
|
switch and can be problematic on some hardware types. Instead,
|
||||||
|
reboot/power off the node via the "poweroff" and "reboot" commands
|
||||||
|
(soft power action).
|
Loading…
x
Reference in New Issue
Block a user