Posts

How to use mdo in 5 steps

0. The steps 2 to 4 assume that you either are user root or switched to it by using su(1) 1. Test the Ring 3 command mdo(1) for the status quo as a normal user mdo whoami mdo: setcred() : Operation not permitted 2. Enable the Ring 0 module mac_do(4) by editing the loader.conf(5) file with ee(1) ee /boot/loader.conf mac_do_load="YES" 3. Load the Ring 0 module mac_do(4) with kldload(8) or just reboot with shutdown(8) kldload mac_do or shutdown -r now (first command will load the module immediately, the second one will load it via the previously added loader.conf entry) 4. Configure the rules by editing the sysctl.conf(5) file with ee(1) and load them into memory with sysctl(8) ee /etc/sysctl.conf # mac_do rules security.mac.do.rules="gid=0>uid=0,gid=*,+gid=*" and sysctl security.mac.do.rules="gid=0>uid=0,gid=*,+gid=*" (the rules in the file are only loaded at the next boot so we also have to load them into memory with sysctl) 5. Use the...

The current state of Intel Arc support on FreeBSD

Image
People had been keen-eared when Intel released its first discrete GPU since the i740 (if you don't count the ca. 50 pieces of i752 that were never sold) on Halloween of 2020. It was the Intel Iris Xe MAX GPU aimed at Laptops and a first dedicated graphics card that kind of served as a proof of concept for its successors, only ASUS and GUNNIR actually built dedicated cards based on this discrete GPU. (The Intel i752, a dedicated graphics card that was never officially sold) That's also what the codename DG1 stands for, the first generation of a discrete GPU that could be either used in mobile devices, embedded devices or in dedicated desktop graphics cards. All the different codenames can be quite confusing so I made a little table to overview all the current and future generations. DG Code Name Architecture Codename Linux Kernel  ¹ ² DG1 Iris Xe Xe ...

The dreaded EFI framebuffer freeze in FreeBSD

Image
If you ever booted FreeBSD or a system that is based on it like GhostBSD you may have come across this sight: The screen will just be stuck. If you're a beginner you will have no idea what happened. If you research a bit you will find the component that is responsible for this message : loader.efi , the UEFI variant of the FreeBSD boot loader . When I had this frozen screen I connected a serial cable to another PC, started PuTTY and could see the log messages totally fine, meaning it's just an output issue, the system is booting up normally in the background (unless you have another issue which causes an infinite boot loop). When you research this issue on the internet you mostly find 5 groups: Server users with a misconfigured serial port Desktop   users with multiple graphics cards Laptop users with multiple graphics cards Issues in virtual machines, e.g. Parallels Desktop for Mac Microcode and BIOS updates, see this thread and this post A workaround is to disable one GPU...

How to install Tiny11 on GhostBSD

Image
Now that we migrated from Windows and have a running GhostBSD system we may need an application that won't run via Wine on GhostBSD. But we can use a hypervisor and run Windows in a virtual machine. So that' s the opposite way when we tested GhostBSD on Windows. To do this we first need to install the hypvervisor component and a GUI for it. On FreeBSD systems the hypvervisor is called bhyve and one GUI for it is called bhyvemgr . If we go to System->Administration->Software Station we can select the needed components: GhostBSD-bhyve bhyvemgr Please note that bhyve-firmware and edk2-bhyve are also required but they are dependencies in bhyvemgr, so they will be automatically installed and we don't have to select them there. You may have also noticed that bhyvemgr is available in 3 flavors: bhyvemgr-gtk2, bhyvemgr-qt5 and bhyvemgr-qt6, these are different GUI toolkits, you can see a comparison here . I chose the Qt6 variant because it had the smallest install footprint...

The almost 10 year old mouse wheel bug in FreeBSD nobody cares about

When I first discovered this bug I first thought it was just a questionable key binding decision by GhostBSD author Eric Turgeon . But as it turned out this is a real bug. So what exactly is this bug? When you use your mouse wheel to scroll down it works perfectly fine but if you scroll up any program you are in just moves back and forth, e.g. up and down in directories in the file explorer or back and forward in your web browser. I was not the first to discover this bug, it is at least known since September of 2016. Here are some links that I attribute to it: 09/2016: FreeBSD Forums: mouse wheel strange behavior with firefox 12/2016: VirtualBox Forums: FreeBSD/TrueOS mouse wheel issues browser back command 10/2018: FreeBSD Forums: Sudden mouse movement change page in Web browsers 07/2019: KDE Community: Mouse wheel *scroll up* always jumps to cursor 06/2021: reddit: Anyone else having weird behaviour with scrolling the mouse wheel causing other actions? 12/2021: Google Groups: Bizarro...

How to change the QEMU display resolution using OVMF

Image
When you followed my tutorial on how to install GhostBSD on QEMU you probably noticed that the resolution of the emulator window is very low when you have a modern monitor with a high resolution. In my case the default resolution in QEMU is 1280x800, it's probably the same for you. This is how you can increase the resolution in QEMU using the OVMF: Directly after you started the VM hammer the escape (ESC) key on your keyboard to get into the OVMF BIOS menu. Then go to "Device Manager->OVMF Platform Configuration" and change the value "Change Preferred Resolution for Next Boot" to a higher resolution, e.g. 1920x1080. Then select "Commit Changes and Exit", press the ESC key to get to the main menu and select "Reset" to reboot. After the GhostBSD MATE desktop environment loaded you most likely will be faced face this warning message in your top right corner: This can be fixed by opening the Caja file manager, editing the path with the penci...

Why does it say "User &" on the login screen?

Image
You may have come across this, the title over the password field on the GhostBSD login screen says "User &". At first I thought this was a bug in GhostBSD but it seems to be some behaviour in the upstream display manager LightDM which is the default in the MATE desktop environment. This is caused by an empty "Real name" field if you set up GhostBSD, see RoboNuggie's video at 12:15 . I don't know if GhostBSD specifically sets this comment field to "User &" when you leave it empty, I couldn't find that bit in the actual set_admin_user function in the GBI (GhostBSD Installer) source which in succession uses the pw useradd command. There is a thread by a FreeBSD user so I suspect it is actually caused by FreeBSD. I could reproduce it by the simple command sudo pw useradd testuser3 , the previous commands sudo pw useradd testuser1 -c "" and sudo pw useradd testuser2 -c " " did not create this effect, so it's onl...