FreeBSD Gnome Installation howto

GNOME is a complete desktop environment (no matter what Linus says 😉 ). In GNOME, everything is easy to use, and works the way you want.

So how do you install Gnome Desktop system under FreeBSD?

These days it is quite easy to install Gnome Desktop system under FreeBSD. You have following choices (use only one of the method).

Option # 1: Fetch and install Gnome binary package from Internet

To install GNOME 2.16 from binary package over Internet or local FTP server type the command:
# pkg_add -v -r gnome2

Now proceed to post installation instructions.

Option # 2: Install Gnome binary package from CD/DVD

Login as root and type sysinstall:
# sysinstall

Select Configure > Packages > CD/DVD > Gnome

Select all packages and hit install button

Now proceed to post installation instructions.

Option # 3: Install Gnome using FreeBSD ports system

To compile and build Gnome type the following command:
# cd /usr/ports/x11/gnome2
# make clean; make install clean

Now proceed to post installation instructions.

Enable and start GNOME automatically

You need to start all of the GNOME-related services when system comes (at boot time). All you need to do is add following line to /etc/rc.conf file:
Open /etc/rc.conf file:
# vi /etc/rc.conf
Append following line:
Save close the file.

If you have other system such as KDE and just want gnome as default add the following line to ~/.xsession or ~/.xinitrc file so that GNOME 2.16 can be started as soon as you type startx command:
echo 'exec gnome-session' >> ~/.xsession

How do I use Gnome?

You can login using GDM or simply type the command:
$ startx

Further recommended readings

🐧 Please support my work on Patreon or with a donation.
🐧 Get the latest tutorials on Linux, Open Source & DevOps via:
CategoryList of Unix and Linux commands
File Managementcat
FirewallAlpine Awall CentOS 8 OpenSUSE RHEL 8 Ubuntu 16.04 Ubuntu 18.04 Ubuntu 20.04
Network Utilitiesdig host ip nmap
OpenVPNCentOS 7 CentOS 8 Debian 10 Debian 8/9 Ubuntu 18.04 Ubuntu 20.04
Package Managerapk apt
Processes Managementbg chroot cron disown fg jobs killall kill pidof pstree pwdx time
Searchinggrep whereis which
User Informationgroups id lastcomm last lid/libuser-lid logname members users whoami who w
WireGuard VPNAlpine CentOS 8 Debian 10 Firewall Ubuntu 20.04
17 comments… add one
  • eric Nov 18, 2012 @ 14:43


    how to configure WPAD, i have dhcp win2k8 server and DNS my proxy freebsd 9 with squid 3.2.3 i want all my client pc and wireless mobile and laptop to without proxy just using WPAD please helpp 🙁

  • Ernie Sep 18, 2012 @ 23:04

    how do I do this part?
    You need to start all of the GNOME-related services when system comes (at boot time). All you need to do is add following line to /etc/rc.conf file:
    Open /etc/rc.conf file:
    # vi /etc/rc.conf

  • huppy one Jul 16, 2012 @ 11:21

    hi my friend I ‘ve downloaded dvd boot from
    should I download the gnome desktop or not
    what should i do to install it without download if i found it please a will wait for your answer

  • R Jarvis Jul 3, 2012 @ 12:31

    I appreciate the information. Currently installing GNOME using FreeBSD 9 on a Sun 280r UltraSPARC64 6GB RAM, and the port install is taking forever…. I’m 4 hours into it so far!

    I completely agree with Sean. GNOME3/Unity is horrible!

  • Sean McCullough Oct 27, 2011 @ 9:27

    A short comment:

    Linus was talking about the abomination of GNOME3/Unity when he bashed GNOME. GNOME 2 is still a perfectly good desktop environment.

    GNOME3/Unity is yet another attempt to make Linux and BSD resemble MacOS X and WinDoze. Folks, if you want one of those slow bloated pieces of you-know-what, go out and buy one! But please leave our BSD and Linux alone!

  • Kenneth Smith Jul 10, 2009 @ 19:58

    Great stuff – very helpful

    • martcan Oct 10, 2010 @ 18:40

      dont forget to add an entry in fstab
      echo “proc /proc procfs rw 0 0” >> /etc/fstab

  • Caio Ribeiro César Jun 2, 2009 @ 11:49

    # cd /usr/ports/x11/gnome2
    # make clean; make install clean

    It takes so long u.u ‘ zzzzzzzzzzzzzz

    • Anuar Lezama May 13, 2010 @ 22:19

      Yes indeed, is the installation faster using the binary package????

      • Azendale Aug 19, 2011 @ 0:06

        Yes it is faster with the binary package. Using ports downloads the source and then compiles it. Ports takes more time and disk space.

  • Billy Jun 1, 2009 @ 1:55

    I’ve been using gdm_enable=”YES” in my /etc/rc.conf file. I’m gonna try that gnome_enable=”YES” in a sec. To answer James’s question, if you’re using Vi as your editor, hit ZZ or Shift Z 2 times. If you’re using emacs I dunno. Vi is forever.

  • dns Apr 6, 2009 @ 10:12

    ctrl+x for pico and nano
    ctrl+[escape] for vi :>) all the best

  • James Mar 8, 2009 @ 16:46

    how do I exit out of the config file plz help me someone
    yes i know im a noob with free bsd but plz help

  • sig Feb 8, 2009 @ 7:12

    This is helpful truly.


  • victor Jan 5, 2009 @ 1:07

    If u cant start gnome with “$ startx” you try “$ gdm” i used it when i couldnt start gnome with startx and it worked like magic.
    all the best

  • stan Dec 27, 2008 @ 16:43

    i did everything according to the steps above, but when i log in as root and i typ ‘startx’ it says: command not found
    and when i type ‘gdm’:
    gdm-binary[1358]: WARNING: GDM already running. Aborting! GDM already running. Aborting!
    what to do?

  • sejavu Apr 11, 2008 @ 21:54

    i did install gnome .
    kde n gnome want to open together . how can i find select window?

Leave a Reply

Your email address will not be published. Required fields are marked *

Use HTML <pre>...</pre> for code samples. Problem posting comment? Email me @