Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-30 Thread Robert Nordier

David O'Brien wrote:

> On Fri, Oct 27, 2000 at 01:10:56PM +0200, Robert Nordier wrote:
> > Just doing the disklabel -w -r followed by the disklabel -B is creating
> > a dangerously dedicated disk, 
> 
> Actually this is a "fully dedicated" disk.  (made to look like a 50MB or
> so disk to M$ products)
> Sysinstall is used to create a "dangeriously dedicated" disk (when not
> create slices.
 
I can't say I agree with the distinction (though I'm not sure it
really matters).

Consider this comment in sys/i386/i386/autoconf.c:

|  * For properly dangerously dedicated disks (ones with a historical
|  * bogus partition table), the boot blocks will give slice = 4, but
|  * the kernel will only provide the compatibility slice since it
|  * knows that slice 4 is not a real slice.  []

The "historical bogus partition table" is defined in the file
sys/kern/subr_diskmbr.c as follows:

| static struct dos_partition historical_bogus_partition_table[NDOSPART] = {
|   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, },
|   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, },
|   { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, },
|   { 0x80, 0, 1, 0, DOSPTYP_386BSD, 255, 255, 255, 0, 5, },
| };

and this is the same table entry that appears in the hexdump provided
by Matt Dillon:

| Raw data on disk after 'disklabel -w -r da0 auto; disklabel -B da0 auto'
| 
| 00f0  66 8b 46 08 52 66 0f b6  d9 66 31 d2 66 f7 f3 88  |f.F.Rf...f1.f...|
| . . . . .
| 01e0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 80 00  ||
| 01f0  01 00 a5 ff ff ff 00 00  00 00 50 c3 00 00 55 aa  |..P...U.|

It's a long time since I used sysinstall, but I assume that a "fully
dedicated disk" just has a normal partition table with a single entry 
that allocates all available space.

The above, OTOH, is an illegal fdisk partition table entry, and what
I think most of us would refer to as "dangerously dedicated".

-- 
Robert Nordier

[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-30 Thread David O'Brien

On Fri, Oct 27, 2000 at 01:10:56PM +0200, Robert Nordier wrote:
> Just doing the disklabel -w -r followed by the disklabel -B is creating
> a dangerously dedicated disk, 

Actually this is a "fully dedicated" disk.  (made to look like a 50MB or
so disk to M$ products)
Sysinstall is used to create a "dangeriously dedicated" disk (when not
create slices.

Yep, on the i386 we actually have three kinds of disklables.

-- 
-- David  ([EMAIL PROTECTED])
  GNU is Not Unix / Linux Is Not UniX


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-28 Thread Jamie Heckford

Cool idea. I will add a -z option to the disklabel code and submit it to the
author if thats OK with everyone else?

-- 
Jamie Heckford
Chief Network Engineer
Psi-Domain - Innovative Linux Solutions. Ask Us How.

===
email: [EMAIL PROTECTED]
web:  http://www.psi-domain.co.uk/

tel:+44 (0)1737 789 246
fax:+44 (0)1737 789 245
mobile: +44 (0)7779 646 529
===


On Sat, 28 Oct 2000, you wrote:
> In message <[EMAIL PROTECTED]>, Matt Dillon 
> writes:
> > :Do you have dangerously dedicated mode on by chance?  Some
> > :SCSI BIOS's _will_ crash with this if you use dangerously
> > :dedicated mode.
> > 
> > Yup.
> > 
> > The real question is:  Ok, so if I can't use dangerously dedicated
> > mode, then how do I create a disklabel on a normal partition?  Everything
> > I try using fdisk and disklabel fails.  fdisk will create a normal 
> > freebsd-dedicated dos partition, but disklabel refuses to label it.
> 
> After fdisk creating partitions try,
> 
> dd if=/dev/zero of=/dev/da0s1 count=16
> 
> Then disklabel -r -w and disklabel -B
> 
> Tru64-UNIX has a disklabel -z option which zeros out the disk label.  
> Compaq and Digital before that recommended disklabel -z prior to laying 
> down a new label.  Should we consider a -z option for our disklabel?
> 
> 
> Regards,   Phone:  (250)387-8437
> Cy Schubert  Fax:  (250)387-5766
> Team Leader, Sun/DEC Team   Internet:  [EMAIL PROTECTED]
> Open Systems Group, ITSD, ISTA
> Province of BC
> 
> 
> 
> 
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-hackers" in the body of the message



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Matt Dillon

:Danny Braniss ([EMAIL PROTECTED]) wrote:
:> In message <[EMAIL PROTECTED]>you write:
:> }This is really weird.  I have two valinux rackmount boxes, duel cpu's.
:> }
:> }I was testing the PXE stuff and booting one of the boxes regularly.  
:> }All of a sudden every time I reboot I get:
:> }
:> 
:> i've seen the same, i just reboot it, and it works. sometimes, while
:> the kernel is doing it's init stuff it panics. i haven't seen it fail
:> more than once in a row, so i was thinking maybe some network error
:> that was not dealt properly. btw, the boxes are DELL.
:
:He was not seeing a PXE bug, it was a loader issue with the BIOS.
:The PXE bug you are seeing is with anything build 078 or earlier.
:Intel has a bug in their rom which they fixed back in March of this year.
:
:-- 
:Paul Saab
:Technical Yahoo

