Przeglądaj źródła

añado el script para ajustar el máximo numero de grupos en el arranque

develop
psarria 3 lat temu
rodzic
commit
f12b08b09e
1 zmienionych plików z 46 dodań i 0 usunięć
  1. +46
    -0
      custom_boot.sh

+ 46
- 0
custom_boot.sh Wyświetl plik

@@ -0,0 +1,46 @@
#!/usr/bin/bash

usage()
{
echo "Usage: $0 [ -d dirname ]" >&2
echo "ex: $0 -d /zones/boot/boot-20220113T011608Z"
exit 1
}

while getopts ":d:" opt;
do
case "$opt" in
d)
DIR=$OPTARG
;;
\?)
echo "Error: Invalid Option: -${OPTARG}" >&2
usage
;;
:)
echo "Error: -${OPTARG} requires an argument."
usage
;;
*)
usage
;;
esac
done

shift $((OPTIND -1 ))

if [ -z ${DIR} ]; then
usage
fi

mkdir -p $DIR/bootfs/etc
cp /etc/system $DIR/bootfs/etc/

echo 'set ngroups_max=1024' >> $DIR/bootfs/etc/system

cat << EOF >> $DIR/loader.conf.local
etc_system_load=YES
etc_system_type=file
etc_system_name=/boot/bootfs/etc/system
etc_system_flags="name=/etc/system"
EOF

Ładowanie…
Anuluj
Zapisz