OpenBSD

OpenBSD RDomains

Intro Let’s assume you have a Mikrotik Router which got a Mgmt Interface with IP: ‘192.168.88.1/24’ and DHCP Server enabled. You wann Access the Router via HTTP/HTTPS while offering Internet Services for the Mikrotik Router. You have an APU and OpenBSD running. What do you do ? Setup 2 NIC’s em0: dhcp client, default route, rdomain 0 em3: dhcp client, rdomain 3 Interfaces Interface em0 cat << 'EOF' > /etc/hostname.em0 # Public Internet inet autoconf inet6 autoconf EOF Interface em3

OpenBSD - USB

dmesg show disks dmesg |grep ^sd. sd0 at scsibus1 targ 0 lun 0: <ATA, KingFast, T031> t10.ATA_KingFast_04xxxxxxxxxxxx sd0: 114473MB, 512 bytes/sector, 234441648 sectors, thin sd1 at scsibus4 targ 1 lun 0: <JetFlash, Transcend 8GB, 1100> removable serial.85xxxxxxxxxxxxxxxxxx sd1: 7450MB, 512 bytes/sector, 15257600 sectors Show DiskLabel sysctl hw.disknames hw.disknames=sd0:9axxxxxxxxxxxxxx,sd1:60xxxxxxxxxxxxxx Show Disklabel sd1 disklabel sd1 disklabel sd1 # /dev/rsd1c: type: SCSI disk: SCSI disk label: Transcend 8GB duid: 60xxxxxxxxxxxxxx flags: bytes/sector: 512 sectors/track: 63 tracks/cylinder: 255 sectors/cylinder: 16065 cylinders: 949 total sectors: 15257600 boundstart: 64 boundend: 15257600 16 partitions: # size offset fstype [fsize bsize cpg] c: 15257600 0 unused Fdisk kill everything

Hetzner - Arm64 OpenBSD

OpenBSD on ARM64 at Hetzner DC Price/Performance is unbeatable at Hetzner for arm64 virtual machines. A Server (CAX21) with 4 CPU, 8 GB RAM, 80 GB Disk, 20 TB Traffic/month cost around 7 Euros/Month. Let’s build a Template for OpenBSD. Here is how todo it: Get Server with CAX21 (4 CPU, 8 GB RAM, 80 GB Disk), with Debian or Ubuntu Menu “ISO-Images”, mount Image “OpenBSD 7.4-current 2023-11-03 (arm64)” Reboot the VM Install OpenBSD as usual Disk: sd0 Use (W)hole disk (E)dit auto layout Delete all Partitions execpt Partition “i” (MSDOS) Build Disk Layout as you like.

APU - Firmware Upgrade

intro as we all know, the apu’s from pcengines are eol. but it’s worth to bring the existing ones to the latest firmware. if you have openbsd running on your boxes, you can upgrade it with like this: add packages doas pkg_add -i flashrom pciutils set hostname based on apu version and mac of em0 type=$(dmesg |grep ^bios0: |tail -1 |sed 's/.*gines //') mac=$(ifconfig em0 |awk '/lladdr/ {print $2}' |awk -F':' '{printf "%s-%s-%s\n",$4, $5, $6}') echo "${type}-${mac}" |tee /etc/myname; hostname $(cat /etc/myname) sample

Python Versions

History Long time ago, there were huge discussions about Python 2.7 or Python 3.xx. Fortunately, these times are gone and we’ve all gotten over the hurdle to Python 3. But are you on 3.6, 3.7, 3.8 ? or even 3.11 or 3.12 ? That’s the current Version you should use for your daily Projects ? Status of Python versions A good indicator is this Website: https://devguide.python.org/versions/ OpenBSD It’s also recommended to check what our Operating System is installing by default, or what you can get from their Package Repository.

OpenBSD 7.4

OpenBSD 7.4 finally released Today, the 55th Release of OpenBSD was announced. My Upgrade Script is available here. Highlights vmd(8) has moved to a multi-process model for virtio(4) block and network devices malloc(3) now has built-in leak detection In OpenSSH 9.5, ssh-kengen(1) generates Ed25519 keys by default sec(4) for Route Based IPSec VPNs see the Post on Undeadly for more Details, or the OpenBSD Page … Script doas su - cd /root ftp https://blog.

