# OpenBSD impressions...



## Deleted member 63539 (Aug 30, 2020)

First, OpenBSD can't found the installation set even though the install67.fs image was used. The only way to get the set is via http with the server cdn.openbsd.org.

Second, OpenBSD doesn't need any dbus-launch or ck-launch-session in .xinitrc like FreeBSD, only exec startxfce4 is enough, shutdown and reboot via menu works seamlessly.

Third, the way OpenBSD install packages different than us. It's because their security "features":

/usr/local and /usr are both used to install packages
/usr/local is a separate file system, mounted with the option wxallowed

Fourth, many libraries installed without creating the correct symlinks, e.g: libfoo.so.18 but no libfoo.so, we have to create the symlinks ourselves.

Fifth, gcc and g++ are separate package, we have to install both to get a working gcc compiler. By default, the gcc and g++ both default to the old version shipped with the system. The correct gcc and g++ binary are egcc and eg++.

This gcc version is buggy, avoid it ang use clang, the system compiler.

One of it bugs: cc1plus: out of memory allocating 93600 bytes after a total of 0 bytes

It seemed the problem is with the source file's encoding, not because of lacking of memory available:









						How to diagnose g++ error "cc1plus.exe: out of memory allocating 838860800 bytes" in moderately sized project?
					

I'm attempting to port my C++ library to g++ using rudimentary makefile (it compiles well in Visual Studio). The portion I'm trying to compile right now measures at about 45000 lines of code.  The




					stackoverflow.com
				




Sixth, openjdk package on OpenBSD is not named openjdk but just jdk, e.g: jdk-1.8.0, jdk-11. They are not included in PATH, they are installed in /usr/local/jdk-1.8.0 or /usr/local/jdk-11.

Seventh, to be able to use autotools on OpenBSD, we need to define extra environment variables:

automake: export AUTOMAKE_VERSION=1.16
autoconf: export AUTOCONF_VERSION=2.69

Eighth, X11 and freetype2 location is /usr/X11R6, headers are in /usr/X11R6/include. On FreeBSD, these headers are in /usr/local/include.

Ninth, if you searched for package via pkg_info -Q [package name], you will found that it not always show the full list of packages with this name.

Tenth, raw device vs block device:

/dev/sd1c: entire disk, block device
/dev/sd1a: a partition
/dev/rsd1c: entire disk, raw device
/dev/rsd1a: a partition

raw device: direct access, no caches, no buffers => use for things like dd.

block device: only for mounting.

I always have trouble to remember putting an 'r' before device name for use with dd.

The last, the sound quality is very good. It's the biggest plus for me about this OS.


----------



## Deleted member 63539 (Aug 30, 2020)

Almost forgot, this boot loader bug, too:









						Solved - Bhyve - How to install OpenBSD?
					

I'm using vm-bhyve. Here is my openbsd.conf:  loader="uefi" cpu=4 memory=4G network0_type="virtio-net" network0_switch="public" disk0_type="ahci-hd" disk0_name="disk0.img" disk1_type="ahci-hd" disk1_name="install67.fs" graphics="yes" xhci_mouse="yes" graphics_res="1600x900" graphics_wait="yes"...




					forums.freebsd.org
				




p/s: the above review was done on real hardware, but I have troubled to be able to install it on Bhyve with this boot loader bug, too.


----------

