Setting Up An Ubuntu Testbed

Hey there everyone! I’m just now getting around to setting up a spare computer as an Ubuntu testbed for some projects I have planned. The computer in question is an old Asus P6T motherboard, 12GB of RAM, an Nvidia GTX 460, and a Samsung 50″ DLP TV. I’ve been fighting with Ubuntu 12.04.3 LTS and finally managed to get everything installed.

My first hurdle was getting Ubuntu to install! I went ahead and created a boot disk on an SD card, boot from it, and tried getting Ubuntu to detect my drive in the installer, but it failed to do so! I could see the drive in gparted and also if I ran sudo fdisk -l, but I couldn’t get the installer to detect it. After some digging, I realized that the drive I had installed in the PC used to belong to a RAID array. It turns out that the drive was marked as being part of an array, and the installer was skipping it. I issued the following and Ubuntu proceeded to install successfully!

 dmraid -E -r /dev/sdX (where X = the drive in question)

After that was solved, I ran into an overscan issue with my DLP TV. The first thing I had to do was install the Nvidia drivers by issuing the following commands:

sudo apt-get remove nvidia-currentsudo apt-get update
sudo apt-get upgrade
sudo apt-add-repository ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get install nvidia-current nvidia-settings

Once this is finished, I verified that the drivers were installed by going into System Settings>Nvidia

After going through all that trouble, I couldn’t find an overscan slider to adjust! What a rip!!

Once I did a bit more googling, I came across a post by Raymond DeCampo which explains how to modify the Nvidia driver settings to properly scale the screen.

A few weeks ago I upgraded my HTPC to Ubuntu 12.10 and was treated to a nasty surprise: the overscan settings for the nvidia driver were no longer recognized. The HTPC is connected to my television (naturally) which is a 40″ LG LCD HDTV. If you have ever tried to connect your PC to an HDTV before, you probably encountered the problem of that the visible portion of the screen is smaller than the drawable portion of the screen. The result is that the edges of the screen are not visible. In my case that meant the dash and the universal menu of Unity could not be seen. That makes for a less than usable experience.

In the past nvidia included an overscan setting slider in the GUI configuration tool (nvidia-settings). When I opened it up however, the setting was nowhere to be found. A short time on google confirmed the worst: nvidia had removed the setting.

The good news is that the setting can be twiddled via the command line. Then, once you find the magic numbers that work with your particular graphics card and monitor, you can put them in your .nvidia-settings-rc file to automatically apply them on login. Also, the command is safe: if you try something that would push the screen too far, the driver simply ignores it.

The first step is to run the command with a bunch of values until you find the values that work best:

nvidia-settings --assign 0/CurrentMetaMode="DFP-0: 1280x720 { ViewPortIn=12
80x720, ViewPortOut=1190x680+44+20 }"

The first set of numbers, the ViewPortIn and the value before that, are determined by the native resolution of your HDTV. Mine is a 720p, so the native resolution is 1280×720. The next set of numbers, the ViewPortOut, are the ones you will want to experiment with. They are telling the driver how to transform the viewport so the screen ends up in the visible area of the HDTV. The first part, the 1190×680, indicates how much to scale the viewport. The second part, +44+20, indicates how much to shift the image.

Once you have the values you want, edit your ~/.nvidia-settings-rc file adding the following at the end:

0/CurrentMetaMode=DFP-0: 1280x720 { ViewPortIn=1280x720, ViewPortOut=1190x680+44+20 }

Obviously you will want to use the correct values for your system.

Once this was all fixed, I reboot with a simple sudo reboot and was greeted with a perfect desktop!

I hope this helps out someone having to go through the same issue!

Comments

comments