Ubuntu Update Breaks NVidia Composite Display

Yesterday evening I’ve encountered an annoying problem. My composite display was broken. My compiz was not working properly. I couldn’t play any games that using 3D texture. I remember that the night before I installed regular updates from Ubuntu. As Homer says, DOUB! That must be the cause. Sometimes I don’t understand why this kind of problem must be happening. When I run “compiz-check”, it returned:

Gathering information about your system…
.
Distribution:          Ubuntu 10.04
Desktop environment:   GNOME
Graphics chip:         nVidia Corporation Device 0a2b (rev a2)
Driver in use:         nvidia
Rendering method:      Nvidia
.
Checking if it’s possible to run Compiz on your system…
.
Checking for texture_from_pixmap…               [ FAIL ]
Checking for non power of two support…          [ FAIL ]
Checking for composite extension…               [ OK ]
Checking for FBConfig…                          [ OK ]
Checking for hardware/setup problems…           [ SKIP ]
.
At least one check had to be skipped:
Error: Unable to detect maximum 3D texture size

I run “nvidia-bug-report.sh” to check what the error is, and then checked the file generated by the script. The file showed that GLX initialization is failed, and recommended me to reinstall the NVidia driver.

(EE) Apr 29 21:46:19 NVIDIA(0): Failed to initialize the GLX module; please check in your X
(EE) Apr 29 21:46:19 NVIDIA(0):     log file that the GLX module has been loaded in your X
(EE) Apr 29 21:46:19 NVIDIA(0):     server, and that the module is the NVIDIA GLX module.  If
(EE) Apr 29 21:46:19 NVIDIA(0):     you continue to encounter problems, Please try
(EE) Apr 29 21:46:19 NVIDIA(0):     reinstalling the NVIDIA driver.

As recommended, I reinstalled the NVidia driver. When reinstalling the driver, the installer returned an error message:

ERROR: File ‘/usr/lib/xorg/modules/extensions/libglx.so’ is not a symbolic link.

After the message, the installer was still continuing the installation process until finish. I restarted my system, and found out that the problem had gone. Then I checked the location of the libglx.so, and it is there. So, I guess that’s the root of the problem. I think Ubuntu has to be more careful with its update, because sometimes it breaks a well-running system. Luckily, the problem is not as complicated as I thought.

Thanks to these forums:

And, special thanks to http://forlong.blogage.de/entries/pages/Compiz-Check for the “compiz-check” script. You Rockz!

Creative D200 on Linux

For anyone, who is electronic junkie, having cables run in all directions in his room or house is a common sight.  In my own experience, I really fed up with those cables. They are very annoying, messy, and difficult to clean.  Worse of all, it makes me hate my own room. GEEZZ!!

Last week I bought a dream-come-true wireless speaker at a Creative sale.  Its model is Creative D200. Its dimension is about 40 cm wide x 10 cm high x 10 cm deep, with glossy black color. It looks awesomely elegant. The sound quality is also out of this earth. I didn’t know that wireless speaker has outstanding sound quality.  The day I bought this beauty might just be one of my best days indeed!!

Creative D200: Overall View

Creative D200: Buttons

Creative D200: Bass

This speaker is using Bluetooth technology as its wireless connection. The device connection to the speaker is also very easy. Before you can use the speaker, you need to pair your device with the speaker. Press the Bluetooth button on the speaker for 3 seconds, then the light beside the Bluetooth button will turn blue and blinking. It means its in pairing mode. In Windows 7, you have to select “Add Device”, then select Creative D200. In Android phone, turn on the Bluetooth function, select “Scan Devices”, and then select the Creative D200. In Linux (Ubuntu 10.04), you select Bluetooth icon in toolbar, select “Set Up A New Device”.

Step 1: The welcome screen of Bluetooth new device setup will be shown. Click “Forward” from here.

Bluetooth New Device Setup

Step 2: The wizard will be scanning any bluetooth device available for pairing. Creative D200 will be shown in the list. Click “PIN options…”.

Bluetooth New Device Setup-D200

