Home page of this blog

Tuesday, November 24, 2009

Fedora 12 includes a reverse engineered nvidia driver called nouveau which did not work properly with my nvidia card (9800 GT).

I could not login properly, nor see how Fedora looked/worked. Somehow I wanted to try Fedora 12. I tried blacklisting nouveau and forcing fedora use vesa to see how it looks. It worked and,

Here is a textual summary of what I tried which I hope may help someone

When I booted from live USB, I was greeted by "Automatic boot in 10 seconds"

I pressed tab. This brought me to Boot menu. I pressed tab again and added the following

nouveau.blacklist=1

(and pressed return key after appending above to boot)

After some time, nouveau failed to load as expected as there was no param called blacklist in nouveau (we can give any xyz in place of blacklist to force the module not to load into the kernel!, see the last screenshot)

I was greeted by a blank screen. Great. I am not scared by that

I gave Ctrl + Alt + F2 and gave root as the user name. It logged in without prompting a password. I brought down failed X-Server by issuing

init 3

(init 3 brings down runlevel to 3 without graphical UI)

I confirmed if nouveau was loaded by mistake by lsmod and grep as follows

lsmod | grep nouveau

(if loaded, nouveau wont get unloaded easily, no rmmod will work on it, it is tightly bound, so is this prevention mechanism to not allow nouveau from loading)

I used Xorg to configure my Xorg Server as follows

Xorg -configure

which created a new file xorg.conf.new under current directory

and here is how I edited my file to substitue vesa in place of nouveau using sed editor

sed -i s/nouveau/vesa/g xorg.conf.new

and copied the modified file into /etc/X11/ folder using cp command

cp xorg.conf.new /etc/X11/xorg.conf

To start and test X-server I used

startx

and I was inside gnome with vesa driver running (which of course did not crash or corrupt my display like nouveau driver, alternative solution is using init 5 and logging in as liveuser, which is a hit and a miss, but startx works always)
In case X-Server flickers due to misconfiguration, it is again easy to fix, by giving Ctrl + Alt + F3 or Ctrl + Alt + F4 ... and then stopping X-Server by init 3

Fedora 12 rocks, even when running vesa driver, it is fast fast ....

Some Fedora 12 screenshots running with vesa driver (last screenshot shows dmesg output, showing how Fedora got confused while trying to load nouveau as I appended blacklist param to boot, which I used to my advantage to stop nouveau from loading, any loadable module can be stopped from loading into kernel using this technique)

Notes:

1. vesa is a minimal X driver which should work in any situation.

2. Xorg -configure is the command to configure Xorg manually in Fedora

3. lsmod lists the loaded modules and |grep nouveau lists a line if there is a match (grep stands for regular expression)

4. sed -i edits file in place and s///g searches a pattern in the first // and replaces with pattern from second //

Monday, November 16, 2009

Here are the screenshots of ubuntu 32 bit on virtualbox-ose in openSUSE 11.2 under seamless mode. You could see the fuse of gnome menus and KDE menus in second screenshot and fuse of openSUSE 11.2 and ubuntu package managers running side by side!!

Saturday, November 14, 2009

openSUSE 11.2 KDE4.3.1 is awesome, extremely fast and very beautiful. I started loving it. Neither can I miss my favorite ubuntu , nor can I miss openSUSE 11.2 KDE 4.3 after getting a feel of its speed, power and beauty. So here is what I did and I am not that good in explaining how I configure. But let me try explaining thinking the reader in second person

If you have a core 2 duo or a quad core PC you need not miss either! Why? Because core 2 duo or quad core processors are coming with hardware virtualization. By default hardware virtualization is disabled in bios. If it is disabled you can enable it in bios. Hardware virtualization makes the guest OS run with near native speed. see X86 Virtualization in wikipedia

I installed openSUSE 11.2 and consider it as a powerful host for hosting guest OSes. As the kernel is very much optimized for desktop use, virtue of 64 bit openSUSE 11.2 kernel with 1000Hz frequency ( unlike ubuntu karmic 64 bit which is 100Hz frequency kernel and that is the main reason I dumped 64 bit ubuntu)

I installed virtualbox-ose, and using virtualbox I have ubuntu karmic running as a guest OS. virtualbox-ose has two parts host and guest

host is the OS which is powerful enough and can host other OS on top of itself, guest is any OS which should be able to run in virtualmachine. ubuntu 32 bit felt light on top of virtualbox and it is a good guest OS

Host

The powerful openSUSE 11.2 with 1000 Hz frequency kernel is my host. To install virtualbox in openSUSE 11.2 is just a click away. Goto yast and install it, suse will resolve all dependencies. Or if wanted to do it command line it can be done as follows

sudo zypper install virtualbox-ose virtualbox-ose-kmp-desktop

Guest

By default after installing ubuntu ran well, but graphics acceleration was not good . So I installed guest additions from the virtualbox menu (Devices --> Install Guest Additions)

Then rebooted and now ubuntu ran well as a guest

Here are the screenshots for your enjoyment (if you view this from a tabbed browser, right click the following images and open in new tab to get a full view)

Here is the virtualbox settings I configured as an image

I ticked the following in system menu while configuring

1. Enable ACPI

2. Enable IO APIC

3. Enable PAE/NX

4. Enable VT-x/AMD-v

5. Enable Nested Paging

and ticked enable 3d acceleration in display menu while configuring

and I configured networking as bridged

Why virtualbox?

Because, virtualbox has a open source edition and it offers 3d acceleration in guest OS, kudos Sun Microsystem for such a great product

To look further, there are numerous articles about virtualization in internet. To get virtualbox with full USB support, download and install it from virtualbox.org instead of installing ose edition from repository

swappiness --> If we have large RAM, there is probably no use for a swap file and we can decrease the swappiness to a very low value without fear. If the RAM capacity is 512 MB or less than 1 GB RAM, then Ubuntu or any linux uses swap as a swapfile. The default swappiness is normally 60 (but I have seen 40 in case of Fedora 11 after updates). Do not touch the swappiness and cache pressure unless you have atleast 1 GB of RAM

If we decrease swappiness, speed of opening programs feels faster

to get current swappiness of system

sudo sysctl -q vm.swappiness

to change swappiness to value 20, which is low

sudo sysctl -w vm.swappiness=20

to increase the speed of browsing files and folders again and again, we should decrease vfs_cache_pressure. Default vfs_cache_pressure is 100, if we decrease it, kernel virtual machine (vm) caches files more and more

Sometime today morning when browsing irctc and opening some news sites, youtube, Ubuntu took a very very long time. Then I remembered that old debian lenny errata page and followed it and tweaked tcp window scaling settings. If you ever feel that you are not able to visit some sites or browse properly, follow this debian errata