Skip navigation

Lost password? | Help

Linux and more...

Linux

Windows 7 on VirtualBox with PCnet driver on Ubuntu Linux

, ,

So now ugraded to Intrepid which is a great relief for when using VirtualBox on custom compiled kernels. Thanks to DKMS, the VirtualBox module is being built on the first startup of a rebuilt kernel, in my case a kernel to favor a duo core cpu.

Upon searching for a solution to use the built-in network drivers of VirtualBox for PCnet-Fast III (AM79C973) and PCnet PCI II (AM97C970A) for Windows 7, I couldn't find a solution. So I figured out a recipe and hope it can help others too. Here's how I did it:

1) Download the PCnet driver here from AMD's website: http://www.amd.com/us-en/ConnectivitySolutions/ProductInformation/0,,50_2330_6629_2452^2454^2486,00.html (It is the first download link - "NDIS5 Driver for Microsoft Windows..."

2) Save the zip file to a new folder and extract. I created the folder "pcnet-driver" and in the command prompt simply used:
unzip V4.51.zip


3) Make an iso CD image of the folder with contents. You can use a CD burning application like Brasero, or use the utility "genisoimage" like this:
genisoimage -o pcnet.iso ../pcnet-driver

This will create an image of the folder and contents.

4) Mount the iso image in VirtualBox and start Windows 7.

5) In Windows 7, go to Device Manager, browse to "Other Devices" and right-click on "Ethernet..." . Select "Update driver software" and "Browse my computer..." on the next dialogue. Then locate the CD image on the "CD drive" and remember to selet "include subfolders".


6) Now the driver should have installed successfully and you can use internet to search for the other missing drivers!

Free replacement OS for Windows

, ,

Another option for people who are used to Windows, and not willing to learn a different operating system, is "ReactOS". The idea is to have a free operating system, compatible with Windows and which can run Windows applications. Here is the website: http://www.reactos.org. So far I have tested the OS on Virtualbox. The installation interface looks pretty much like XP's but the installation was very quick. No wonder, as the downloadable CD image is only about 35 MB! The GUI have a lot of elements like icons and the multi desktop which reminds of KDE but the dialogues look like Windows 2000's. The desktop explorer looks busy when indexing folders. It has kind of a Firefox theme, just like Windows explorer nowadays follows an Internet Explorer theme. There is a basic package manager to install extra applications like Firefox. Once Firefox is installed, I assume a user can download just about any Windows application and install it just as in Windows. Almost all dialogues are identical to Windows. After shutting down, the user is prompted to switch off the machine.

If I should guess what ReactOS holds for the future, I'd say it would become more stable and compliant to Windows, but with a KDE-like interface.

Wireless drivers

Now the new kernel uses a new wireless driver called iwl3945 whereas the original 2.6.22-15 kernel uses the ipw3945 driver. The new driver seemed to get confused how to name the network interfaces. Sometimes "eth1" and other times "wlan0_rename". Later it was clear that the kernel swaps the names on every boot. The firewall complained everytime bout an unknown interface. In the file /etc/modprobe.d/iwl3945 the line "alias wlan0 iwl3945" has been added in the hope to rename "wlan0_rename" to "wlan0", but instead, it was named "wlan1". In the file "/etc/udev/rules.d$ vim 70-persistent-net.rules" the query "DRIVERS=="ipw3945"" and "DRIVERS=="iwl3945"" have been added for both module drivers, so that each kernel can query the available driver and name the interfaces correctly according to the name fileds "NAME="eth1"" and "NAME="wlan0"" respectively. Now the naming stays constant for the new 2.6.25.7 kernel.

New Linux kernel 2.6.25.7

