Saturday, December 25, 2004

HOWTO: Install Fedora Core 3 Linux on a Sony Vaio PCG-TR2A Laptop



I've installed Fedora Core 3 Linux (the freely-downloadable version of RedHat Linux) on my Sony Vaio PCG-TR2A laptop. It detected and configured correctly for everything except for the odd size (1280x768) display screen and the Intel Centrino-based wireless network interface. Based on my perusal of hints others had left at Linux on Laptops for this and other variations of the PCG-TR* model and for other Linux distros, here is how I got things working. There are still a couple of things left to do, like hotkeys and the integrated video camera; I'll add what I found after I find it/figure it out.

X Configuration

Download the 1280patch, compile it, and then install it:

$ gcc -o 1280patch 1280patch.c
$ su
# mv 1280patch /usr/X11R6/bin
# cd /usr/X11R6/bin
# ./1280patch

To make sure this patch is loaded each time the machine is rebooted, append the line

1280patch

to the bottom of file /etc/rc.d/rc.local. Next, modify your X configuration file /etc/X11/xorg.conf by adding the line

Modeline "1280x768" 80.14 1280 1344 1480 1680
768 769 772 795

(all on one line) to the "Monitor" section. Don't forget to comment-out the HorizSync and VertRefresh lines or else this won't work:

# HorizSync 31.5 - 37.9
# VertRefresh 50.0 - 70.0

Then, in each of the "Display" subsections of the "Screen" section, add

"1280x768"

(including the quotation marks) first in line, prior to the other listed screen resolutions.

Update

It may or may not be necessary, but this is where I ran up2date. You might skip this part. It may or may not affect the rest of the process.

Sound

To get sound to work, open the GNOME ALSA mixer using menu items "Applications" > "Sound and Video" > "ALSA Mixer Control". Deselect the "external amplifier". You might also want to mute the microphone ("mic") to keep from getting feedback screeching.

Fonts

Under menu "Application" > "Preferences" > "Fonts" I chose "Font Preferences" = 9, 9, 9, 9 and "Font Rendering" = "subpixel smoothing (LCDs)". This seemed like a nice compromise between screen readability and getting enough information display on the small 10.5-inch X-Brite screen.

Wireless LAN

Type
  

$ /sbin/lspci

to see that the Linux (if not RedHat) has detected that the computer is using the following wireless LAN NIC:

02:0b.0 Network controller: Intel Corp. PRO/Wireless
LAN 2100 3B Mini PCI Adapter (rev 04)

Based on this information, download the following RPMS: driver ipw2100-1.0.0-27.rhfc3.at.i386.rpm, kernel module kernel-module-ipw2100-2.6.9-1.681-FC3-1.0.0-27.rhfc3.at.i686.rpm, and firmware ipw2100-firmware-1.3.5.at.noarch.rpm. Verify that you are running the 2.6.9.1.681 i686 kernel, which is the latest at the time of this writing, by typing

# uname -a

Now, as root, install these packages:

# rpm -ivh ipw2100-firmware-1.35.at.noarch.rpm
# rpm -ivh kernel-module-ipw2100-2.6.9-1.681-
FC3-1.0.0-27.rhfc3.at.i686.rpm
# rpm -ivh iwp2100-1.0.0-27.rhfc3.at.i386.rpm

(Again, each command should be written all on one line. It is reformatted to fit on the this web page.) Then reboot. Kudzu will detect the WLAN card now. Let it configure the card. Choose DHCP instead of trying to configure a static IP address for it (if you're WLAN access point is a DHCP server. Which is what it almost certainly is. You're on your own if it isn't.) Once the computer has finished rebooting, use

# /sbin/lsmod | grep ipw2100

to verify that the ipw2100 kernel module was really loaded. You can configure your IP interfaces either using the menu "Appliations" > "System Settings" > "Network" or you can configure the relevant file directly:

file /etc/sysconfig/network-scripts/ifcfg-eth0
 

DEVICE=eth0
BOOTPROTO=dhcp
ONBOOT=no
TYPE=Ethernet

file /etc/sysconfig/network-scripts/ifcfg-eth1
 

DEVICE=eth1
ONBOOT=yes
BOOTPROTO=dhcp
HWADDR=xx:xx:xx:xx:xx:xx
NETMASK=
DHCP_HOSTNAME=
IPADDR=
DOMAIN=
USERCTL=no
PEERDNS=yes
GATEWAY=
TYPE=Wireless
IPV6INIT=no
ESSID=xxxxxxxxx
CHANNEL=1
MODE=AUTO
RATE=AUTO

Note that I had previously configured my wireless access point to use channel 1 in order to avoid interference from neighbors using other channels. You should change this file accordingly.

file /etc/sysconfig/network-scripts/keys-eth1
 

KEY=xxxxxxxxxxxxxxxxxxxxxxxxxx

Now restart the network using either
   

# /etc/init.d/network restart

or
   

# /sbin/service network restart

Then verify that the wireless link works by typing
   

# /sbin/iwconfig eth1

and observing the response. It couldn't hurt to verify that your Firefox web browser can still load web pages... ;-)

I will add more as I get additional items working. Remember, "it said use Windows XP or better, so I installed Linux!"


11 comments:

Anonymous said...

cool

Anonymous said...

Awesome!
Thanks for your sharing priceless knowledge. :)

Anonymous said...

I searched ATRPMs site but there are newer kernel versions. Can you send me 3 rpms for wireless 2100?

also how can I find version number of firmware?

mail them to:
mahmood.nt [at) gmail {dot] com

Anonymous said...

Hi! I have a problem with 1280patch and FC5
1280patch does not work under fedora core 5!
Have you try installing FC5 to your TR?
So I installed FC4 and it worked.
Have you got any idea about this problem?

hrzafer@gmail.com

(pcg-tr3ap)

thanks...

Anonymous said...

hi raluke,

I am a beginner in linux and I would like to have my wireless card to work.
I have a PCG-TR2AP , i've installed FC 6 like you told but i dont find the 1280patch nor the RPMS.
Can you tell me how to do that nowaday ? ^^)
Thank you ,
geekcode@hotmail.com

Anonymous said...

This blog solved my sound problem with ubuntu that I've been working on for about 5 hours now. Thanks!

Bertrand said...

Hi,

This awesome: the sound trick works for a PCG-TR2MP as well... it should be a geek stuff, having the external amplifier enabled by default on a laptop chipset !

Wisu said...

Hi Thanks...

I have a Sony PCG-TR5GP, installed Ubuntu without any sound... by default the installation doesn't include gnome-alsamixer...

so with ur tip i installed the gnome-alsamixer.. ran it... unticked use "external amplifier"... and i have sound...

Casey said...

Dude! You're the bomb! Stupid, simple sound fix! ^.^!

Degovx said...

Excellent blog! Ubuntu 8.10 will install all these components but the sound. Your guide and the comment about downloading gnome-alsamixer have helped me to get everything enabled and working!!

Tom W said...

I just installed Ubuntu on this tr2a. running xp on it was so slow, and I couldn't get the sound to work. this did the trick, so now I have sound, thanks!

I still have a lot of HD access time go on, so I wonder if the hd is going.

Post a Comment