OpenBSD on AWS - pciide/wd issue

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

OpenBSD on AWS - pciide/wd issue

Pavel Korovin-2
Dear all,

Today I've got some headache after upgrading OpenBSD-current running on
AWS. Usually I upgrade twice a month using ansible. Last time I
upgraded it on Aug 13. Today I started upgrade to the snapshot built on
Sep 2, the instance didn't boot.

The logs showed where it stuck:

pciide0:0:0: not ready, st=0x0, err=0x00
wd0c: device timeout reading fsbn 0 (wd0 bn 0; cn 0 tn 0 sn 0), retrying
pciide0:0:0: not ready, st=0x0, err=0x00
wd0c: device timeout reading fsbn 0 (wd0 bn 0; cn 0 tn 0 sn 0), retrying
fd0 at fdc0 drive 0: density unknown

For some reason, the boot volume was recognized also as

wd0 at pciide0 channel 0 drive 0: <QEMU HARDDISK>
wd0: 16-sector PIO, LBA48, 16384MB, 33554432 sectors
wd0(pciide0:0:0): using PIO mode 0, DMA mode 2

and then as
scsibus1 at xbf0: 2 targets
sd0 at scsibus1 targ 0 lun 0: <Xen, phy hda 768, 0000> SCSI5 0/direct
fixed
sd0: 16384MB, 512 bytes/sector, 33554432 sectors

As a quick fix I disabled pciide/wd, the instance booted and runs fine.
The dmesgs from successful and unsuccessful boots are attached.
May be this information can be helful for somebody.

--
With best regards,
Pavel Korovin

aws_ok.txt (3K) Download Attachment
aws_nok.txt (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: OpenBSD on AWS - pciide/wd issue

Andrew Daugherity
On Wed, Sep 4, 2019 at 12:56 PM Pavel Korovin <[hidden email]> wrote:
> The logs showed where it stuck:
>
> pciide0:0:0: not ready, st=0x0, err=0x00
> wd0c: device timeout reading fsbn 0 (wd0 bn 0; cn 0 tn 0 sn 0), retrying
> pciide0:0:0: not ready, st=0x0, err=0x00
> wd0c: device timeout reading fsbn 0 (wd0 bn 0; cn 0 tn 0 sn 0), retrying

I can reproduce this on my local Xen environment with the latest
bsd.rd snapshot (OpenBSD 6.6-beta (RAMDISK_CD) #270: Wed Sep  4
11:46:05 MDT 2019); 6.5 works just fine.


> For some reason, the boot volume was recognized also as
>   wd0 at pciide0 channel 0 drive 0: <QEMU HARDDISK>
> and then as
>   sd0 at scsibus1 targ 0 lun 0: <Xen, phy hda 768, 0000> SCSI5 0/direct
>
> As a quick fix I disabled pciide/wd, the instance booted and runs fine.

I noticed that in the problematic snapshot, pciide is listed in dmesg
*before* any xen stuff, whereas in 6.5, xen0/xbf0/sd0 are listed
first, and pciide comes later and says "channel 0 disabled (no
drives)".  I believe xbf(4) and xnf(4) disable any emulated devices
(e.g. wd0, re0) when they load, so maybe they need to load first?

Here's a "known good" dmesg from OpenBSD 6.5 + syspatches (up through
010_frag6ecn):
OpenBSD 6.5 (GENERIC.MP) #5: Thu Aug 29 20:38:30 CEST 2019
    [hidden email]:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 1056964608 (1008MB)
