Last modified: Friday 03 January 2003 (D. Quah) Linux

Linux: Sony VAIO PCG N505X

(Elegant image due to Charles Barrasso)


This page up through Updates describes what I found out installing Red Hat 6.1 (Kernel 2.2.12-20) on my Sony Vaio in February 1999. Since then I have updated to Red Hat 7.0 (Kernel 2.2.16-22, April 2001) and Red Hat 8.0 (Kernel 2.4.2-2, December 2002). Some of the original information and queries remain useful; other parts no longer relevant. But I figured I would keep the original description here just as an audit trail. Additional user information on upgrading Red Hat Linux.


  • Intel Celeron 333MHz, 128M ram, 6.8G hd
  • 10.4in XGA TFT screen
  • Video adaptor NeoMagic MagicMedia 256Av (also known as NM2200 and NM2360) 2.5M ram
  • Serial, XGA monitor, printer, i.LINK S400, USB mouse, and USB ports on Port Replicator
  • 1 Type II PCMCIA slot: For Ethernet card (3Com EtherLink III Lan/PC card 3c589c-tp, 3c589c-combo); CD-ROM drive
  • USB port: Floppy drive
  • 1.2 kg/22.2mm thick


  • Windows 98 (delivered)
  • Linux (Red Hat/Intel 6.1 Cartman, to install from the Net)
  • X11 (/Linux)

Subtleties: Executive summary

I do not have a Linux CD-ROM, and I wanted to install over the net. A suitable Linux-on-a-floppy boots fine from the USB floppy drive. However, Linux itself does not recognize the USB floppy drive and so cannot write a lilo boot floppy, whether as part of the Install process or afterwards.

This might not be a problem, but for one reason or another my Linux install appeared to blow away the Win98 partition. Thus, Linux booted fine but the machine then couldn't access the Win98 information---even though the latter was all still there. When Win98 finally got reinstated (not as arduous as one might think, given the circumstances), the LILO information on the MBR now had gotten wiped. So this time Win98 booted but Linux was unknown, even when all the Linux information remained secure on the inaccessible partition.

The trick is to use the original boot floppy but to stop its execution before it tries to do another full Install-Over-the-Net. Rerun LILO but now with complete stanzas for both Linux and Win98.