OpenBSD 7.4 DevBox

OpenBSD 7.4 … will be released next week (23. Oct 2023). Why not have a look at the upcomming OS and prepare a VM for Software Development ? Preparation grab a fresh VM and Install OpenBSD 7.4 os version puffy74# sysctl kern.version kern.version=OpenBSD 7.4 (GENERIC.MP) #1396: Sun Oct 8 09:20:40 MDT 2023 deraadt@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP empty vm puffy74# pkg_info quirks-6.159 exceptions to pkg_add rules and cache add go, rust, python puffy74# pkg_add go rust python3 quirks-6.

OpenBSD - Nornir

Build Nornir on OpenBSD - Failed :( Any Idea how to build it … ? (cisco-nornir-py3.11) puffy$ RUST_BACKTRACE=1 poetry add nornir-netmiko ... Compiling asn1 v0.13.0 Running `rustc --crate-name asn1 --edition=2018 /home/stoege/.cargo/registry/src/github.com-1ecc6299db9ec823/asn1-0.13.0/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C linker-plugin-lto -C overflow-checks=on -C metadata=e01d853059c772ba -C extra-filename=-e01d853059c772ba --out-dir /tmp/tmpyhzdyoqa/cryptography-40.0.2/src/rust/target/release/deps -L dependency=/tmp/tmpyhzdyoqa/cryptography-40.0.2/src/rust/target/release/deps --extern asn1_derive=/tmp/tmpyhzdyoqa/cryptography-40.0.2/src/rust/target/release/deps/libasn1_derive-dbeffd4d85568b7f.so --extern chrono=/tmp/tmpyhzdyoqa/cryptography-40.0.2/src/rust/target/release/deps/libchrono-994a1164a0b8cdf4.rmeta --cap-lints allow` Running `rustc --crate-name pyo3 --edition=2018 /home/stoege/.cargo/registry/src/github.com-1ecc6299db9ec823/pyo3-0.15.2/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C linker-plugin-lto -C overflow-checks=on --cfg 'feature="abi3"' --cfg 'feature="abi3-py310"' --cfg 'feature="abi3-py36"' --cfg 'feature="abi3-py37"' --cfg 'feature="abi3-py38"' --cfg 'feature="abi3-py39"' --cfg 'feature="default"' --cfg 'feature="extension-module"' --cfg 'feature="indoc"' --cfg 'feature="macros"' --cfg 'feature="paste"' --cfg 'feature="pyo3-macros"' --cfg 'feature="unindent"' -C metadata=001198fe1619b05c -C extra-filename=-001198fe1619b05c --out-dir /tmp/tmpyhzdyoqa/cryptography-40.

iperf3 - rdomain

how do i run a iperf3 server in a rdomain ? if you don’t know what a rdomain is, just have a look at the man pages show interface with rdomain -> rdomain 1 show that this Interface is not running in the Default RDomain 0 ifconfig em3 em3: flags=808843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,AUTOCONF4> rdomain 1 mtu 1500 lladdr de:ad:be:ef:be:ef description: connected to Switch (Gi0/1) index 4 priority 0 llprio 3 media: Ethernet autoselect (1000baseT full-duplex) status: active inet 192.

OpenBSD - ansible-pylibssh

wanna build ansible-pylibssh on OpenBSD 7.3 ? Build failed ? $ pip install ansible-pylibssh Defaulting to user installation because normal site-packages is not writeable Collecting ansible-pylibssh Using cached ansible-pylibssh-1.1.0.tar.gz (106 kB) Installing build dependencies ... done Getting requirements to build wheel ... done Installing backend dependencies ... done Preparing metadata (pyproject.toml) ... done Building wheels for collected packages: ansible-pylibssh Building wheel for ansible-pylibssh (pyproject.toml) ... error error: subprocess-exited-with-error × Building wheel for ansible-pylibssh (pyproject.