Sunday, July 23, 2006

Simple way of clearing Windoz print queues when your printer goes spastic.

This especially good if you have an inkjet printer!

Copy the following to a text file and make sure its saves as 'filename'.bat

i.e: Printq.bat

net stop spooler

cd C:\WINNT\system32\spool\PRINTERS ;NB: You may need to change WINNT to your windows directory

del *.*

net start spooler

Procedure for installing Debian ETCH on Dell PE1950 and other servers using MEGARAID and SAS disks... Document Revision 1.1

I expect the following procedure will be valid for other systems using similar Megaraid chipsets that are not able to be booted using initrd.

The second install was a lot simpler and some of the procedures mentioned in the first attempt as I discovered were not required on the second install.

The revised procedure:

Grab a copy of Etch 2.6.8 net or full install CD No. 1

Boot Etch and run through the install procedure, it will detect all the hardware with no problems.

Set up your drives... I just used '/dev/sda1' as / and a swap area '/sda2'

Run through install till the end this will install the default kernel as 2.6.15-1-686.

Allow the system to reboot and boot again using the install cd.

Go through menu till the drives are selected ( as per partition menu previous) DO NOT CHANGE THE DRIVE PARITIONING just hit 'go back' twice.

F2 to new shell

mount /sys (I found a problem mounting '/sys' on the second build for some reason so I used the following to overcome the problem:

mount -o bind /sys /target/sys

copy your device node files from the live cd into the new root file system

'cp -a /dev/hd* /dev/sd* /target/dev'

mount your root partition :

mkdir /target

'mount /dev/sda1 /target' (make sure the only mount option is rw)

chroot into the new installation

'chroot /target'

mount the kernel file systems

'mount /proc' , 'mount /sys' See notes on mounting /sys above

:/$ cd to /etc


in /etc/kernel-img.conf
ramdisk = /usr/sbin/mkinitrd.yaird

Note: The Network interfaces are swapped on the rear of the case ETH0 is on the right!

:/$ apt-get install yaird initrd-tools sudo ssh

If you want you can start SSH and continue from another PC.... Its a lot easier on the ears!!!
/etc/init.d/ssh start and open an ssh session :/$ ssh root@

:/$ cd /boot
:/$ mv initrd.img-2.6.15-1-486 2.6.15-1-686 initrd.img-2.6.15-1-486 2.6.15-1-686.bak

:/$ yaird --output initrd.img-2.6.15-1-686 2.6.15-1-686

If YAIRD works then do a :/$ ls you should see the new initrd.img-2.6.15-1-686


All being well you will have a working machine. Once this is going just grab the kernel build files and

remember to use the --initrd option during make-kpkg

ie: :/$ make-kpkg --initrd --revision=Custom-PE1950 kernel-image

Make sure in SCSI low-level drivers you select the items below and install them into the kernel (*) not as modules (M) then go the Fusion MPT device section select everything except (ioctl)

SCSI low-level drivers

[*] LSI Logic New Generation RAID Device Drivers
<*> LSI Logic Management Module (New Driver)
<*> LSI Logic MegaRAID Driver (New Driver)
<*> LSI Logic MegaRAID SAS RAID Module
<*> Serial ATA (SATA) support

Fusion MPT device support

<*> Fusion MPT ScsiHost drivers for SPI
<*> Fusion MPT ScsiHost drivers for FC
<*> Fusion MPT ScsiHost drivers for SAS
(40) Maximum number of scatter gather entries (16 - 128)
Fusion MPT misc device (ioctl) driver