Making a freebsd workstation

I'm coming from archlinux. I have a couple of questions that i would like to resolve before i do the actual installation. This is not my first install on hardware and i currently have a freebsd vm that i made just to check out the installation process. I will use zfs. My first question is regarding xinit and my window manager of choice- dwm. After the install i will log in as root and setup doas for my normal user. After that i will install xorg, some other stuff and i will git clone dwm, dmenu and st from suckless.org. Then i will run desktop-installer and i will setup the firewall and other stuff but i wont choose a de or a display manager. After that, do I just copy the .xinitrc file into my home dir and replace the last few lines to launch dwm, my compositor and my polkit or is there something else that I need to do? Are there any services that i need to enable? I couldnt get it to work on my openbsd vm. If i add my normal user to wheel, should i also add it to operator, since i only plan on having one user other than root?
My machine has hybrid graphics but i will only be using my nvidia card... Can i install the drivers with pkg or do i need to go to the nvidia website?
I'm a student and I'm learning dotnet development with C#, which was not a problem on linux. Now I was thinking that i could make a linux jail and have dotnet there? I'm new to jails... Could I make an archlinux jail and if i could would it slow down my machine? What kind of resources does a jail have at its disposal in terms of cpu threads, graphics, ram etc.?
For other development i normally use nvim and vscode, so I'll do that on freebsd.
I dont do much gaming but somebody on reddit told me that they got the witcher 3 to work on freebsd with proton. Is that the case?
 