After some time of recompiling this kernel for my Ubuntu distro, this is not the latest one anymore. The compilation went fine, following the instructions. "menuconfig" has been used to create a new configuration file. All the apparent unnecessary modules like the long list of sound drivers and modules for Toshiba, Sony Vaio and Fujitsu-Siemens and some things for IBM computers and servers have been removed. After the first compilation, the wireless didn't work. I found that the new kernel uses the iwl3945 driver instead of the ipw3945 used by the original Ubuntu kernel (2.6.22-14). Then I selected the correct settings for iwl3945 in the new kernel's confg file and downloaded the firmware from http://intellinuxwireless.org. After compiling and reinstalling the new kernel, there was still no success to connect. After a lot of searching on the web, I've found that there needs to be a startup file in the folder modprobe.d under /etc, called "iwl3945" and with the line "options iwl3945 disable_hw_scan=1". On the next startup, the "NetworkManager" applet performed a search and connection had been established to a wireless hub. It seems that the module gets confuse about which device to use, eth1 or one called wlan0_rename, which I think it is supposed to use. It changes to the other one after a restart. This seems not to be serious, but the setting needs to be changed in the "Firestarter" personal firewall everytime, or else the firewall icon will stare with a red eye.

Screen brighness could not be controlled, not from the function keys at least. There was no loaded module called "video" as during a session with the original kernel .After a lot of searching it was found that another display module needs to be selected during kernel configuration, which in turn makes the "video" module visible in the "menuconfig" program, and thus selectable.

video module
this option was not available unless "Video output controls" have been selected, as in the next image.

Video output controls

After the kernel has been compiled with the video module it is possible to control the screen brighness with the function keys (Fn + f7/f8) and there is even an on-screen display!

Introduction to Linux

, , , ...

It all started with Tux, the Linux penguin, a Thai friend who sat like Tux on a rock in the middle of a river, and some memories of work done on Unix some years ago. Something about that photo of the Thai friend reminded me of Tux whom I saw on so many web pages. After making some jokes about him, I eventually read around the picture and became so confused about which distro to use.

I remember Mandrake to be quite popular as it was mentioned many times in conversations between people or the media, but anyway, it rang a bell. So I decided to go for Mandriva and installed it on my old Pentium 3 computer, which then felt like new. By that time, I just got a new Compaq Presario V3407TU laptop (from the V3000 series) with Vista installed. I wasn't very impressed with Vista after the laptop failed to boot only after a week's use. On the other hand, I had only started with Linux on a personal level...


The Ubuntu distro got my final vote for the folowing reasons:
1. When doing a search for Linux, there are almost always a lot of listings from the Ubuntu forums. Most of the time the answer I look for is then also within an Ubuntu forum.
2. Not a solid reason, but the distro originates from my home country, South Africa.
3. I was convinced that the support is superior when I ordered an Ubuntu CD with the Gnome desktop and it arrived here in Thailand within a month, absolutely free of charge. I downloaded and installed XUbuntu, just before the CD arrived, as I was very excited to get started. By the way, a CD can be ordered after registering at Launchpad, accessable from the Ubuntu home page.
4. There were no serious issues which convinced me to try another distro.
5. Ubuntu is very popular even among computer manufacturers.
6. There are special Ubuntu projects like running Ubuntu side-by-side with Windows, without partitioning the hard drive.



The installation of XUbuntu - "Gutsy Gibbon" on the Presario took place about six months ago. I shrank the partition with Vista on it with Vista's partition manager, in the hope that Vista would know how to handle its own partition. It could possibly been done within the Ubuntu installer's partitioner, Anyway, the formatting and installation went smooth, but by that time I didn't know that at least the root file system (/) needs to be mounted onto a partition, so the installer wouldn't let me continue without selecting a partition to mount "/"! The Mandriva installer on my former computer must have assumed the only partition to be the default to mount "/" and let me install happily. On the Ubuntu installer, I then selected "jfs" as a file system and it installed "/" on the new available partition. "jfs" is a file system used by IBM. Normally Linux is installed on an "ext3" or now a new "reiserfs" system. In the past "ext2" was used. "ext2" is more volnurable to immature system shutdowns, during which it can leave data corrupted if nothing worse. I changed to "ext3" later on, but more on that later...

