lilo config maker script added
This commit is contained in:
parent
3d0afc2944
commit
4af04f573d
|
@ -0,0 +1,32 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
IMG=$(ls /boot/vmlinuz*|sort -r|sed 1q)
|
||||||
|
|
||||||
|
VERS=$(echo $IMG | sed 's/\/boot\/vmlinuz-//')
|
||||||
|
|
||||||
|
INIT=/boot/initramfs-$VERS.img
|
||||||
|
|
||||||
|
ROOT_UUID=$(cat /etc/fstab|grep "UUID"|awk '{print $1}')
|
||||||
|
|
||||||
|
LBOOT="$1"
|
||||||
|
|
||||||
|
|
||||||
|
#global setup
|
||||||
|
printf "boot=$LBOOT
|
||||||
|
prompt
|
||||||
|
timeout=150
|
||||||
|
lba32
|
||||||
|
root=\"$ROOT_UUID\"
|
||||||
|
vga=normal
|
||||||
|
read-only
|
||||||
|
menu-title=\"edbarz9's computer\"
|
||||||
|
\n\n
|
||||||
|
|
||||||
|
#image setup
|
||||||
|
image = $IMG
|
||||||
|
\tlabel = \"$VERS\"
|
||||||
|
\t#root = \"$ROOT_UUID\"
|
||||||
|
\tread-only
|
||||||
|
\tinitrd = $INIT\n" > /etc/lilo.conf
|
||||||
|
|
||||||
|
lilo
|
Loading…
Reference in New Issue