Hybrid graphics might be difficult, depending on your hardware (which you didn't tell).
My impression is that the postinstallers around that I have looked at don't handle such configurations, which potentially might result in the need for you to do that manually.

What I like about jails, is that they are an effective form of virtualization that avoids a lot of redundancy (OS overheads in runtime and memory etc). (Of course, this doesn't go too well with CPU and RAM manufacturers, who prefer bloaty solutions)
But for running another OS you'll need a virtual machine.
 
  • dwm ― It’s in the ports collection and available as package. No need to fetch it via git and build it yourself.
  • xinitrc ― Yes, it should work as you described.
  • operator ― The operator group enables you to use the shutdown(8) and poweroff(8) commands. It also has permissions to access certain devices in /dev; this is meant to enable operators to create backups (e.g. run dump(8) on a partition) and things like that. So you don’t have to use sudo, super, doas or similar tools for that.
  • Nvidia ― You can install the driver with pkg.
  • jails ― These are not VMs, they are more light-weight. You can think of them as some sort of chroot(1) with additional restrictions. Jails will use the same memory and processor resources as the rest of the system (although you can assign dedicated cores or CPU threads to a jail if you want). You should be able to create a jail that contains a Linux base system like archlinux. It will not slow down the machine. The FreeBSD Handbook has an extensive chapter on jails; that’s probably a good introduction if you’re new to jails.
 
I dont do much gaming but somebody on reddit told me that they got the witcher 3 to work on freebsd with proton. Is that the case?
Somebody even managed to run steam on FreeBSD via linux compatibility layer, but if you plan on playing games, IMHO a much better solution is to do a dualboot with windows, which is much more elegant/simple than trying to force gaming on FreeBSD.
 
Oh, for fuck's sake, everybody and their dog already knows about Windows and dual boot. You don't even realize how little additional infrastructure gaming actually requires in comparison with, say, browser usage. Gamepad drivers is only thing I can think of, actually.
 
Oh, for fuck's sake, everybody and their dog already knows about Windows and dual boot. You don't even realize how little additional infrastructure gaming actually requires in comparison with, say, browser usage. Gamepad drivers is only thing I can think of, actually.
I dont really like windows and also this post wasnt really about gaming, that was kind of a side question as i do not intend to use this system for gaming(i wrote that dont really game much)
 
  • dwm ― It’s in the ports collection and available as package. No need to fetch it via git and build it yourself.
  • xinitrc ― Yes, it should work as you described.
  • operator ― The operator group enables you to use the shutdown(8) and poweroff(8) commands. It also has permissions to access certain devices in /dev; this is meant to enable operators to create backups (e.g. run dump(8) on a partition) and things like that. So you don’t have to use sudo, super, doas or similar tools for that.
  • Nvidia ― You can install the driver with pkg.
  • jails ― These are not VMs, they are more light-weight. You can think of them as some sort of chroot(1) with additional restrictions. Jails will use the same memory and processor resources as the rest of the system (although you can assign dedicated cores or CPU threads to a jail if you want). You should be able to create a jail that contains a Linux base system like archlinux. It will not slow down the machine. The FreeBSD Handbook has an extensive chapter on jails; that’s probably a good introduction if you’re new to jails.
Thanks for explaining. I’ll read the handbook
 
I
Somebody even managed to run steam on FreeBSD via linux compatibility layer, but if you plan on playing games, IMHO a much better solution is to do a dualboot with windows, which is much more elegant/simple than trying to force gaming on FreeBSD.
I dont really plan on playing games. I wrote that i dont play much... I regret asking that now since people got fixated on this question that i asked out of curiosity more than anything else. The post was meant as to how to set up a workstation(title) since i’m new to freebsd. I have had dual booted systems in the past and i’m not a big fan of them, however i agree with your statement that it would be more elegant to dual boot for gaming. My question of gaming was more about the general possibility, since as you already know i’m new to this os.
 
Just my 2¢: since you come from ArchL*x (implying some familiarity to set things up from scratch) & seem to prefer to build some SW on your own, IMHO you're a perfect candidate to use 1(2|3)-STABLE on your workstation (you may want to use quarterly ports(7), though). Usually stable runs fine, you'll learn how to use the BeaSD's excellent build infrastructure, and you can help with testing & find bugs early. The plan you outlined in your 1st post looks fine to me. ports-mgmt/psearch or ports-mgmt/portfind will help you to find what you want.
 
Yeah there are packages but i will git clone regardless
May I ask you for the reason?

In general, it is preferable to build software from the ports collection or install a pre-built package with pkg. The reason is that others have already put some effort into porting this software to FreeBSD, testing it within the FreeBSD ecosystem, and making sure that it works fine with FreeBSD and other software from the ports collection. FreeBSD ports often (almost always) contain patches that adapt the software to certain pecularities of FreeBSD, or even to take advantage of features that don’t exist on other systems. You won’t get all of this when you try to build the software yourself, and in some cases it won’t build at all, or exhibit certain bugs or malfunctions.

Therefore, I strongly recommend to use a ready-made package (or build the software from the ports collection, if you prefer). It will probably save time and trouble.
 
I would like to add one huge advantage of ports or packages versus building software from its git source.
FreeBSD uses pkg audit(8) to keep track of all the software you have installed.

This is especially important when checking for software vulnerabilities.
When you install software from git or pip you now have software installed that is unregistered with the system.
What happens if you forget about this unregistered software and a vulnerability hits it? You are left flapping in the wind.
Using the official software channel helps your security posture.
 
I'm coming from archlinux. I have a couple of questions that i would like to resolve before i do the actual installation. This is not my first install on hardware and i currently have a freebsd vm that i made just to check out the installation process. I will use zfs. My first question is regarding xinit and my window manager of choice- dwm. After the install i will log in as root and setup doas for my normal user. After that i will install xorg, some other stuff and i will git clone dwm, dmenu and st from suckless.org. Then i will run desktop-installer and i will setup the firewall and other stuff but i wont choose a de or a display manager. After that, do I just copy the .xinitrc file into my home dir and replace the last few lines to launch dwm, my compositor and my polkit or is there something else that I need to do? Are there any services that i need to enable? I couldnt get it to work on my openbsd vm. If i add my normal user to wheel, should i also add it to operator, since i only plan on having one user other than root?
My machine has hybrid graphics but i will only be using my nvidia card... Can i install the drivers with pkg or do i need to go to the nvidia website?
I'm a student and I'm learning dotnet development with C#, which was not a problem on linux. Now I was thinking that i could make a linux jail and have dotnet there? I'm new to jails... Could I make an archlinux jail and if i could would it slow down my machine? What kind of resources does a jail have at its disposal in terms of cpu threads, graphics, ram etc.?
For other development i normally use nvim and vscode, so I'll do that on freebsd.
I dont do much gaming but somebody on reddit told me that they got the witcher 3 to work on freebsd with proton. Is that the case?
Out of curiosity, do you plan to just learn programming, or to run some scientific computing software on the FreeBSD workstation?
 
The dwm port is one of the few packages for which I use the port. Install the ports tree.
portsnap fetch extract
Take any patches you may want--for example, I use the move-resize patch (these days, I think it's available as a diff) and put the patch file in /usr/ports/x11-wm/dwm.

Customize your config.h as you want it. Then cd into /usr/ports/x11-wm/dwm and run
make DWM_CONF='~myusername/config.h' install clean.

Otherwise, I think you will have issues building it on FreeBSD as there are Linux-specific things in the code (though I could be wrong about that. I've not done it from source on FreeBSD in so long, I've forgotten since it's so easy to customize from ports.) The ports will also open dialogs asking if youi want st and dmenu installed. You can choose not to install them. Also, you can install st the same way, with an ST_CONFIG=config.h inserted into the make file.

If you like playing around with fixing C code, then of course you can build it yourself, but if you want to get it up and running quickly, I'd use the port. There is, as you'll see all over the forum, some danger in mixing ports and packages, but I install everything from packages save dwm, which I install from ports and it's fine.

I have a dated page on it--glancing over the page, I have to update the installing on FreeBSD part. The page is somewhat dated, but possibly worth it a Debian forums post where they go through config.h, explaining all of it.

Now that I see how dated that page is, I will almost certainly update installing on FreeBSD soon, maybe even today.
EDIT. Yeah, I updated the installing of FreeBSD part.
 
I'm coming from archlinux. I have a couple of questions that i would like to resolve before i do the actual installation. This is not my first install on hardware and i currently have a freebsd vm that i made just to check out the installation process. I will use zfs. My first question is regarding xinit and my window manager of choice- dwm. After the install i will log in as root and setup doas for my normal user. After that i will install xorg, some other stuff
Why don't you use something more advanced. In fact you can install different WM-s at the same time and use them by choice and mood. I have installed MATE, XFCE and KDE Plasma to the same machine and using x11/sddm as a login manager. SDDM allows you to choose the WM before login from menu. As a backup, I have also x11/slim installed and ready to run if something happens with SDDM (it has happened once when upgrading).
My machine has hybrid graphics but i will only be using my nvidia card... Can i install the drivers with pkg or do i need to go to the nvidia website?

The best way to do it is to install graphics/drm-fbsd12.0-kmod. If cards are not conflicting, it should recognize both video adapters. I have tried this once. Conflicting means of the same type. So, if your on-board graphics is Intel or AMD, it may work with Nvidia at the same time because DRM loads different GPU modules.
 
The best way to do it is to install graphics/drm-fbsd12.0-kmod. If cards are not conflicting, it should recognize both video adapters. I have tried this once. Conflicting means of the same type. So, if your on-board graphics is Intel or AMD, it may work with Nvidia at the same time because DRM loads different GPU modules.
Actually that’s not necessary when you just want to use the Nvidia GPU and ignore other GPUs present in the system. Simply install the Nvidia driver only. If there are multiple Nvidia GPUs, the Nvidia driver picks all of them up automatically, and you will be able to configure them with the nvidia-settings utility.
 
Actually that’s not necessary when you just want to use the Nvidia GPU and ignore other GPUs present in the system. Simply install the Nvidia driver only. If there are multiple Nvidia GPUs, the Nvidia driver picks all of them up automatically, and you will be able to configure them with the nvidia-settings utility.
Oh! I already forgot that Nvidia is a black sheep!
 
Back
Top