Skip to content

Commit

Permalink
OpenBSD: Wait on kernel relink before syspatch (#3)
Browse files Browse the repository at this point in the history
Without this syspatch would sometimes fail. Relink check is taken from
OpenBSD syspatch tool:

https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/syspatch/syspatch.sh.diff?r1=1.133&r2=1.134
  • Loading branch information
jage authored Apr 13, 2024
1 parent 48d4e72 commit de93054
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions openbsd/scripts/postinstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ printf "%s\n" "$hostname" > /etc/myname
printf "127.0.0.1\tlocalhost %s\n" "$hostname" > /etc/hosts
printf "::1\t\tlocalhost %s\n" "$hostname" >> /etc/hosts

# wait until relink kernel is done, as it blocks syspatch
echo "Waiting on kernel relink"
while $(pgrep -qxf '/bin/ksh .*reorder_kernel'); do sleep 1; done

# list and install available patches
syspatch -c
# handle: "syspatch: updated itself, run it again to install missing patches"
Expand Down

0 comments on commit de93054

Please sign in to comment.