APLawrence.com -  Resources for Unix and Linux Systems, Bloggers and the self-employed

2005/04/16 initrd


Some material is very old and may be incorrect today

© April 2005 Tony Lawrence

I recently had a confusing issue with trying to install an updated kernel on a machine I could only reach remotely. This is a dedicated machine at a large web hosting company. You can do quite a bit remotely: you can boot from a rescue image, you can access the box through its ttyS0 port if the network is broken, you can even have the whole thing reinstalled. But you can't select the kernel that it is going to boot - it's only going to boot the default kernel.

Well, we wanted to update that kernel - it wasn't horribly old, but things change, and security issues come up, so the decision was made to update. Unfortunately, I really didn't look closely at the current configuration, and ended up with an unbootable machine.

I really don't have a complete answer to what did or didn't happen yet. Looking at the existing /boot directory, there were several kernels present, some of which had accompanying initrd files. However, the booted kernel had no initrd file, so I assume it was not needed. The purpose of initrd is to allow a two stage boot: a file system image from the indicated image is loaded onto a ram disk, and the kernel loads other modules that it needs from that image. It's often used for scsi disks and RAID controllers where the driver has been provided as a loadable module. This system is some sort of SATA RAID, so I would think it would need that, but then again there is the oddity that there was no initrd file for the booted kernel, nor any mention of it in /etc/lilo.conf. You create the initrd image with mkinitrd.

If there had been an initrd image, we could mount the image (on the loop device) and see what modules are in it. This is a script that helps do that: http://sial.org/howto/linux/initrd/initrd-util

But, as I said, the booted kernel had no such image. This low level stuff confuses me a bit - I can grok it at some level, but when faced with a puzzle like this, I'm a bit lost. I can look in /proc/modules and see there's nothing there about a scsi driver: there's md5, ipv6 , iptables stuff, microcode and binfmt_misc, but that's all.

I can see the drive stuff with "dmesg" but I don't yet know if the new kernel should have been able to boot this hardware (it was a yum download, not compiled from scratch - which is probably what I should have done)

Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
Loading Adaptec I2O RAID: Version 2.4 Build 5go
Detecting Adaptec I2O RAID controllers...
Red Hat/Adaptec aacraid driver (1.1.2-lk2 Dec 21 2004)
3ware Storage Controller device driver for Linux v1.26.00.039.
3w-xyzx: No cards found.
3ware 9000 Storage Controller device driver for Linux v2.26.02.001.
libata version 1.02 loaded.
ata_piix version 1.02
PCI: Setting latency timer of device 0000:00:1f.2 to 64
ata1: SATA max UDMA/133 cmd 0x1F0 ctl 0x3F6 bmdma 0xFFA0 irq 14
ata1: dev 0 cfg 49:2f00 82:346b 83:7d01 84:4003 85:3469 86:3c01 87:4003 88:207f
ata1: dev 0 ATA, max UDMA/133, 156301488 sectors: lba48
ata1: dev 0 configured for UDMA/133
scsi0 : ata_piix
Using anticipatory io scheduler
  Vendor: ATA       Model: ST380817AS        Rev: 3.42
  Type:   Direct-Access                      ANSI SCSI revision: 05
ata2: SATA max UDMA/133 cmd 0x170 ctl 0x376 bmdma 0xFFA8 irq 15
ATA: abnormal status 0x7F on port 0x177
scsi1 : ata_piix
SCSI device sda: 156301488 512-byte hdwr sectors (80026 MB)
SCSI device sda: drive cache: write back
 sda: sda1 sda2 sda4 > sda5 sda6 sda7 >
Attached scsi disk sda at scsi0, channel 0, id 0, lun 0
 

That doesn't mean a lot to me, frankly. And of course because I can't see anything from the failed boot, I have little clue to what it was missing or had trouble with.


If you found something useful today, please consider a small donation.



Got something to add? Send me email.





