FreeBSD GNOME 3 Fast Track

This article is dedicated to Abraham Joseph who recently asked me if I could make an article on how to configure GNOME 3 on FreeBSD 12.2. At the moment 12.2-RC3 version is available so that is what I used but it will be the same on FreeBSD 12.2-RELEASE (or 12-STABLE). All commands here are executed as root user.

Here is the Table of Contents for this article.

  • Install
  • Connection to Internet
    • LAN with DHCP
    • LAN with Static IP Address
    • WIFI
    • DNS
  • Packages
  • Settings
  • GNOME 3
  • Rest of the Setup
Install


First you will have to install FreeBSD. You may use FreeBSD Handbook or one of my guides – Install FreeBSD 12 – available here.

Connection to Internet


Then after booting to new system you need to get connectivity to the Internet. If its LAN connection then its pretty fast. Its for em0 interface.

LAN with DHCP


# ifconfig em0 up
# dhclient em0


… assuming that you are on the LAN network with DHCP enabled.

To make it permanent put below line to the /etc/rc.conf file.

ifconfig_em0="DHCP"

LAN with Static IP Address


If not then execute these for static IPv4 connection on your em0 interface.

First add these two lines to the /etc/rc.conf file.

ifconfig_em0="inet 10.0.10.80/24 up"
defaultrouter="10.0.10.1"


This is how you /etc/rc.conf file should look like now assuming that you want 10.0.10.80/24 IP address and 10.0.10.1 gateway.

# grep -A 1 ifconfig /etc/rc.conf
ifconfig_em0="inet 10.0.10.80/24 up"
defaultrouter="10.0.10.1"


Then restart the netif and routing services.

# /etc/rc.d/netif restart
# /etc/rc.d/routing restart

WIFI


If you want to use WiFi to connect to the Internet then its slightly more typing. On my system I have iwn0 wireless card so that is what I will use here. The SSID is the name of your WiFi network and PSK is password for that network.

# sysctl -n net.wlan.devices
iwn0
# ifconfig wlan0 create wlandev iwn0
# wpa_passphrase SSID PSK >> /etc/wpa_supplicant.conf
# wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf
// wait for CONNECTED state and hit [CTRL]-[Z]
# bg
# dhclient wlan0


To make it permanent across reboots add these to /etc/rc.conf file. I assume that information about your network is already in the /etc/wpa_supplicant.conf file generated by the wpa_passphrase(8) command above.

wlans_iwn0=wlan0
ifconfig_wlan0="WPA SYNCDHCP"

DNS


Last but not least you also need DNS. Put your favorite here or just paste the one below.

# echo nameserver 1.1.1.1 > /etc/resolv.conf

Packages


We will now switch to the latest branch or pkg(8) repository and install needed gnome3 and xorg packages.

# sed -i '' s/quarterly/latest/g /etc/pkg/FreeBSD.conf

# grep /latest /etc/pkg/FreeBSD.conf
url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest",

# pkg install -y gnome3 xorg

# pkg stats | head -3
Local package database:
Installed packages: 523
Disk space occupied: 3 GiB

Settings


Now you need to add ‘yourself’ to wheel and video groups.

# pw groupmod video -m yourself

# pw groupmod wheel -m yourself


GNOME 3 can not live without the /proc filesystem.

# cat << EOF >> /etc/fstab
proc /proc procfs rw 0 0
EOF


Enable needed services.

# sysrc dbus_enable=YES

# sysrc hald_enable=YES

# sysrc gdm_enable=YES

# sysrc gnome_enable=YES


Enable EVDEV support.

# cat << EOF >> /etc/sysctl.conf
kern.evdev.rcpt_mask=6
EOF


Make the boot process faster and more clean.

# cat << EOF >> /boot/loader.conf
autoboot_delay=2
boot_mute=YES
EOF


Done. Now you can reboot into your new GNOME 3 system on FreeBSD.

# reboot

GNOME 3


Your GNOME 3 desktop is now ready and you can login. For the purpose of this article I used asd user.

gnome-0-gdm


gnome-1-gdm


gnome-2-desktop


gnome-3-menu


gnome-4-apps


The default font sizes on GNOME 3 are way too big for me so I tweaked them to 0.8 scale as shown on last screenshot. I also set the font in Terminal app to Monospaced.

Fix the Icons

As you probably saw on the screenshots above the buttons on the windows are broken. There is very simple fix for that. Like shown below on the screenshots first open the Tweak Tool. Then go to Appearance page. The 3rd item from top on the right panel (under the Themes sign) is Icons – please set it to Gnome.

gnome-5-tweak


gnome-6-appearance


gnome-7-icons


gnome-8-fixed


Viola! Now all icons look properly now.

Rest of the Setup


Now there are some things that will need be addressed.

Like with the drawing below, you have just drawn the circles
🙂


owl


Just kidding
🙂


Add your favorite applications with pkg(8) like LibreOffice or Firefox for example.

If you run GNOME 3 on a laptop, then I would suggest adding net-mgmt/networkmgr package to get Networkmgr networking manager from GhostBSD.

I would also suggest using some of the FreeBSD Desktop series articles for the completeness of your GNOME 3 setup. If you need to tweak X11 then check X11 Window System part. I would also suggest visiting Configuration – Fonts & Frameworks for fonts fine tuning. If you want to have automatic mounting of removable media (and you probably do) then check Configuration – Automount Media part. If its laptop then tuning the power management will give you extra battery time. Check the details at The Power to Serve – FreeBSD Power Management part. As you are using GNOME 3 you may want to check Dash to Dock plugin or use Plank described in the Configuration – Plank – Skippy-XD part. If you did not liked the net-mgmt/networkmgr package (Networkmgr from GhostBSD) you may want to try my network.sh solution – FreeBSD Network Management with network.sh – described here.

Not sure what else I can add here as I do not use GNOME 3 daily.

EOF

Continue reading...
 
Back
Top