Upgrade

FreeBSD - Upgrade to 13.2

Upgrade FreeBSD 13.1 to 13.2

reading some NewFeeds, FreeBSD 13.2 got released … Let’s do an upgrade and see if it’s working fine.

Patch it first

freebsd-update fetch
freebsd-update install

reboot

may not needed, but you have to boot anyway a few times …

Fetch and Upgrade to 13.2

this needs some time ! depending on your internet speed, and specially to power and filesystem performance of your machine. 5-10min for a common VM is not unreal :(

OpenBGPD - Upgrade Looking Glass

I’m running a BGP Looking Glass Server on https://bgp.stoege.net, where can get some view about BGP running on the Global Internet.

Upgrade to 7.2

Did an Upgrade to the latest Version with my Script.

Upgrade was sucessful, but the BGP Service needs some Fix. Website show as “500 Internal Server Error”, and the Logs got a few messages like this:

tail -f /var/log/messages

Oct 21 11:38:07 bapi slowcgi[62677]: execve /cgi-bin/bgplg: Permission denied
Oct 21 11:38:07 bapi slowcgi[93993]: caught exit of unknown child 62677
Oct 21 11:38:12 bapi slowcgi[45500]: execve /cgi-bin/bgplg: Permission denied

Reapply the Permission

chmod 0550 /var/www/cgi-bin/bgplg
chown www:daemon /var/www/cgi-bin/bgplg

chmod 0555 /var/www/bin/bgpctl
chmod 4555 /var/www/bin/ping* /var/www/bin/traceroute*

Check Service

$ curl --head "https://bgp.stoege.net/cgi-bin/bgplg"
HTTP/1.1 200 OK
Cache-Control: no-cache
Connection: keep-alive
Content-Type: text/html
Date: Fri, 21 Oct 2022 09:45:38 GMT
Server: OpenBSD httpd
Transfer-Encoding: chunked

and we’re back again …

FreeBSD - Upgrade 13.0 to 13.1

Upgrade FreeBSD 13.0 to 13.1

should be a easy task, right ?

Patch it first

freebsd-update fetch
freebsd-update install

reboot

may not needed, but you have to boot anyway a few times …

Fetch and Upgrade to 13.1

this needs some time ! depending on your internet speed, and specially to power and filesystem performance of your machine. 20-30min for a common VM is not unreal :(

time freebsd-update upgrade -r 13.1-RELEASE
time freebsd-update install

Reboot

shutdown -r now

Finish Install

freebsd-update install

Final Reboot

shutdown -r now

Any Comments ?

sha256: f5d56eadc5e7a757d4a2af764da5a0446ebb246ce6ea630b158a53dc3a160996

Update_hugo

how to update hugo

you can use ports (pkg_add hugo) and get the lastest stable hugo package based on OpenBSD release cycles (2 x year), or grab the latest binary from github and put it on your machine.

Releases: https://github.com/gohugoio/hugo/releases

cd /tmp
ftp https://github.com/gohugoio/hugo/releases/download/v0.62.0/hugo_0.62.0_OpenBSD-64bit.tar.gz
tar xfz hugo_0.62.0_OpenBSD-64bit.tar.gz
doas mv hugo /usr/local/bin/

or find latest automatically

doas su -
cd /tmp/
u=$(lynx -dump -listonly https://github.com/gohugoio/hugo/releases/latest |grep "OpenBSD-64bit" |sed 's/.*https/https/')
f=$(echo $u |sed 's/.*\///')
ftp $u
tar xfz $f
doas mv hugo /usr/local/bin/
rm $f

or extract automatically

Openbsd upgrade 6.6

OpenBSD 6.6 is released today. here is my upgrade procedure:

run sysmerge

reboot

run script:

#!/bin/sh

# be nice and verbose
e() {
  echo "\n$1 **"
}

e "** vars"
_mydir=$(pwd)

e "** build base urls"
_path_base=https://cdn.openbsd.org/pub/OpenBSD/6.6/amd64/
_path_pkg=https://cdn.openbsd.org/pub/OpenBSD/6.6/packages/amd64/
echo "_path_base: ${_path_base}"
echo "_path_pkg: ${_path_pkg}"

e "** make all devices"
cd /dev
./MAKEDEV all || exit 1

e "** cd /tmp"
cd /tmp

e "** install boot loader"
_boot=$(mount |awk -F'[/ ]' '/ on \/ / {print $3}')
installboot ${_boot%?}

e "** hash new Kernel"

 
Any Comments ?
sha256 -h /var/db/kernel.SHA256 /bsd e "** export URL for pkg upgrade" echo "export PKG_PATH=${_path_pkg}" export PKG_PATH="${_path_pkg}" e "** run sysmerge" sysmerge e "** run fw update" fw_update -v e "** run pkg update" pkg_add -Vu e "** index new man pages" makewhatis e "** Update Acme Client API" sed -i s'/acme-v01.api.letsencrypt.org/acme-v02.api.letsencrypt.org/' /etc/acme-client.conf e "** files to remove" rm -f /usr/share/man/man3p/carp.3p \ /usr/share/man/man3p/Tie::ExtraHash.3p \ /usr/share/man/man3p/Tie::StdHash.3p \ /usr/share/man/man3p/Tie::StdScalar.3p \ /usr/share/man/man3p/basename.3p \ /usr/share/man/man3p/cluck.3p \ /usr/share/man/man3p/confess.3p \ /usr/share/man/man3p/croak.3p \ /usr/share/man/man3p/dirname.3p \ /usr/share/man/man3p/fileparse.3p \ /usr/share/man/man3p/getopt.3p \ /usr/share/man/man3p/getopts.3p \ /usr/share/man/man3p/inet_aton.3p \ /usr/share/man/man3p/inet_ntoa.3p \ /usr/share/man/man3p/longmess.3p \ /usr/share/man/man3p/look.3p \ /usr/share/man/man3p/open2.3p \ /usr/share/man/man3p/open3.3p \ /usr/share/man/man3p/pod2usage.3p \ /usr/share/man/man3p/podchecker.3p \ /usr/share/man/man3p/podselect.3p \ /usr/share/man/man3p/shortmess.3p \ /usr/share/man/man3p/sockaddr_in.3p \ /usr/share/man/man3p/sockaddr_un.3p \ /usr/share/man/man3p/writemain.3p rm -f /usr/sbin/snmpctl \ /usr/share/man/man8/snmpctl.8 rm -f /usr/X11R6/lib/pkgconfig/libfs.pc \ /usr/X11R6/include/X11/fonts/FSlib.h rm -rf /usr/X11R6/share/doc/libFS rm -f /usr/X11R6/bin/xman \ /usr/X11R6/lib/X11/xman.help \ /usr/X11R6/man/man1/xman.1 \ /usr/X11R6/share/X11/app-defaults/Xman rm -f /usr/X11R6/bin/xman \ /usr/X11R6/lib/X11/xman.help \ /usr/X11R6/man/man1/xman.1 \ /usr/X11R6/share/X11/app-defaults/Xman \ /usr/X11R6/lib/pkgconfig/libfs.pc \ /usr/X11R6/lib/modules/v10002d.uc \ /usr/X11R6/lib/modules/v20002d.uc \ /usr/X11R6/lib/modules/drivers/ark_drv.la \ /usr/X11R6/lib/modules/drivers/ark_drv.so \ /usr/X11R6/lib/modules/drivers/chips_drv.la \ /usr/X11R6/lib/modules/drivers/chips_drv.so \ /usr/X11R6/lib/modules/drivers/glint_drv.la \ /usr/X11R6/lib/modules/drivers/glint_drv.so \ /usr/X11R6/lib/modules/drivers/i128_drv.la \ /usr/X11R6/lib/modules/drivers/i128_drv.so \ /usr/X11R6/lib/modules/drivers/neomagic_drv.la \ /usr/X11R6/lib/modules/drivers/neomagic_drv.so \ /usr/X11R6/lib/modules/drivers/rendition_drv.la \ /usr/X11R6/lib/modules/drivers/rendition_drv.so \ /usr/X11R6/lib/modules/drivers/s3_drv.la \ /usr/X11R6/lib/modules/drivers/s3_drv.so \ /usr/X11R6/lib/modules/drivers/s3virge_drv.la \ /usr/X11R6/lib/modules/drivers/s3virge_drv.so \ /usr/X11R6/lib/modules/drivers/sis_drv.la \ /usr/X11R6/lib/modules/drivers/sis_drv.so \ /usr/X11R6/lib/modules/drivers/tdfx_drv.la \ /usr/X11R6/lib/modules/drivers/tdfx_drv.so \ /usr/X11R6/lib/modules/drivers/trident_drv.la \ /usr/X11R6/lib/modules/drivers/trident_drv.so \ /usr/X11R6/lib/modules/drivers/tseng_drv.la \ /usr/X11R6/lib/modules/drivers/tseng_drv.so \ /usr/X11R6/man/man4/chips.4 \ /usr/X11R6/man/man4/glint.4 \ /usr/X11R6/man/man4/i128.4 \ /usr/X11R6/man/man4/neomagic.4 \ /usr/X11R6/man/man4/rendition.4 \ /usr/X11R6/man/man4/s3.4 \ /usr/X11R6/man/man4/s3virge.4 \ /usr/X11R6/man/man4/sis.4 \ /usr/X11R6/man/man4/tdfx.4 \ /usr/X11R6/man/man4/trident.4 \ /usr/X11R6/man/man4/tseng.4 \ /usr/X11R6/man/man3/XkbAllocGeomOverlayKey.3 rm -f /usr/X11R6/include/X11/fonts/FSlib.h \ /usr/include/dev/ic/dwc_gmac_reg.h \ /usr/include/dev/ic/dwc_gmac_var.h \ /usr/include/llvm/Analysis/IndirectCallSiteVisitor.h \ /usr/include/llvm/CodeGen/GCs.h \ /usr/include/llvm/DebugInfo/PDB/Native/NativeBuiltinSymbol.h \ /usr/include/llvm/DebugInfo/PDB/Native/NativeEnumSymbol.h \ /usr/include/llvm/IR/TypeBuilder.h \ /usr/include/llvm/Transforms/Utils/OrderedInstructions.h rm -f /usr/share/man/man1/clang++.1 \ /usr/share/man/man1/clang-cpp.1 \ /usr/share/man/man1/diagnostics.1 \ /usr/share/man/man3/SipHash24.3 \ /usr/share/man/man3/bitstring.3 \ /usr/share/man/man3/byteorder.3 \ /usr/share/man/man3/directory.3 \ /usr/share/man/man3/ethers.3 \ /usr/share/man/man3/exec.3 \ /usr/share/man/man3/fts.3 \ /usr/share/man/man3/getcap.3 \ /usr/share/man/man3/inet_net.3 \ /usr/share/man/man3/md5.3 \ /usr/share/man/man3/pcap-filter.3 \ /usr/share/man/man3/pcap.3 \ /usr/share/man/man3/pwcache.3 \ /usr/share/man/man3/resolver.3 \ /usr/share/man/man3/rmd160.3 \ /usr/share/man/man3/sha1.3 \ /usr/share/man/man3/sha2.3 \ /usr/share/man/man3/stdarg.3 \ /usr/share/man/man3/uucplock.3 \ /usr/share/man/man3/uuid.3 \ /usr/share/man/man3/ypclnt.3 \ /usr/share/man/man4/i386/vmm.4 \ /usr/share/man/man4/macppc/openprom.4 \ /usr/share/man/man4/sparc64/openprom.4 e "** remove myself" cd ${_mydir} rm $0 e "** done !"

Any Comments ?

sha256: 2bb8d98fff6c458bd85b32a50afb0c31b65a2cd8a0599fdc891b567334464552