(OLDER)    <- More Stuff -> (NEWER)    (NEWEST)   

Printer Friendly Version

->
-> 2005/04/16 initrd

9 comments


Inexpensive and informative Apple related e-books:

Take Control of Numbers

Take Control of Parallels Desktop 12

Take Control of the Mac Command Line with Terminal, Second Edition

Take Control of Preview

Take Control of Automating Your Mac





More Articles by © Tony Lawrence







Tue Apr 26 21:34:20 2005: 385   bruceg2004


I am just interested in a follow up on this issue. Did you get things working again, and how so? When you say you can access by ttyS0, what do you mean by that, if the network is down (a modem connected to ttyS0?) Or some other kind of device you can use to access the machine if the network is down?

Just wondering...

- Bruce



Tue Apr 26 21:46:03 2005: 386   TonyLawrence

gravatar
Yes, I got it working, but only by reimaging and restoring from backup.


This hosting service gives you a machine you can ssh to and login with an account that sends you to a serial port on your box.. very handy feature, but it wasn't enough to fix this :-)



Wed Apr 27 14:04:42 2005: 391   bruceg2004


That is a neat feature. But what if the network is down? Is that machine on a totally different network? Do they offer modem access to the machine, and then you can get to the serial port? I have wanted to try and mess around with something like this for work. Right now, I just have a regular modem on our main server, and from there, I can get anywhere, albeit slowly...

- Bruce






Wed Apr 27 14:28:06 2005: 393   TonyLawrence

gravatar
No, they don't offer modem access. I think the assumption is that if the network is totally down, no point in your having access anyway :-)







Wed Apr 27 15:07:41 2005: 395   bruceg2004


I am also saying if the network on *your* end is down for some reason, and no way to use SSH. Although I have seen almost zero downtime with my home cable connection, there is of course, a possibility, and if I still have my phone, I can always dial in. I have had to do that once during a power outage at my house, and got a call on my cell, that something absolutely could not wait, so the laptop, and modem was the only way to get through.

Do you have any idea what kind of device is used to allow network access, and then access to a system via the serial port? I know they exist, but I am not sure what they are called. I think a lot of KVM manufacturers specialize in that type of HW, but I am not even sure what to type into google, to find out how much they cost, and all the options for them. I will probably look at Raritan, which is the only KVM I will purchase now, after several other brands, Raritan seems to work best with multiple Unix flavors, and Win32 systems. I always had mouse and keyboard issues going from *nix to Windows, or vice verca, with other KVM brands, and Raritan has always been flawless.

- Bruce






Wed Apr 27 15:17:30 2005: 397   TonyLawrence

gravatar
It's probably something very much like a Digiboard Portserver - you ssh into some machine and it sends you off to a particular serial port on the device.



Wed Apr 27 15:26:47 2005: 398   bruceg2004


Strange... I keep getting "Connection Refused" errors from (link) Can you get the site to come up, Tony?

- Bruce






Wed Apr 27 15:56:45 2005: 399   TonyLawrence

gravatar
Pops right up for me.. but give 'em a call - they actually have knowledgable people who will talk to you.. very strange policy, I know :-)



Wed Apr 27 16:04:42 2005: 400   bruceg2004


It's coming up for me now. Maybe a small DNS issue, or some other little glitch. Yes, it is always nice to call a company, and have a knowledgeable individual at the other end. :-)

- Bruce

------------------------


Printer Friendly Version

Have you tried Searching this site?

This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more.

Contact us


Printer Friendly Version





If it looks like a duck, and quacks like a duck, we have at least to consider the possibility that we have a small aquatic bird of the family Anatidae on our hands. (Douglas Adams)




Linux posts

Troubleshooting posts


This post tagged:

Kernel

Linux

Unix



Unix/Linux Consultants

Skills Tests

Unix/Linux Book Reviews

My Unix/Linux Troubleshooting Book

This site runs on Linode