Step 3: Choose “0000” as the PIN. It is the option for most of the device. Click “Close”.

PIN Options-0000

Step 4: Your device will be connected successfully with the speaker. Click “Close”.

Bluetooth New Device Setup-D200 Connected

In order to connect to the speaker, you can press the Bluetooth button on the speaker once, the speaker will connect to any of ready device.Once its connected the light besides the Bluetooth button will turn blue, but not blinking.

In Linux (Ubuntu 10.04), if you have connected with the device but the sound still comes from your computer then you have to select Creative D200 in “Sound Preferences | Hardware”.

Sound Preferences-Hardware-D200

Still in Linux (Ubuntu 10.04), if the sound has come from the speaker but you are unable to increase or decrease its volume then you have to select Creative D200 in “Sound Preferences | Output”.

Sound Preferences-Output-D200

In other Linux distro, the adding of Bluetooth speaker might be different, especially non-Gnome desktop environment, but technically its the same.

So, good luck and may the force be with you.  Prevail in the end, you will.

Microphone Problem on Ubuntu 10.04

Recently I bought a PC headset with noise-cancellation mic. Smiling all the way to my work desk, I plugged the headset into my Sony Vaio notebook that running Ubuntu 10.04, but to my surprise the mic didn’t work (blasted!), even though it’s earphone is working fine. I tested the headset on my Windows 7 system, and it’s working fine.

After a little bit of experiment I solved the problem. The solution is quite easy.

Open “Sound Preferences” -> “Hardware” -> Change Profile to “Analog Stereo Input” -> Test -> Change Profile to “Analog Stereo Duplex” -> Test again.

Sound Recorder Profile

Sound Recorder Profile

Up to this step the device should be able to work.

I guess the cause of the problem is because of missing settings in one of the configuration files.  (Okay, I admit! Windows is not the only OS to have missing files out of nowhere).  By doing above steps, the system refreshed its settings. YAY!

Play Heroes of Might and Magic V on Linux

Heroes of Might and Magic is one of my favorite game in old times (I’m still young though). This game is a strategy game and it’s very addictive, I mean, REALLY ADDICTIVE.  Countless nights I spent in battlefield, thanks to this game.  We have to pick one of the race, build an army, and capture enemy castles. We can spend most of our time just to play this game. One of the best strategy game I have ever played indeed!  Heroes of Might and Magic V is latest installment of the game series.

The question is last time I play in DOS and Windows 98 environments, and Heroes V is also a Windows game. How to run this game on linux, especially Ubuntu? To do it I bet my luck on Wine.  Wine is not just good to play game but also to drink.  🙂

I use Wine 1.2.2 to install Heroes Might and Magic V on my Ubuntu 10.04. The installation run smoothly. I run the game. My screen resolution changed according to the game resolution. An introduction showed a story how the war starts. After the introduction, the game leads me to a main menu screen. The problem happened when I tried to click a menu. The screen shifted little bit to the right. The more I click to the screen the more the screen shifted to the right. In short I could not play the game.
After a little bit of research I would be able to run the game if I emulate a virtual window for all application run under Wine. It has to be set on Wine Configuration (winecfg).

Wine Configuration

Wine Configuration

After setting the virtual window I’m able to play the game perfectly, feels like I’m playing in Windows environtment… 🙂  See here, Bill. Your platform is not the only one anymore!!

Heroes of Might and Magic V on Wine

Heroes of Might and Magic V on Wine

Internet Connection Problem in VMWare and VirtualBox

I was trying to compare VMWare and VirtualBox. I ran Ubuntu 10.04 Server Edition on both virtualization program, and both had the same problem with the Internet connection. When I tried to run “sudo ifup eth0”, system showed something like “eth0: ERROR while getting interface flags: no such device”.

Once again I found the solution in the ubuntuforums.org. It suggestes me to delete these lines below from “/etc/udev/rules.d/70-persistent-net.rules”

PCI device xxxxxxxxxxx (module)
SUBSYSTEM==”net”, DRIVERS==”?*”, ATTRS{address}==”xxxxxxx”, NAME=”eth0″

