MonkeyBrains.net/~rudy/example Random examples

Asus v2-AH2

HOW-TO: FreeBSD + Asus V2-AH2 + SamSung SyncMaster 204bw

Short answer: FreeBSD 6.2 i386 + snd_hda + nvidia driver

Phew, I spent a better part of the Thanksgiving weekend getting my new machine up and running. Hopefully, these notes will help out other people with Asus V2-AH2 barebones systems.

  • Motherboard seems similar to the Asus: M2NPV-VM
  • Graphics chip: Nvidia C51PV
  • High Definition Audio chip: MCP51
  • Ethernet driver: nfe (or nve < FreeBSD 7.0)

    I started with 6.1-amd64-release and found all kinds of problems:

  • ethernet was not working
  • nv driver in X windows would not do the native monitor resolution 1680x1050 [man nv]
  • the nVidia X drivers don't work at all on freebsd-amd64
  • the audio would not work at all
    + +
  • ETHERNET

    Step One was putting in an old RealTek ethernet card so I could update the ethernet driver. Sure enough, 6.2-RC1 GENERIC has the nve driver in it. Phew, that was an easy fix. [man nve] I removed the RealTek card, and the Internet works. :)

    Update: In FreeBSD 7, use the nfe driver. You can also patch your 6.x drivers to use nfe (see freebsd mailing lists on FreeBSD.org for more info).... FYI, the nfe is part of the 7.x GENERIC kernel. (You do want the SMP kernel if you have a dual-core CPU).

    VIDEO

    Next was the video driver. In vain, I updated X from 6.9 to 7.2 following these directions: http://wikitest.freebsd.org/ModularXorg
    [update, 7.2 is the standard X version in the ports now - May 23, 2007]

    Still, the 'nv' driver did not work as desired --- I couldn't get it to run 1680x1050 pixels on my SyncMaster monitor. I tried downloading the nVidia drivers: http://www.nvidia.com/object/freebsd_1.0-8776.html but they only work on i386. I had to start over and reinstall i386 and forgo amd64. :( As far as I can tell, there is no way to run Mixed Mode kernel objects. You can run i386 binaries on an amd64 system, however, you can't load a i386 ko into a running amd64 kernel. This time, I downloaded the 6.2-RELEASE ISO and skipped having to upgrade the 6.1 -> 6-STABLE with cvsup.
    Update: The ports tree has a newer driver... "cd /usr/ports/x11/nvidia-driver && make install" - Sept 26, 2007

    If you cursor is not being displayed, set this in your xorg.conf file in the nvidia Section: Option "SWcursor" ... also, HWcursor seems to work as well.

    Once I got i386 installed, I found I had to jump through some hoops to get the nvidia-xconfig script to run. The nvidia site states: "If you are using FreeBSD 6.x, you will need to make sure that the 'compat5x' package is installed."
    [ add compat libraries like this: cd /usr/ports/misc/compat5x/ && make install - May 23, 2007]

    Well, I have found you need more than that! The COMPAT5X is enabled in the GENERIC kernel (and SMP kernel if you are running a dual core CPU) so that is not a problem. The problem is this, You need the 5x /lib stuff as well. You have to copy the FreeBSD 5.x libraries from somewhere to run the nvidia-xconfig script. Here is what I did:

    mkdir /usr/compat/FreeBSD55
      rsync -av host-running-5.5:/lib /usr/compat/FreeBSD55
      cd /lib
      ln -s /usr/compat/FreeBSD55/lib/libm.so.3 .
      ln -s /usr/compat/FreeBSD55/lib/libc.so.5 .
      
    If you don't have another box with 5.5, you can download the base distribution from here: ftp://ftp.freebsd.org/pub/FreeBSD/releases/i386/5.5-RELEASE/base. Download that whole folder into /tmp/base and then run this command:
    env DESTDIR=/usr/compat/FreeBSD55 /tmp/base/install.sh

    After running nvidia-xconfig, X windows launches with the proper resolution.

    nVidia doesn't seem to have much internest in porting their driver to FreeBSD amd64: nvidia doesn't support FreeBSD amd64

    AUDIO

    The last step was getting the audio to work. The snd_hda driver is needed.

    The easiest way to do this, is to download the binary snd_hda module. get "sndkld_releng6_i386_lowlatency.tar.gz" from here: http://people.freebsd.org/~ariff/lowlatency/

    You need to unpack that tarball and copy sound.ko and snd_hda.ko into /boot/kernel. Then run:
    kld_load snd_hda
    Oh, if you already have the old sound.ko loaded, unload it first (using kldunload).

    Here is more info on the snd_hda driver:

  • http://people.freebsd.org/~ariff/
  • http://lists.freebsd.org/pipermail/freebsd-multimedia/2006-September/004864.html
  • [man snd_hda]
  • In Summary

    My new box rocks! I threw an AMD Athlon X2 3800+ CPU (the sweet spot), two sticks of 512Mb Super Talent Ram, an Asus DVD player, and a slim 160GB Seagate Drive.

    More references:

  • Asus site
  • This page (and any updates)
  • Need to host a server? Check out my kickass ISP: MonkeyBrains.Net
    If you want an ASUS barebones machine built out for you and installed with FreeBSD, I'll do it for the cost of the machine plus 100 dollars. 415.974.1313 ask for Rudy.