[If anyone else tries to do this and figures out where I might have improved the procedure, please email to let me know. The procedure given here is purely for information. It works for me, but I cannot be responsible for what it will do to your system. Also if you're going to do this, it helps if you're comfortable rewriting MBR's. Otherwise, avail yourself of the nearest (and, unlike software, non infinitely expansible) Linux service engineer.]


  • An IP address for the new machine; your network's netmask; a gateway IP address; a domain name; your machine's new hostname
  • One Windows 3.5in floppy (for the partition manager boot floppy)
  • One fresh 3.5in floppy (for a Linux boot image)

Linux installation, step by step

  • Repartition the hard disk keeping the Windows information already there. To do this:
    1. Run Defragmenter under Win98 to move all Win98 information to be contiguous on the front of the disk.
    2. Use Ranish's partition manager program part to reduce the size of the Win98 partition (I used version 2.37.12, current at time of application). Be sure to save the MBR: Creating a part boot floppy under the default installation procedure does that automatically, but watch out otherwise. The Red Hat-provided fips works too, and might have been preferable, I don't know.
    3. I got drive C: down to 2.5G, and looked for /dev/hda4 which is where I had thought PowerSuspend would go, and hence would need to be kept. (Apparently, if the W98 partition is set active, then suspend-to-disk works: The data are saved by default to a hidden file save2dsk.bin in C:\. Thanks for for pointing this out to me.) But not on this machine..., so the rest I mentally pencilled in for Linux.
    4. (Perhaps this is one place I went wrong, but I did not specify anything further about wanting a Linux partition. Or perhaps if I'd used fips I wouldn't have run into the Subtleties above.)
    5. No more Linux partition information is required here; that will be done, on the fly, as part of the network Install.
  • Bring out Linux
    1. The Red Hat installation online manual works for this. If you want to read that instead of following what's here under this bulletpoint, that's fine.
    2. Get a boot image from the Net. Because of where I am in London, I used the UK sunsite mirror. Look up the Red Hat mirror list for whatever is best for you. Go into images/ and grab pcmcia.img. This is the image for installing Linux via PCMCIA/Ethernet.
    3. Write the boot image to a floppy disk. In Linux, do
        dd if=pcmcia.img of=/dev/fd0 bs=1440k
      or, in an MSDOS window, do
        rawrite pcmcia.img a:
    4. Reboot the machine off the floppy just written. Even though the drive is USB, this works fine. At the boot: prompt, I typed
      linux mem=128M expert[CarriageReturn].
    5. Install procedure continues. When the procedure asked for FTP site, I gave it; when it asked for Directory, I said /pub/Mirrors/ (your responses here will likely differ).
    6. Workstation/Server/Custom Install? I wanted to preserve the Win98 partition, so I went for Custom Install (I believe the Workstation Install would do as well now), and partitioned as follows: /dev/hda5 (root, 86M) /, /dev/hda6 (usr, 2243M) /usr, /dev/hda7 (home, 886M) /home, /dev/hda8 (swap, taking up the rest, approximately 73M). (If I were to do this again, I might give a little more room to /dev/hda5 and / --- perhaps up to 100M.)
    7. Altogether I picked up 379 pkgs for a total of 601M, taking 2h30m.
    8. For Monitor, I used Custom, with a Vertical refresh rate of 50-150 and a Horizontal sync rate of 31.5--45.0. (These work for me but if someone out there knows better, please tell me what they should be.)
    9. LILO: I asked it to write to MBR and floppy. Problem: Writing to MBR, the way I'd done things above, Linux doesn't know about the Win98 partition at /dev/hda1 and doesn't allow me to write in the appropriate stanza (below). Next, when lilo tries to write to floppy, it falls over as Linux now doesn't know about USB floppy drives (even though it had booted off one to begin). This way of setting things up zaps the MBR and lets LILO manage the boot process, eventually, from the W98 partition. If you make the Linux partition active, preserving the original MBR, suspend-to-disk in W98 won't work: It requires W98 partition be set active.
  • Linux runs and boots, but the Win98 partition is invisible and inaccessible. Prepare now---for a step further below---your own file, say lilo.conf, that will be accessible to you (perhaps on the root partition) and containing at least the stanzas:


    This lilo.conf is the file I actually used in its entirety. Remember if your hard disks are set up differently, you'll have to replace the root, other, and table fields with whatever might be appropriate for you.
  • Boot off the part (partition manager) floppy, and change /dev/hda1 to type W95 FAT. Restore the MBR that had been saved above. Now, Win98 is recognized, but while Linux is still there, you can't get at it. So, ...
  • Boot off the pcmcia.img floppy. When boot: appears, type vmlinuz root=/dev/hda5. This gives access to enough of a Linux and its partitions that you can then run
      /sbin/lilo -C lilo.conf
    using the lilo.conf above to rewrite the MBR. Do a sync to be sure.
  • Reboot. (At this point my machine froze on trying to umount some file systems. Powering up and down only (pushing the power switch and holding it for about 3 seconds) gave me back the frozen screen each time. I did a hardware reset using a paperclip on the reset button [bottom of machine].)
  • Success. The machine now comes up with the warm friendly LILO boot: prompt. Hitting tab shows both vmlinuz and w98 images available. More important, both work.


  1. The European version of this machine has no builtin modem (Win or otherwise). That's the machine I have so I can't test if the (US-supplied machine) builtin modem works.
  2. The ethernet card setup I have (above) works.
  3. The trackpad works. (I haven't tried a USB mouse, and don't plan to. I have been told, however, that USB instructions that work are available.)
  4. The CDROM drive (via pcmcia) works. I did have to ln -s /dev/hdc /dev/cdrom, although this will vary with setup. I was able to browse a mounted CDROM with the GNOME File Manager gmc. To check that the drive plays CD music properly, I plugged in speakers to Line Out on the drive itself (Thanks to for pointing this out to me. If you want to do more than test the software/hardware combination here, you might wish to turn to cdda2wav or CD Paranoia.)
  5. Sound and video: After compiling the extra modules for an updated kernel, the following /etc/conf.modules (kind of) worked for me, but this machine clearly must be able to do better than SoundBlaster 3.01 8-bit. (If you're going to use SoundBlaster, it's likely also a good idea to do an exclude irq 5 in your /etc/pcmcia/config.opts.
    [Updated: 28 November 2000] The new ALSA sound drivers now contain code that work with this machine. I used version 0.5.9d, compiled using --with-isapnp=no; loaded in a new /etc/conf.modules; and turned off PnP in the machine's CMOS (do this with Function Key F2 while the Sony boot image is displayed). Remember, if your xmms player, for instance, shows the spectrum going satisfactorily, but no sound emanates, that's because the ALSA driver's mixer channels are muted by default. Use aumix or an OSS mixer to set the volume. Warning: Do not sit at your machine with headphones plugged in and over your ears while experimenting with this (to state the obvious). For one, I had tried loading the sound drivers, compiled with --with-isapnp=yes, and not turning off PnP. On booting Linux, the machine started emitting a very loud, high-pitched whine. Such a setup might, eventually, have worked but no one within 100 meters of me was willing to let me continue the experiment. Imagine what that will do to your eardrums if you're on headphones.
    See also Hugo.


  1. Tweak XF86Config to improve performance? I am currently using this.
  2. Does accelerated X server work? I had earlier had to buy a commercial server for use on my Dell Latitude as, at that time (1997), XF86_SVGA did not support the NeoMagic NM2090. That was the past, though, and I am glad to see that XF86_SVGA now does, but no machine can ever be too thin, rich, or fast. Bas van der Linden reports good results with using the accel-driver in 16-bit colormode, using his XF86Config.
  3. Parallel and USB mouse ports on the port replicator: I haven't tried these and don't plan to for the foreseeable future.
  4. How to make rescue floppies with the USB floppy drive unrecognized (but bootable from)?


  1. Red Hat 7.0 Anaconda kernel 2.2.16-22, 2001-04-18. After the hard disk crash, since I had the opportunity, I decided all the different partitions had to go, so everything lives now in just /dev/hda2 mounted as /.
  2. Red Hat 8.0 Seawolf kernel 2.4.2-2, 2002-12-29. From zeniiia. Put pcmcia.img, pcmciadd.img onto a floppy each. Boot off the first, use the second for additional drivers. Choose upgrade, select more swap under /, migrate to ext3 filesystem. The first boot after upgrading got me only to LI of LILO. So I booted again off pcmcia.img, and typed vmlinuz root=/dev/hda2 back at the boot: prompt. Boot continues and gave me enough access to my files on the root partition. Make an appropriate lilo.conf somewhere and /sbin/lilo -C it. I used
    since (obviously) I had my linux partition in /dev/hda2 whereas a Windows partition had installed itself in /dev/hda1.
  3. Red Hat Linux upgrades: A user perspective.

Jump to Danny Quah's Home Page | Recent Output | Current Manuscripts |
Short Bio | Selected Publications |
Intellectual Property Rights IRL | The Weightless Economy IRL |

Danny Quah,

LSE Economics Department
Houghton Street
London WC2A 2AE
Copyright © Danny Quah 1999--2003