Right.  It isn't PXE.  PXE works fine. 

I'm starting to figure out what is going on.  If I create a
'dangerously dedicated' parittion, the BIOS drops dead when the
loader tries to scan it.

If I create a normal fdisk partition, the BIOS works, but disklabel
will not let me label the fdisk partition and I have no clue as to why
not!

fdisk -I da0(init a real freebsd-dedicated DOS partition)
reboot  (reboot just to be sure)
(BIOS does NOT crash with a real dos partition
table)
fdisk da0   (see output below)

The data for partition 1 is:
sysid 165,(FreeBSD/NetBSD/386BSD)
start 63, size 143363997 (70001 Meg), flag 80 (active)
beg: cyl 0/ sector 1/ head 1;
end: cyl 731/ sector 63/ head 254
The data for partition 2 is:

The data for partition 3 is:

The data for partition 4 is:

10:/root# 

disklabel -w -r da0s1 auto  (label it)

10:/root# disklabel -w -r da0s1 auto
Oct 27 11:00:35 10 /kernel: da0: cannot find label (no disk label)
Oct 27 11:00:35 10 /kernel: da0s1: cannot find label (no disk label)
Oct 27 11:00:35 10 /kernel: da0: cannot find label (no disk label)
Oct 27 11:00:35 10 /kernel: da0s1: cannot find label (no disk label)
disklabel: ioctl DIOCGDINFO: Invalid argument
disklabel: auto: unknown disk type

I don't understand why it won't let me label the fdisk partition.  If
only I could label the real partition 'fdisk -I' created, I think the
system will work.

The question is, why is disklabel failing above?  It shouldn't be
failing..it should let me label da0s1.

-Matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Robert Nordier

Matt Dillon wrote:
> 
> : 
> :> Raw data on disk after 'disklabel -w -r da0 auto; disklabel -B da0 auto'
> :
> :If you added "auto" after the "disklabel -B", that may be your problem.
> :
> :-- 
> :Robert Nordier
> 
> type-o.  No auto for the -B still blows up the dos partition
> table.
 
Just doing the disklabel -w -r followed by the disklabel -B is creating
a dangerously dedicated disk, which your BIOS apparently doesn't like.
(See the first hex dump you did, where boot1 has ended up in the MBR.)

That's why installing boot blocks is messing with the partition table,
to answer the question you asked elsewhere.

You need to dd and fdisk before the disklabel commands, which will give
you a standard partition table (at the cost of 63 sectors of disk
space).