The installation went fine and dual booting Vista, XP and Ubuntu was possible without difficulty, thanks to the "Grub" bootloader of Linux, which doesn't overwrite an existing operating system like Windows's boot entry in the master boot record (MBR), unless you tell it to sweep off an existing partition. The installation was very quick, maybe twenty minutes at most and no floppy is needed to install any SATA drivers, as it is included within the Linux kernel.

At first, the sound didn't work, but after the next boot it was there, but so soft. I got advise to turn up the volume controls in the interface for "ALSA" (Advanced Linux Sound Application if I remember correctly). The volume was normal after that. The command used in a console was "alsamixer", which exposes the volume controls. The wireless needed some setting up, using "NetworkManager" applet. The built-in card reader didn't work as well as the other quick keys with blue LED's. Some function keys on the keyboard might be linked to do aome function, which I haven't tried yet. I was surprised to see that it is possible to access Windows's NTFS file systems within Ubuntu, even accessing user folders without a security limit, while from Vista, it was impossible to see the file system where Linux is installed.

The XFCE desktop of XUbuntu have reacts fast, but lacks some rich eye candy, like the Gnome and KDE desktops. I thought of installing Ubuntu from the received CD, to get Gnome, but didn't want to loose the XFCE dektop I got used to. Then I read thet it is possible to install the Gnome and KDE desktops together with the XFCE desktop. After about two commands in the console, KDE and Gnome downoaded and installed. So then I could log in in any desktop environment and still see all my programs, although it is rearranged in the different menu layouts of the different desktops. The startup screen showed the splash screen of KUbuntu (for KDE), the desktop I installed last. It had been changed to Ubuntu's standard splash screen, using a program called "Startup Manager".

Xfce.png]

Vista enquired about the registration key after the Ubuntu installation. According to what I have read up on the net, Vista uses a daemon which analyses current hardware installed on a computer. If it finds a change, it will require a re-entry of the registration key. Microsoft intended it this way to prohibit illegal copying of its operating system. I suppose the resizing of partitions fired that one off. I also read about the built-in software monitoring daemon, which "decides" what may or may not run to avoid license breaches. That process steals resources. Some of my XP programs were still incompatible with Vista.

I decided to remove Vista. After using the wonderful program called "Vista Boot Pro" to recover the MBR of XP, to be able to boot XP without Vista's boot loader, I used "QtParted" in Ubuntu to remove Vista's partition. I didn't take into account that the partition number for Ubuntu would decrease from three to two. The former partition were defined as sda3 for Ubuntu, and sda2 and sda1 for Vista and XP respectively. The new partition number for Ubuntu would then be sda2 and sda1 for XP. When I rebooted, I got error 2.2 from the Grub boot loader. Installing from the XUbuntu CD again and rolling back a system backup from a tar file which I made shortly after installing Ubuntu put my system back in little time. I kept the newly installed boot folder with the correctly assigned partition numbers though, by copying the installed one to somewhere, then rolled the backup, and then moved the boot folder from the installation back again. I could have saved myself this trouble if I had changed the partition numbers in the menu.lst file in the boot folder, before rebooting. When reinstalling from the XUbuntu CD, I knew by then that at least the root (/) file system needs to be assigned a partition as mount point. It was then that I decided to use the "ext3" file system in place of the former "jfs" one used. There was no problem with the "jfs" but the partition manager didn't support resizing of "jfs" file systems. The swap partition didn't mount due to a new partition id assigned to it, which neede to be updated in the fstab file in the /etc folder. That caused havoc when the system tried to recover from suspend mode. The laptop would shutdown after recovering from suspend mode. The swap partition was also corrupted and neede a reformat, easily done in "QtPAred". After fixing the swap mount the system recovered successfully from suspend mode, but usb ports would fail to recover. That was fixed by white listing the usb kernel module to not turn off during suspend.
December 2009
S M T W T F S
November 2009January 2010
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31