avail mem = 1015353344 (968MB)
mpath0 at root
scsibus0 at mpath0: 256 targets
mainbus0 at root
bios0 at mainbus0: SMBIOS rev. 2.4 @ 0xeb01f (12 entries)
bios0: vendor Xen version "4.4.4_40-61.43.2" date 03/21/2019
bios0: Xen HVM domU
acpi0 at bios0: rev 2
acpi0: sleep states S5
acpi0: tables DSDT FACP APIC WAET SSDT SSDT
acpi0: wakeup devices
acpitimer0 at acpi0: 3579545 Hz, 32 bits
acpimadt0 at acpi0 addr 0xfee00000: PC-AT compat
ioapic0 at mainbus0: apid 1 pa 0xfec00000, version 11, 48 pins, remapped
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Intel(R) Xeon(R) CPU E5420 @ 2.50GHz, 2494.24 MHz, 06-17-06
cpu0: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,SSSE3,CX16,SSE4.1,x2APIC,DEADLINE,HV,NXE,LONG,LAHF,MELTDOWN
cpu0: 6MB 64b/line 16-way L2 cache
cpu0: smt 0, core 0, package 0
mtrr: Pentium Pro MTRR support, 8 var ranges, 88 fixed ranges
cpu0: apic clock running at 100MHz
cpu1 at mainbus0: apid 2 (application processor)
cpu1: Intel(R) Xeon(R) CPU E5420 @ 2.50GHz, 2493.89 MHz, 06-17-06
cpu1: FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2,HTT,SSE3,SSSE3,CX16,SSE4.1,x2APIC,DEADLINE,HV,NXE,LONG,LAHF,MELTDOWN
cpu1: 6MB 64b/line 16-way L2 cache
cpu1: smt 0, core 2, package 0
acpiprt0 at acpi0: bus 0 (PCI0)
acpicpu0 at acpi0: C1(@1 halt!)
acpicpu1 at acpi0: C1(@1 halt!)
acpipci0 at acpi0 PCI0: _OSC failed
acpicmos0 at acpi0
"ACPI0007" at acpi0 not configured
"ACPI0007" at acpi0 not configured
pvbus0 at mainbus0: Xen 4.4
xen0 at pvbus0: features 0x705, 32 grant table frames, event channel 4
"vfb" at xen0: device/vfb/0 not configured
"console" at xen0: device/console/0 not configured
xbf0 at xen0 backend 0 channel 6: disk
scsibus1 at xbf0: 2 targets
sd0 at scsibus1 targ 0 lun 0: <Xen, phy hda 768, 0000> SCSI3 0/direct fixed
sd0: 4096MB, 512 bytes/sector, 8388608 sectors
xnf0 at xen0 backend 0 channel 7: address 00:16:3e:79:85:28
xnf1 at xen0 backend 0 channel 8: address 00:16:3e:46:21:98
pci0 at mainbus0 bus 0
pchb0 at pci0 dev 0 function 0 "Intel 82441FX" rev 0x02
pcib0 at pci0 dev 1 function 0 "Intel 82371SB ISA" rev 0x00
pciide0 at pci0 dev 1 function 1 "Intel 82371SB IDE" rev 0x00: DMA,
channel 0 wired to compatibility, channel 1 wired to compatibility
pciide0: channel 0 disabled (no drives)
pciide0: channel 1 disabled (no drives)
piixpm0 at pci0 dev 1 function 3 "Intel 82371AB Power" rev 0x01: SMBus disabled
vga1 at pci0 dev 2 function 0 "Cirrus Logic CL-GD5446" rev 0x00
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
xspd0 at pci0 dev 3 function 0 "XenSource Platform Device" rev 0x01
isa0 at pcib0
isadma0 at isa0
fdc0 at isa0 port 0x3f0/6 irq 6 drq 2
com0 at isa0 port 0x3f8/8 irq 4: ns16550a, 16 byte fifo
com0: console
pckbc0 at isa0 port 0x60/5 irq 1 irq 12
pckbd0 at pckbc0 (kbd slot)
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pms0 at pckbc0 (aux slot)
wsmouse0 at pms0 mux 0
pcppi0 at isa0 port 0x61
spkr0 at pcppi0
lpt0 at isa0 port 0x378/4 irq 7
vscsi0 at root
scsibus2 at vscsi0: 256 targets
softraid0 at root
scsibus3 at softraid0: 256 targets
root on sd0a (70bae60fe9b7d0df.a) swap on sd0b dump on sd0b
fd0 at fdc0 drive 0: density unknown
fd1 at fdc0 drive 1: density unknown

-Andrew