RevoDrive 3 & GTX560Ti on Ubuntu

I’ve installed Ubuntu on my shiny new RevoDrive 3 with my custom kernel powered installer CD. I couldn’t make it boot, so I installed a 200mb /boot partition to my other HDD and made that the first boot drive in the BIOS. Maybe I could do this solution but I didn’t want to spend more time on this and booting the kernel from the HDD works well. I made two RAID0 partitions on the Revo, one for the swap and one for the data.

Video card

After the installation, I downloaded the latest Nvidia drivers and installed it by running the binary file. I’ve noticed that the system froze during booting with a stack trace showing modprobe as the source of the error. After googling I realized that there was a problem with a driver (possibly nouveau) taking over the card before the Nvidia driver loads.

To solve this problem I edited /etc/modprobe.d/blacklist.conf and added these lines to the bottom of the file:

1
2
3
4
5
6
7
blacklist vga16fb
blacklist nouveau
options nouveau modeset=0
blacklist rivafb
blacklist nvidiafb
blacklist rivatv
blacklist nvidia

And the ran update-initramfs -c -k all. On the next reboot X booted flawlessly without the need to boot into recovery mode.

To have OpenGL X extensions (NVIDIA_GLX), I had to install xserver-xorg-dev and then ran again the Nvidia installer. Without the package the Nvidia installer couldn’t compile the GLX module.

Multi-monitor setup

After googling for a while, I learned that if I want to use two displays, I have to enable TwinView or Xinerama in nvidia-settings. Xinerama is out of question because it disables compiz. I have 2 video cards and if I turned on TwinView for both of them, Unity panel stretched on the whole 2 monitor desktop and app windows kept opening in the middle near the edge of the two displays.

Finally I decided to stick with separate X screens. The problem with this was compiz only started on the primary screen only, so I had to write two scripts to start it on Screen1 and Screen2 (I’m not using Screen3):

1
2
3
4
5
#!/bin/bash
DISPLAY=`echo $DISPLAY | sed s/[.]0$//` | sed s/[.]1$//`.1
compiz --replace &
sleep 5
google-chrome --user-data-dir=/home/nonoo/.config/google-chrome1 &
1
2
3
4
5
#!/bin/bash
DISPLAY=`echo $DISPLAY | sed s/[.]0$//` | sed s/[.]1$//`.2
compiz --replace &
sleep 5
google-chrome --user-data-dir=/home/nonoo/.config/google-chrome2 &

As you can see, the scripts also autostart Chrome on those displays automatically. The sleep lines are needed because without them Chrome’s window titlebar will show up behind the Unity panel.

I had another problem: there was no wallpaper on the screens, just a solid white background. To fix this, I installed “Advanced Settings” in the Software Center, and switched off “Have file manager handle the desktop”.

Some tweaks

To speed things up I edited /etc/rc.local, replaced the first line to #!/bin/bash -e and added these lines before the exit 0 line (gets RevoDrive devices’ name by UUID, replace them with yours):

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# params: UUID IGNORESSDDEV
function getdevnamefromuuid {
    if [ ! -z "$2" ]; then
        echo `blkid | grep -v /dev/$2 | grep -m 1 $1 | awk '{print $1}' | sed -e
 's/\([0-9\:]\)\|\(\/dev\/\)//g'`
    else
        echo `blkid | grep -m 1 $1 | awk '{print $1}' | sed -e 's/\([0-9\:]\)\|\
(\/dev\/\)//g'
`
    fi
}

SSDDEV1=`getdevnamefromuuid 220b5b8d-2574-bdae-428f-2ca159e68ce4`
echo noop > /sys/block/$SSDDEV1/queue/scheduler
SSDDEV2=`getdevnamefromuuid be713d02-caca-d7dd-eb1c-bbb8ebbfbaea $SSDDEV1`
echo noop > /sys/block/$SSDDEV2/queue/scheduler

I added noatime,nodiratime,discard to the md0 partition in /etc/fstab (discard enables TRIM support), and added these lines to the end of the file:

1
2
tmpfs /tmp tmpfs defaults,noatime 0 0
tmpfs /var/log tmpfs defaults,noatime 0 0

These lines put /tmp and /var/log in the system RAM. Further info about tmpfs is here.

To remove unnecessary things like printer drivers I purged/installed the following packages:

1
2
sudo apt-get purge brltty foo2zjs hplip hplip-cups hplip-data hpijs min12xxw pxljr splix
sudo apt-get install localepurge

Lock freeze

When the screen got locked, Ubuntu displayed black screen even when I moved the mouse or pressed a button. I had to replace gnome-screensaver with xscreensaver. Here’s the guide for this.

[...] the script from this blog make the wallpaper show up, but I still cannot use the desktop on that screen. I can’t drag [...]

 
johnny cash 2012-05-16 18:58:02

Your multi-monitor solution was very helpful getting me started on my configuration, thanks!

 
Rishad 2012-07-11 10:10:27

When I run this:
# DISPLAY=`echo $DISPLAY | sed s/[.]0$//`.2
# compiz –replace &
compiz (core) – Fatal: Couldn’t open display :0.1.2

(I’m trying to setup dual monitor on Ubunti 12.04. Have run nvidea-settings)

Nonoo 2012-07-11 10:27:45

I’ve updated that script in the blog post to handle :0.1 and :0.2 displays.

 
 
Name (required)
E-mail (required - never shown publicly)
Webpage URL
Comment:
You may use <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> in your comment.

Click for dp.nonoo.hu »

About me

Nonoo
I'm Nonoo. This is my blog about music, sounds, filmmaking, amateur radio, computers, programming, electronics and other things I'm obsessed with. ... »

Twitter

Listening now

My favorite artists

Facebook