From: "Theo de Raadt" Subject: Re: sysupgrade(8) says incompatible versions yet works To: Andrew Hewus Fresh Cc: tech@openbsd.org Date: Thu, 12 Nov 2026 06:47:50 -0600 I agree with you. > I was having an issue after installing a VM where /usr wasn't big enough > and my kernel relinking failed. I cleaned up some space and thought the > easiest fix would be to run through the upgrade to the version I'm > running. > > However, when doing that it said "incompatible options" but yet did what > I was hoping and "upgraded" to the running release. > > I'm not entirely sure why the `set -e` at the top doesn't stop the > script, something to do with the `!` confusing it I guess. > > $ sh -c 'set -e; f() { return 3; }; ! false && f; echo $?' > 3 > $ sh -c 'set -e; f() { return 3; }; (! false) && f; echo $?' > $ echo $? > 3 > > So, while we could wrap that `! $SNAP` in parens, is there a reson to > keep that check? > > > $ doas sysupgrade -f > sysupgrade: incompatible options: -f without -s > Fetching from https://cdn.openbsd.org/pub/OpenBSD/8.1/amd64/ > sysupgrade: Error retrieving https://cdn.openbsd.org/pub/OpenBSD/8.1/amd64/SHA256.sig: 404 Not Found > Fetching from https://cdn.openbsd.org/pub/OpenBSD/8.0/amd64/ > SHA256.sig 100% |*************************************| 2144 00:00 > Signature Verified > ... > > Index: sysupgrade.sh > =================================================================== > RCS file: /cvs/src/usr.sbin/sysupgrade/sysupgrade.sh,v > diff -u -p -r1.64 sysupgrade.sh > --- sysupgrade.sh 2 Nov 2026 15:31:39 -0000 1.64 > +++ sysupgrade.sh 11 Nov 2026 19:50:04 -0000 > @@ -120,8 +120,6 @@ esac > FILE=true > $FORCE_VERSION && $SNAP && > err "incompatible options: -s -R $NEXT_VERSION" > -$FORCE && ! $SNAP && > - err "incompatible options: -f without -s" > > USED_USR=$(df -P /usr | awk 'NR==2 {print substr($5, 1, length($5)-1)}') > if (( ${USED_USR} >= 90 )) && ! $FORCE; then >