mirror of
https://github.com/leitbogioro/Tools.git
synced 2025-10-09 23:05:49 +08:00
Update RHELinit.sh
This commit is contained in:
parent
64d5a79421
commit
07c8b76a84
1 changed files with 8 additions and 1 deletions
|
@ -2,7 +2,14 @@
|
|||
#
|
||||
# Alpine Linux use "ash" as the default shell.
|
||||
|
||||
exec >/dev/tty0 2>&1
|
||||
# Find available temporary tty.
|
||||
for ttyItems in "/dev/tty0" "/dev/ttyS0" "/dev/ttyAMA0"; do
|
||||
ttyAttribute=$(stty -F "$ttyItems")
|
||||
[[ -n "$ttyAttribute" && -n $(echo "$ttyAttribute" | grep -io "\-brkint ixoff \-imaxbel") ]] && {
|
||||
break
|
||||
}
|
||||
done
|
||||
exec >"$ttyItems" 2>&1
|
||||
|
||||
# Delete the initial script itself to prevent to be executed in the new system.
|
||||
rm -f /etc/local.d/rhelConf.start
|
||||
|
|
Loading…
Add table
Reference in a new issue