-- 
Robert Nordier

[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Matt Dillon

: 
:> Raw data on disk after 'disklabel -w -r da0 auto; disklabel -B da0 auto'
:
:If you added "auto" after the "disklabel -B", that may be your problem.
:
:-- 
:Robert Nordier

type-o.  No auto for the -B still blows up the dos partition
table.

-Matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Robert Nordier

Matt Dillon wrote:
 
> Raw data on disk after 'disklabel -w -r da0 auto; disklabel -B da0 auto'

If you added "auto" after the "disklabel -B", that may be your problem.

-- 
Robert Nordier

[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Anton Berezin

On Fri, Oct 27, 2000 at 12:46:05AM -0700, Matt Dillon wrote:
> This is really weird.  I have two valinux rackmount boxes, duel cpu's.
> 
> I was testing the PXE stuff and booting one of the boxes regularly.  
> All of a sudden every time I reboot I get:
> 
> ...
> BIOS drive A: is disk0
> 
> int= err= efl=00030246 eip=1d29
> eax= ebs=0390 ecx= edx=
> esi=8db7 edi=1c09 ebp=0398 esp=038c
> cs=c800 ds=0040 es=8db7 fs= gs= ss=8db7
> cs:eip= f7 f1 33 d2 8a 4e f6 f7-f1 3d ff 03 76 03 b8 ff
> ss:esp= 00 00 3f 00 00 00 00 00-00 00 02 00 22 0a 00 c8
> BTX halted
> 
> *All* the time.  That is, everything was working fine, then nothing was
> working.  Powering down doesn't help... now every boot comes up with the
> above error.  I didn't change the boot image ... in fact, when I stuck
> the 4.1 CD in the now non-working machine, *IT's* bootloader also 
> crashed every time too (and it worked previously).
> 
> I messed around trying to track down where the loader was dying.  I
> found it was dying in v86int(), called from bd_int13probe() in 
> libi386/biosdisk.c.  It seems to be dying in the BIOS itself.

It looks pretty similar to famous BIOS virus protection thingy.  Can
this be the case?

Cheers,
%Anton.
-- 
 and  would be a nice addition
to HTML specification.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Matt Dillon

Raw data on disk after 'disklabel -w -r da0 auto; disklabel -B da0 auto'

00f0  66 8b 46 08 52 66 0f b6  d9 66 31 d2 66 f7 f3 88  |f.F.Rf...f1.f...|
0100  eb 88 d5 43 30 d2 66 f7  f3 88 d7 5a 66 3d ff 03  |...C0.fZf=..|
0110  00 00 fb 77 44 86 c4 c0  c8 02 08 e8 40 91 88 fe  |...wD...@...|
0120  28 e0 8a 66 02 38 e0 72  02 88 e0 bf 05 00 c4 5e  |(..f.8.r...^|
0130  04 50 b4 02 cd 13 5b 73  0a 4f 74 1c 30 e4 cd 13  |.P[s.Ot.0...|
0140  93 eb eb 0f b6 c3 01 46  08 73 03 ff 46 0a d0 e3  |...F.s..F...|
0150  00 5e 05 28 46 02 77 88  c3 2e f6 06 99 08 80 0f  |.^.(F.w.|
0160  84 79 ff bb aa 55 52 b4  41 cd 13 5a 0f 82 6f ff  |.y...UR.A..Z..o.|
0170  81 fb 55 aa 0f 85 64 ff  f6 c1 01 0f 84 5d ff 89  |..U...d..]..|
0180  ee b4 42 cd 13 c3 52 65  61 64 00 42 6f 6f 74 00  |..B...Read.Boot.|
0190  20 65 72 72 6f 72 0d 0a  00 80 90 90 90 90 90 90  | error..|
01a0  90 90 90 90 90 90 90 90  90 90 90 90 90 90 90 90  ||
01b0  90 90 90 90 90 90 90 90  90 90 90 90 90 90 00 00  ||
01c0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  ||
*
01e0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 80 00  ||
01f0  01 00 a5 ff ff ff 00 00  00 00 50 c3 00 00 55 aa  |..P...U.|

fdisk da0

The data for partition 1 is:

The data for partition 2 is:

The data for partition 3 is:

The data for partition 4 is:
sysid 165,(FreeBSD/NetBSD/386BSD)
start 0, size 5 (24 Meg), flag 80 (active)
beg: cyl 0/ sector 1/ head 0;
end: cyl 1023/ sector 63/ head 255




Raw data on disk after 'fdisk -I da0'

00f0  65 6d 00 4d 69 73 73 69  6e 67 20 6f 70 65 72 61  |em.Missing opera|
0100  74 69 6e 67 20 73 79 73  74 65 6d 00 00 00 00 00  |ting system.|
0110  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  ||
*
01b0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 80 01  ||
01c0  01 00 a5 fe bf db 3f 00  00 00 9d 8f 8b 08 00 00  |..?.|
01d0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  ||
*
01f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..U.|
0200  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  ||

fdisk da0

The data for partition 1 is:
sysid 165,(FreeBSD/NetBSD/386BSD)
start 63, size 143363997 (70001 Meg), flag 80 (active)
beg: cyl 0/ sector 1/ head 1;
end: cyl 731/ sector 63/ head 254
The data for partition 2 is:

The data for partition 3 is:

The data for partition 4 is:





To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Matt Dillon

:> 
:> :I'm just curious.  How many disks are in this box?  We saw something
:> :similar here at work and it turned out that there were multiple disklabels
:> :on the other disks and for somereason it was confusing the loader.
:> :We dd'd the bad sections off and everything worked.
:
:Are you sure it's confusing the loader?  Matt's fault address puts it in 
:the BIOS at 0xc800, which is probably the SCSI adapter's BIOS...> 

I'm confusing something.  If I clear the disk by dd'ing it, the machine
boots (diskless) fine.  

If I do this:
dd if=/dev/zero of=/dev/da0 bs=32k count=4
dd if=/dev/zero of=/dev/da1 bs=32k count=4
disklabel -w -r da0 auto
disklabel -w -r da1 auto
reboot

The machine will boot diskless just fine.  fdisk reports:

Information from DOS bootblock is:
The data for partition 1 is:

The data for partition 2 is:

The data for partition 3 is:

The data for partition 4 is:
sysid 165,(FreeBSD/NetBSD/386BSD)
start 63, size 143363997 (70001 Meg), flag 80 (active)
beg: cyl 0/ sector 1/ head 1;
end: cyl 731/ sector 63/ head 254


*

If I install boot blocks it seems to whack the partition info, and if
I reboot after this point the machine is fracked -- the boot loader blows
up in the BIOS (i.e. the BIOS blows up) trying to scan the disks.

disklabel -B da0
disklabel -B da1

fdisk da0
*** Working on device /dev/da0 ***
parameters extracted from in-core disklabel are:
cylinders=8924 heads=255 sectors/track=63 (16065 blks/cyl)

Figures below won't work with BIOS for partitions not in cyl 1
parameters to be used for BIOS calculations are:
cylinders=8924 heads=255 sectors/track=63 (16065 blks/cyl)

Media sector size is 512
Warning: BIOS sector numbering starts with sector 1
Information from DOS bootblock is:
The data for partition 1 is:

The data for partition 2 is:

The data for partition 3 is:

The data for partition 4 is:
sysid 165,(FreeBSD/NetBSD/386BSD)
start 0, size 5 (24 Meg), flag 80 (active)
beg: cyl 0/ sector 1/ head 0;
end: cyl 1023/ sector 63/ head 255

reboot...
BEWM!!!

*

HEEELP!  Why is the simple installation of boot blocks by disklabel
screwing up the partition table?

-Matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Terry Lambert

> I was testing the PXE stuff and booting one of the boxes regularly.  
> All of a sudden every time I reboot I get:
> 
> ...
> BIOS drive A: is disk0
> 
> int= err= efl=00030246 eip=1d29
> eax= ebs=0390 ecx= edx=
> esi=8db7 edi=1c09 ebp=0398 esp=038c
> cs=c800 ds=0040 es=8db7 fs= gs= ss=8db7
> cs:eip= f7 f1 33 d2 8a 4e f6 f7-f1 3d ff 03 76 03 b8 ff
> ss:esp= 00 00 3f 00 00 00 00 00-00 00 02 00 22 0a 00 c8
> BTX halted
> 
> *All* the time.  That is, everything was working fine, then nothing was
> working.  Powering down doesn't help... now every boot comes up with the
> above error.  I didn't change the boot image ... in fact, when I stuck
> the 4.1 CD in the now non-working machine, *IT's* bootloader also 
> crashed every time too (and it worked previously).

Too bad you killed your test case, or it might have gotton fixed;
you made an image backup before you blew away the labels, or not?

I think you might want to consider putting a DELAY after the BIOS
call itself; perhaps some device that was poked by the BIOS is
latching the bus, and you are doing an INB or OUTB too soon after
the fact (but that's just my gut reaction to a crash following a
BIOS call...


Terry Lambert
[EMAIL PROTECTED]
---
Any opinions in this posting are my own and not those of my present
or previous employers.


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Paul Saab

Mike Smith ([EMAIL PROTECTED]) wrote:
> > 
> > :I'm just curious.  How many disks are in this box?  We saw something
> > :similar here at work and it turned out that there were multiple disklabels
> > :on the other disks and for somereason it was confusing the loader.
> > :We dd'd the bad sections off and everything worked.
> 
> Are you sure it's confusing the loader?  Matt's fault address puts it in 
> the BIOS at 0xc800, which is probably the SCSI adapter's BIOS...> 

I wasn't 100% involved with the problem.  Peter looked into and notice
the disks had bogus labels (sometimes up to 3 labels on 1 disk) and when
he removed them, the machines were happy again.  We never looked into
further because we just didn't have the time.

-- 
Paul Saab
Technical Yahoo
[EMAIL PROTECTED] - [EMAIL PROTECTED] - [EMAIL PROTECTED]
Do You .. uhh .. Yahoo!?


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Mike Smith

> 
> :I'm just curious.  How many disks are in this box?  We saw something
> :similar here at work and it turned out that there were multiple disklabels
> :on the other disks and for somereason it was confusing the loader.
> :We dd'd the bad sections off and everything worked.

Are you sure it's confusing the loader?  Matt's fault address puts it in 
the BIOS at 0xc800, which is probably the SCSI adapter's BIOS...> 

-- 
... every activity meets with opposition, everyone who acts has his
rivals and unfortunately opponents also.  But not because people want
to be opponents, rather because the tasks and relationships force
people to take different points of view.  [Dr. Fritz Todt]
   V I C T O R Y   N O T   V E N G E A N C E




To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message



Re: Really odd "BTX halted" problem booting FreeBSD on VALinux hardware

2000-10-27 Thread Matt Dillon


:I'm just curious.  How many disks are in this box?  We saw something
:similar here at work and it turned out that there were multiple disklabels
:on the other disks and for somereason it was confusing the loader.
:We dd'd the bad sections off and everything worked.
:
:paul

I've got one IDE CDRom and two SCSI disks.

I did play with the labels on those machines.  I will try blowing
them away.  If I put a 'printf("XXX\n");' in front of every single
v86int() call in libi386/biosdisk.c it doesn't crash on me.

... ( time passes ) ...

ok...  I cleared the disk labels using dd.   Hoa!  That seems to have
fixed it allright!  

Very weird.  I was sure I zero'd the labels before I populated the disk,
but maybe not.

Thanks much!  I was tearing my hair out on this one...

-Matt



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message