Saturday, March 26, 2005

less

The new kernel I got from www.kernel.org has some problems with less and man commands.
After some googling, I found that it is a slackware issue. You may either upgrade to the new udev package on www.kernel.org or edit your /etc/udev/rules.d/udev.rules file manually (that's what I did).

Change

/etc/udev/rules.d/udev.rules

KERNEL="tty[p-za-e][0-9a-f]*", "NAME=tty/s%n", SYMLINK="%k"
to
KERNEL="tty[p-za-e][0-9a-f]*", "NAME=pty/s%n", SYMLINK="%k"

And reboot or rerun your kernel. Should work.

Source: A post from Bryan O'Donoghue on ILUG

Kernel 2.6.10

After a 2-week long struggle, I finally got kernel 2.6 running on this machine.

The problem with kernel compilation is that you will probably want to build it as 'clean' as possible. And will leave out a lot of important modules and stuff, and will have to re-compile again and again until you find out everything you needed.

Therefore, I recommend a good dose of patience and time when trying to build a new one from scratch. I found it specially difficult to make the framebuffer device to work correctly - and I wanted my little penguin logo back to the upper left section of my screen.

By the way, check this page for some good info on kernel building.

Friday, December 24, 2004

Dual-boot

The dual-boot is a problem, because installing LILO on the MBR will damage the NTFS boot loader. The easiest way I found for dual-booting by laptop is to use the boot loader from Windows XP to choose the OS to load at startup.

First, installed LILO on the first sector of wherever /boot is located (in my case, /dev/hda3)

Then copied the Linux boot sector to the floppy.

Inserted a DOS-formatted floppy on /dev/fd0, mounted it on /mnt/fd0

to copy the boot sector, enter the following command:

dd if=/dev/hda3 of=/mnt/fd0/linux.bin bs=512 count =1

if=/dev/hda3 because /boot and LILO are installed on /dev/hda3
of=/mnt/fd0/linux.bin to create an image on a file named linux.bin in the floppy

Do not change bs=512 and count=1

Reboot to Windows, and copy linux.bin to directory C:

Edit C:\boot.ini and add at the end of the file

c:\linux.bin="Linux"

Reboot the system and a "Choose OS" screen with options for Windows XP and Linux should appear. Voilá, a dual-boot laptop.

Installation

Installation went pretty straightforward. I must rember however to install the kernel with ACPI (power management) support next time. The problem is that I installed the bare.i kernel and now I'll have to patch or recompile it for ACPI support.

First things first

BIOS

Before booting a 2.4.x kernel, disable in the BIOS the "USB legacy support" option, otherwise, the keyboard hangs and the only way out is hitting the POWER button.


PARTITIONING THE HD


The laptop comes with Windows XP pre-installed, wich means that the whole 40GB HD is 0wn3d by a NTFS partition. I wanted a dual-boot system, so decided to keep 20GB for Windoze and the other half for Linux.

Unfortunatley the fdisk/cfdisk utilities that came with the Slack CD can not re-size the NTFS partition. Did not had Partition Magic, so I formatted, partitioned at my own taste and later re-installed Windoze on /dev/hda1.

I used cfdisk to partition the disk. The output of /sbin/fdisk-l is below.

Disk /dev/hda: 40.0 GB, 40007761920 bytes
255 heads, 63 sectors/track, 4864 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 2432 19535008+ 7 HPFS/NTFS
/dev/hda2 2433 2448 128520 82 Linux swap
/dev/hda3 2449 2813 2931862+ 83 Linux
/dev/hda4 2814 4864 16474657+ 5 Extended
/dev/hda5 2814 3664 6835626 83 Linux
/dev/hda6 3665 4864 9638968+ 83 Linux

The division criteria was disk space:

20 GB for Windoze
128 MB for swap
3 GB for /
6,5 GB for /home
9,2 GB for /usr

I will have to fiddle with these values in the future to find the optimal setup

Software

I'm using Slackware 10.0 [4 CDs] downloaded from http://www.slackware.org
Only the two first CDs are necessary to install, but I would recommend downloading at least the first three. The third and fourth contain patches and source code.

BTW, download bittorrent at http://bittorrent.com/ to speed up downloads.

Hardware

CPU: AMD mobile AMD Athlon(tm) XP2400+ stepping 00
Detected 1788.916 MHz

Memory: 512 MB RAM

PCI: PCI BIOS revision 2.10 entry at 0xfd87b, last bus=3

Video: ATI Technologies Inc Radeon Mobility U1

hda: TOSHIBA MK4025GAS, ATA DISK drive 40GB

hdc: ATAPI 24X DVD-ROM CD-R/RW drive, 2048kB Cache, (U)DMA

PCMCIA: O2 Micro, Inc. OZ6933 Cardbus Controller (rev 01)

Why, in the first place?

There are several web pages on the Web related to this very same subject. I set up this blog for my own notes to some very specific issues for my system, so I could easily access them from anywhere with an Internet connection. I'm also keeping a copy of these notes on my ~/ directory, just in case.

I do not intend to become a serious reference, but, if anything written here helps you, please let me know.

I'm using this blog to fit my own needs rather than to tell the World something, and yes, in a rather selfish manner. If you don't like it, it's your problem, not mine.

FIRST POST!

This is a test to see how this blog will look like. I will soon add some better stuff here.