No users in GDM list on FreeBSD? Here’s a fix

14 May 2010

So today GNOME finally finished compiling on this Compaq Evo N610c laptop which I installed FreeBSD 8.0 on the other day. It only took about 3 days to compile. (Only! Mind you, it pulled in all sorts of stuff, like Epiphany, which includes WebKit.)

After making sure GDM would come up on startup by adding this to /etc/rc.conf


(For some reason, lshal wouldn’t run if gnome_enable="YES" was the only line.)

…I was dismayed to discover that there were no users showing up in the GDM login form. Not even the “Other” option was available to let me log in manually.

Frustrated, I went to search Google. I started typing “freebsd gdm” and then Google Suggest popped up:

FreeBSD GDM no users

Looks like I’m not the only one Googling for that. Turns out I couldn’t find anything on Google — nobody seems to have been bothered to write anything up in an FAQ (which is why I’m writing this post).

On the offchance, I looked in /var/log/messages, and saw some messages quite like the following:

console-kit-daemon[60290]: WARNING: kvm_getenvv failed: cannot open /proc/60378/mem

Turns out FreeBSD doesn’t mount /proc by default, but it is required for GDM to work properly (and, I’d hazard a guess, and a whole lot of other stuff). You can easily enable procfs by adding this line to /etc/fstab:

proc /proc procfs rw 0 0

Then, reboot (or if you’re a clever clogs and mounted /proc by hand with mount, restart GDM /usr/local/etc/rc.d/gdm restart), and you should see the users in the login form!