But, I deleted the file instead, I restarted the system, and then the Internet connection was fixed. This solution is applied to both virtualization program.

Reference:
http://ubuntuforums.org/showthread.php?t=255018

Install VMWare Player on Ubuntu 10.04

I need VMWare Player in my new installed Ubuntu 10.04 64-bit system. Unlike when I installed VMWare Player on Linux Mint 8, I faced problem with Ubuntu 10.04.

I downloaded VMWare Player 2.5 64-bit version installation file and ran it through terminal. The installation looks fine but when the installer were trying to do configuration, the installer stuck there and never finished. From a thread in ubuntuforums.org I found out that the cause was the setup unable to create vmnet virtual devices. So, I followed the suggestion in the website.

I open two terminals, in the first terminal I ran:

while true; do sudo killall -9 vmware-modconfig-console; sleep 1; done

The purpose of the above command is to kill “vmware-modconfig-console” from the memory. In the second terminal I ran the VMWare Player installation file. When the installation file was trying to configure, it ran “vmware-modconfig-console” which was the cause of the system hang, but the command in the first terminal kill the process immediately, so the installation process finished. The installation only installed the VMWare Player program, but it’s configuration, including “vmnet” is still unconfigured. In order to do that I needed to amend several files.

I exctracted vmnet.tar and vmci.tar from “/usr/lib/vmware/modules/source” folder into “/tmp” folder

    tar xvf /usr/lib/vmware/modules/source/vmnet.tar -C /tmp
    tar xvf /usr/lib/vmware/modules/source/vmci.tar -C /tmp

    I changed the working directory to “/tmp” folder

      cd /tmp

      I added #include “compat_sched.h” to “vmnet-only/vnetUserListener.c” and “vmci-only/include/pgtbl.h” files.

        perl -pi -e ‘s,(“vnetInt.h”),\1\n#include “compat_sched.h”,’ vmnet-only/vnetUserListener.c
        perl -pi -e ‘s,(“compat_page.h”),\1\n#include “compat_sched.h”,’ vmci-only/include/pgtbl.h

        I archieved those folder again and put it in the original location

          tar cvf /usr/lib/vmware/modules/source/vmnet.tar vmnet-only
          tar cvf /usr/lib/vmware/modules/source/vmci.tar vmci-only

          I ran the command below to start configuration.

          vmware-modconfig –console –install-all

          I ran the VMWare Player, and everything looked fine. I ran the guest OS, a Windows XP, and I faced another problem. The mouse was not working properly, the VMWare Player status bar were flickering showed “To grab input, press Ctrl-G” and then “To release input, press Ctrl-Alt”, continuously. I found out a solution for this problem from this website. Inserted the line below into “/etc/vmware/bootstrap” file.

          export VMWARE_USE_SHIPPED_GTK=yes

          I tried again the VMWare Player, and it works fine… At last.

          Ubuntu Kernel Update Breaks NVidia Driver

          A day after the successful installation of Ubuntu 10.04, I ran recommended update of the operating system. One of the update was for its kernel. Because of the Nvidia driver was installed into the system’s kernel, so I thought I had to prepare for the worst.

          After the update finished and I restarted the system, my worry became reality, the NVidia driver was missing, so even though I still able to go into Gnome, the screen resolution backed to the standard resolution. When I used Linux Mint, this problem was never happened, maybe it was because last time I used NVidia driver that came with the distro through Envy application. But, for current driver I downloaded manually from the NVidia website.

          According to a thread in ubuntuforums.org (I forgot the address) I just need to reinstall the NVidia driver. So, I did it, and it works.

          Thanks, God. Luckily, it’s easy…

          A Lynx Conquered My Notebook

          Since the first time I know Linux 10 years ago I have tried several Linux distro. The first Linux distro that I used was Mandrake (the former of Mandriva), and then followed by openSuse, SimplyMepis, Ubuntu, PCLinuxOS, and the last was Linux Mint, up to last week. From those distros only PCLinuxOS 2007, Linux Mint 4, 6, and 8 that I used daily on my notebook. I am happy with the performance of both distros, especially Linux Mint. It’s very user friendly.

          But, last week I decided to install a new distro version. I tried the live cd of Linux Mint, Ubuntu, and Kubuntu. Live distro that I tried for first time was Ubuntu 10.04, and I already faced have a problem. The live distro could not boot properly, it showed a blank screen. Then, I tried with Kubuntu and Linux Mint, all of them had the same problem. An obvious result because all of the distros are based on Ubuntu. After google-ing for several hours, I found out from a forum that the cause was “nouveau”, an open-source driver for NVidia. According to the website I need to disable the driver by adding an option command into the grub command.

          nouveau.modeset=0

          So, the grub command became:

          /boot/vmlinuz-2.6.32-21-generic root=UUID=2b69f855-de8b-461b-8f8b-02e3bf7d1142 ro nouveau.modeset=0  quiet splash

          By using this command, I was able to boot into the live distro, not only Ubuntu, but also Kubuntu and Linux Mint.

          Linux Mint 9 Isadora looked similar to its previous version, but I was impressed with the Ubuntu and Kubuntu. I read some reviews for Ubuntu and Kubuntu, looked like Ubuntu received a lot of praises, but Kubuntu received some negative critics. So, it was decided to install Ubuntu 10.04 64-bit Lucid Lynx into my Sony Vaio VPCCW26FG.

          The Ubuntu installation was very smooth, I didn’t get any trouble when installing it. After installation I rebooted to my new OS by disabling the “nouveau” driver in the grub command. And, then I amended the “/etc/default/grub” to disable “nouveau” driver, so I don’t need to amend the grub command every time I boot. In the file I put:

          # Disable Nouveau driver
          GRUB_CMDLINE_LINUX=”nouveau.modeset=0″

          And then I ran the command below from terminal:

          sudo update-grub

          I restarted the OS and I could access Lucid Lynx successfully without needed to amend the grub command.

          Unlike my previous Linux Mint, Lucid Lynx is able to detect my wireless, so I just need to connect to my wireless modem and typed the password. For addition, I needed to change the wireless setting in my Network Manager to connect automatically every time I log in.

          Everything works fine in my new OS, except my NVidia GeForce GT 330m. In order to settle this, I followed instruction from the forum. I downloaded NVidia driver from NVidia website, and then I ran the command below to go to command line and disable the Gnome.

          sudo service gdm stop

          And, then install the downloaded NVidia driver. After the installation I added 2 lines into “Device” section in “/etc/xorg.conf”:

          Option         “ConnectedMonitor” “DFP-0”
          Option         “CustomEDID” “DFP-0: /proc/acpi/video/NGFX/LCD/EDID”

          After this step I rebooted the OS and, foila, my screen resolution became “1600×900”.

          Mission completed ! 😀
          Now time for restoring my favorite applications.

          Special thanks to “TheRawGod” from “ubuntuforum.org”.

          Unable to Retrieve Movie Info with GCStar

          I have a list of movie information that I stored using GCStar. Every time I added a new movie, the application was able to retrieve the correct information, such as director, actors, year, and synopsis,  of the particular movie.   This application worked quite well for me… until recently. GCStar 1.4.3 has problem in retrieving the information.

          Luckily GCStar has it’s own forum, and some other users also encountered the same problem. I found the solution in this forum thread. I needed to download GCGraphicComponents.pm and put it into /usr/share/gcstar/lib folder. The last thing I needed to do was to update the GCStar plugins by running this command:

          sudo gcstar -u

          Then… the problem solved ! I can retrieve any movie information again. Thanks, Tian. It’s a great piece of software.

          Linux Mint 8 on Vaio VPCCW26FG

          Once upon a time I got a brand new Sony Vaio VPCCW26FG, due to hardware problem with my previous notebook. It’s quite elegant, maybe because it has a white color. It came with Windows 7. I tried Windows 7 for a few weeks. I can say Windows 7 is far much better than Windows Vista. It’s boot speed is amazing, less than a minute I can start an application already. It’s display also a mouth drooling appearance. It’s task bar only shows the running application’s icon, where we can see the mini application version by hovering the mouse over it. But, there are two things that obviously I don’t like from Windows 7. Firstly, the main menu system (the menu that shown after click the Start Menu) is too pack. When I select to an application folder, it only shows the content of the folder. I still like the Windows XP menu system. Secondly, most of the applications that come with this notebook are trial version only. I can’t complain, actually, it’s just typical Windows environment. Every notebook that bundle with it always come with trial version applications. Just can’t complain…

          Anyway, whatever how good a Windows Operating System is, I still wanted to use Linux on my Vaio. I still chose Linux Mint over other Linux distro, because I had faith with this distro. I installed the distro while I kept the Windows 7 on my system, so it was a dual-boot system. The installation went very smoothly and fast. Then, I started encounter problems, when I was configuring the system. There are two major problems that I encountered:

          1. The wireless was not working either.
          2. NVidia driver was not working properly, the screen just shown a blank screen after I installed the NVidia driver and restarted the system.

          Fixing Wireless Hardware

          Vaio VPCCW26FG is using Intel network device 422c. I found out from Ubuntu forum that this problem could be fix by installing backported kernel. I followed the instruction and it fixed the problem. My Linux Mint was able to detect the wireless hardware. The kernel version that I used is 2.6.31-19-generic. Read this thread to get more information.

          I think this problem was rather easy to fix.

          Installing NVidia Driver

          Fixing this problem was more difficult than the wireless problem. I spent a few days to find the solution in the Internet. Eventually I found the solution in Ubuntu forum as well. In order to fix this problem I needed to extract the display edid from running Windows in the notebook by using special program. But, somehow the programs that mentioned in the forum thread was not working properly with Windows 7. In the end I was using the edid that provided in the forum thread. The edid had to be put in /etc/X11 folder. After that, I installed the NVidia driver, and amended xorg.conf to include the edid.

          Below is my xorg.conf file content:

          Section “ServerLayout”
          Identifier     “Layout0”
          Screen      0  “Screen0” 0 0
          InputDevice    “Keyboard0” “CoreKeyboard”
          InputDevice    “Mouse0” “CorePointer”
          EndSection

          Section “Module”
          Load           “dbe”
          Load           “extmod”
          Load           “type1”
          Load           “freetype”
          Load           “glx”
          EndSection

          Section “ServerFlags”
          Option         “Xinerama” “0”
          EndSection

          Section “InputDevice”
          Identifier     “Mouse0”
          Driver         “mouse”
          Option         “Protocol” “auto”
          Option         “Device” “/dev/psaux”
          Option         “Emulate3Buttons” “no”
          Option         “ZAxisMapping” “4 5”
          EndSection

          Section “InputDevice”
          Identifier     “Keyboard0”
          Driver         “kbd”
          EndSection

          Section “Monitor”
          Identifier     “Monitor0”
          VendorName     “Unknown”
          ModelName      “Nvidia Default Flat Panel”
          HorizSync       29.0 – 47.0
          VertRefresh     0.0 – 61.0
          Option         “DPMS”
          EndSection

          Section “Device”
          Identifier     “Device0”
          Driver         “nvidia”
          VendorName     “NVIDIA Corporation”
          BoardName      “GeForce GT 330M”
          EndSection

          Section “Screen”
          Identifier     “Screen0”
          Device         “Device0”
          Monitor        “Monitor0”
          DefaultDepth    24
          Option         “TwinView” “0”
          Option         “metamodes” “nvidia-auto-select +0+0”
          Option         “ConnectedMonitor” “DFP-0,DFP-1,CRT”
          Option         “CustomEDID” “DFP-0:/etc/X11/sony_VAIO_CW_1600_900.bin”
          SubSection     “Display”
          Depth       24
          EndSubSection
          EndSection

          For more detail information and to get the edid, please read this thread.

          For anyone who encounter the same problems with me, you have to fix the wireless problem first before fix the NVidia driver. Because installing NVidia driver will modify your Linux kernel.