NeXT Computers Forum Index NeXT Computers
www.NeXTComputers.org
 
Log in to check your private messagesLog in to check your private messages

Log inLog in  RegisterRegister


Profile  Search  Memberlist  FAQ  Usergroups
VM image of real system: switch drivers?

 
Post new topic   Reply to topic    NeXT Computers Forum Index -> Emulation / Virtualization
View previous topic :: View next topic  
Author Message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Tue Nov 03, 2015 11:20 pm    Post subject: VM image of real system: switch drivers? Reply with quote

Folks,

I've been making good use of a USB-to-SCSI adapter to image old hard disks, including NS boot disks - from white hardware so far.

They were run with Adaptec 2940 SCSI cards. So of course I image the disk, I boot the image under Virtualbox - and it panics because it can't mount root, of course; it tries to load the 2940 driver and doesn't find one... I can't make Virtualbox fake the expected 2940.

What do folks think is the best way of proceeding? Ideally, is there a boot option (which I haven't managed to find documented thus far) which says, in effect, 'load the IDE driver instead of the 2940 and find root at (hd) instead of (sd)'? Goal is to preserve and explore images as-is, as much as possible. There's plenty doc on *installing* NS on VMs, but bugger all on *bringing up images* of *real* disks...

Thanks!

Mike
Back to top
View user's profile Send private message
pitz



Joined: 14 Aug 2006
Posts: 122
Location: Oregon, USA

PostPosted: Wed Nov 04, 2015 12:23 pm    Post subject: Re: VM image of real system: switch drivers? Reply with quote

corestore wrote:
Folks,

I've been making good use of a USB-to-SCSI adapter to image old hard disks, including NS boot disks - from white hardware so far.

They were run with Adaptec 2940 SCSI cards. So of course I image the disk, I boot the image under Virtualbox - and it panics because it can't mount root, of course; it tries to load the 2940 driver and doesn't find one... I can't make Virtualbox fake the expected 2940.

What do folks think is the best way of proceeding? Ideally, is there a boot option (which I haven't managed to find documented thus far) which says, in effect, 'load the IDE driver instead of the 2940 and find root at (hd) instead of (sd)'? Goal is to preserve and explore images as-is, as much as possible. There's plenty doc on *installing* NS on VMs, but bugger all on *bringing up images* of *real* disks...

Thanks!

Mike


One way to do this is to create a bootable diskette image (either a 2.88 MB image or multiple 1.44 images similar to that used during the initial installation). In the boot diskette images, include a disk driver (e.g., IDE) that is utilized by VirtualBox. I've had problems with older versions of the drivers, but the new ones (like 4.02 or 4.03?) seem to work well with VirtualBox.

When you boot this image in VirtualBox, you should be able to mount the HDD image as an IDE disk and have access to the file system in the HDD image. Update the drivers in the HDD image to have the same IDE drivers (preferably the latest versions available from the files section in this forum).

Note that there are some VM hosts (I can't remember which ones) that allow mounting HDD images as SCSI devices -- although the list of emulated SCSI controllers is very limited and this may be what you were referring to).
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Wed Nov 04, 2015 3:29 pm    Post subject: Re: VM image of real system: switch drivers? Reply with quote

pitz wrote:

When you boot this image in VirtualBox, you should be able to mount the HDD image as an IDE disk and have access to the file system in the HDD image. Update the drivers in the HDD image to have the same IDE drivers (preferably the latest versions available from the files section in this forum).


Files section? Maybe I'm being a bit blind but I can't see it...?

Mike
Back to top
View user's profile Send private message
pitz



Joined: 14 Aug 2006
Posts: 122
Location: Oregon, USA

PostPosted: Thu Nov 05, 2015 12:32 pm    Post subject: Re: VM image of real system: switch drivers? Reply with quote

corestore wrote:
pitz wrote:

When you boot this image in VirtualBox, you should be able to mount the HDD image as an IDE disk and have access to the file system in the HDD image. Update the drivers in the HDD image to have the same IDE drivers (preferably the latest versions available from the files section in this forum).


Files section? Maybe I'm being a bit blind but I can't see it...?

Mike


I needed to qualify that, the files section in this site (outside the forums):
http://www.nextcomputers.org/NeXTfiles/
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Tue Nov 10, 2015 8:19 am    Post subject: Reply with quote

Thanks, I'm on the road just now but will experiment with boot floppy image idea when I'm home.
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Mon Nov 16, 2015 12:02 am    Post subject: Re: VM image of real system: switch drivers? Reply with quote

pitz wrote:
corestore wrote:
Folks,

I've been making good use of a USB-to-SCSI adapter to image old hard disks, including NS boot disks - from white hardware so far.

They were run with Adaptec 2940 SCSI cards. So of course I image the disk, I boot the image under Virtualbox - and it panics because it can't mount root, of course; it tries to load the 2940 driver and doesn't find one... I can't make Virtualbox fake the expected 2940.

What do folks think is the best way of proceeding? Ideally, is there a boot option (which I haven't managed to find documented thus far) which says, in effect, 'load the IDE driver instead of the 2940 and find root at (hd) instead of (sd)'? Goal is to preserve and explore images as-is, as much as possible. There's plenty doc on *installing* NS on VMs, but bugger all on *bringing up images* of *real* disks...

Thanks!

Mike


One way to do this is to create a bootable diskette image (either a 2.88 MB image or multiple 1.44 images similar to that used during the initial installation). In the boot diskette images, include a disk driver (e.g., IDE) that is utilized by VirtualBox. I've had problems with older versions of the drivers, but the new ones (like 4.02 or 4.03?) seem to work well with VirtualBox.

When you boot this image in VirtualBox, you should be able to mount the HDD image as an IDE disk and have access to the file system in the HDD image. Update the drivers in the HDD image to have the same IDE drivers (preferably the latest versions available from the files section in this forum).

Note that there are some VM hosts (I can't remember which ones) that allow mounting HDD images as SCSI devices -- although the list of emulated SCSI controllers is very limited and this may be what you were referring to).


One problem there... I've downloaded every NS 3.3 floppy image I can find on the site and none of them appear to have an IDE driver. Lots of different SCSI flavors, but no IDE. Further suggestions?
Back to top
View user's profile Send private message
Rob Blessin Black Hole
Site Admin


Joined: 05 Sep 2006
Posts: 587
Location: Ft. Collins, Colorado

PostPosted: Mon Nov 16, 2015 3:20 pm    Post subject: Re: VM image of real system: switch drivers? Reply with quote

corestore wrote:
pitz wrote:
corestore wrote:
Folks,

I've been making good use of a USB-to-SCSI adapter to image old hard disks, including NS boot disks - from white hardware so far.

They were run with Adaptec 2940 SCSI cards. So of course I image the disk, I boot the image under Virtualbox - and it panics because it can't mount root, of course; it tries to load the 2940 driver and doesn't find one... I can't make Virtualbox fake the expected 2940.

What do folks think is the best way of proceeding? Ideally, is there a boot option (which I haven't managed to find documented thus far) which says, in effect, 'load the IDE driver instead of the 2940 and find root at (hd) instead of (sd)'? Goal is to preserve and explore images as-is, as much as possible. There's plenty doc on *installing* NS on VMs, but bugger all on *bringing up images* of *real* disks...

Thanks!

Mike


One way to do this is to create a bootable diskette image (either a 2.88 MB image or multiple 1.44 images similar to that used during the initial installation). In the boot diskette images, include a disk driver (e.g., IDE) that is utilized by VirtualBox. I've had problems with older versions of the drivers, but the new ones (like 4.02 or 4.03?) seem to work well with VirtualBox.

When you boot this image in VirtualBox, you should be able to mount the HDD image as an IDE disk and have access to the file system in the HDD image. Update the drivers in the HDD image to have the same IDE drivers (preferably the latest versions available from the files section in this forum).

Note that there are some VM hosts (I can't remember which ones) that allow mounting HDD images as SCSI devices -- although the list of emulated SCSI controllers is very limited and this may be what you were referring to).


One problem there... I've downloaded every NS 3.3 floppy image I can find on the site and none of them appear to have an IDE driver. Lots of different SCSI flavors, but no IDE. Further suggestions?



The EIDE Driver should work: http://www.nextcomputers.org/NeXTfiles/Software/NEXTSTEP/Drivers/nextstep_3.3/beta/

Best Regards Rob Blessin
_________________
Rob Blessin President computerpowwow ebay sales@blackholeinc.com http://www.blackholeinc.com
303-741-9998 Serving the NeXT Community since 2/9/93
Back to top
View user's profile Send private message Send e-mail Visit poster's website
pitz



Joined: 14 Aug 2006
Posts: 122
Location: Oregon, USA

PostPosted: Mon Nov 16, 2015 8:55 pm    Post subject: Re: VM image of real system: switch drivers? Reply with quote

corestore wrote:

One problem there... I've downloaded every NS 3.3 floppy image I can find on the site and none of them appear to have an IDE driver. Lots of different SCSI flavors, but no IDE. Further suggestions?


On the site directory: http://www.nextcomputers.org/NeXTfiles/Software/NEXTSTEP/Floppy_Images/

The "Additional Drivers" floppy image contains the released EIDE/ATAPI driver which is what you need to access the virtual IDE disk. However, I'd probably suggest using the "Beta Drivers" floppy image because it has the "Primary/Secondary (Dual) EIDE and ATAPI" driver that is later than the released EIDE/ATAPI driver. And I think the "Intel GX/Professional IDE Disk Controller" provides even better performance in accessing the virtual disk.

As an aside, I am totally interested in this work, because the concern stuck out to me as a real concern (for using imaged disks in virtual machines). If it's okay, PM me with read access to one of your disk images and I'll see if I can whip up a 2.88 boot disk to add or install the necessary driver. See portions of my old blog post about creating a 2.88 boot disk. http://peterwong.net/blog/creating-an-openstep-boot-cd/
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Mon Nov 16, 2015 10:34 pm    Post subject: Re: VM image of real system: switch drivers? Reply with quote

pitz wrote:
corestore wrote:

One problem there... I've downloaded every NS 3.3 floppy image I can find on the site and none of them appear to have an IDE driver. Lots of different SCSI flavors, but no IDE. Further suggestions?


On the site directory: http://www.nextcomputers.org/NeXTfiles/Software/NEXTSTEP/Floppy_Images/

The "Additional Drivers" floppy image contains the released EIDE/ATAPI driver which is what you need to access the virtual IDE disk. However, I'd probably suggest using the "Beta Drivers" floppy image because it has the "Primary/Secondary (Dual) EIDE and ATAPI" driver that is later than the released EIDE/ATAPI driver. And I think the "Intel GX/Professional IDE Disk Controller" provides even better performance in accessing the virtual disk.

As an aside, I am totally interested in this work, because the concern stuck out to me as a real concern (for using imaged disks in virtual machines). If it's okay, PM me with read access to one of your disk images and I'll see if I can whip up a 2.88 boot disk to add or install the necessary driver. See portions of my old blog post about creating a 2.88 boot disk. http://peterwong.net/blog/creating-an-openstep-boot-cd/


Neither the "Beta Drivers" nor the "Additional Drivers" contain an EIDE... oh. WAIT.

The prompt I'm responding to is the one asking me to select the **SCSI** adapter my **CD-ROM drive** is connected to!

That would explain why I'm not seeing EIDE drivers listed no matter what virtual driver disk image I insert; just various permutations of AMD, Adaptec, BusLogic, DPT etc. SCSI adapters.

So... how do I tell the NS installer to ignore the CD-ROM drive, I just want to load an EIDE **hard disk** controller driver so I can access the flaming hard disk?

Was it not possible to install NS 3.3 on white hardware from an IDE CD-ROM? You could use an IDE hard disk but the installer CD had to be in a SCSI CD drive? Because that's what the installer very strongly implies...

I'll see if I can put the VDI image somewhere accessible. I'm a bit cagey about sharing it as it's not originally 'mine'; I do have permission to have it - but I feel I should check it and 'sanitize' it if required before sharing it with anyone else - just in case there's personal data on it that shouldn't be shared...

Mike
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Mon Nov 16, 2015 10:58 pm    Post subject: Reply with quote

I further confirmed this.

I added a Buslogic SCSI controller to the Virtualbox config.

I booted from floppy.

I inserted the "Beta Drivers" image when prompted; it asked me to select the SCSI adapter my CD-ROM was attached to. I cycled through all the options; they were all SCSI. I picked the BusLogic PCI and let the installer proceed; at no time was an EIDE or ATAPI driver offered to me for the CD-ROM.

Then it asked me to select the adapter my hard disk was attached to ("This may be the same as your CD-ROM"). Then the list was populated with the various EIDE drivers already mentioned. I selected the "Primary/Secondary (Dual) EIDE and ATAPI" driver and let the installer proceed; it immediately attempted to boot - and of course eventually panicked because it couldn't mount root from any of the CD-ROM devices it thought it might have attached - it tried the BusLogic, then went looking for an ATAPI CD-ROM, then gave up and panicked.

Of course, it didn't try mounting root from the hard disk because it's an installer and thought it was doing a clean install. But at least it saw the VDI image as a drive...

I'm not sure any of this gets us any further forward anyway; even if I did have a NS 3.3 CD-ROM VDI image, and mounted it, and thus avoided the panic, what would or could it do next? All it's going to do is offer to blow away the existing NS partition on the hard disk VDI... right? Or are there other installer options? Can I modify the existing installation through GUI tools? Or at least exit the installer to a command line, mount the VDI hard disk image, and tell it to load the EIDE driver instead of Adaptec, and use that to mount root at boot time?

EDIT ok I found and successfully characterized a very old installer bug! Smile

http://www.nextcomputers.org/forums/viewtopic.php?t=389&sid=87b545360d4b0d91de949625d3cb4c4b

Mike
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Tue Nov 17, 2015 4:54 am    Post subject: Reply with quote

Further progress.

I decided to try to brute-force it. I managed to boot the physical hard disk on the original white hardware (Pentium 133!), went into Config app, added the IDE disk driver, and shut down. I then reimaged the disk and made a new VirtualBox VDI. I booted it.

It loads the IDE driver on boot. It sees the VDI drive - ATA Drive 0, primary master - and the (empty) virtual CD-ROM - ATAPI device 1, primary slave. It then spends an unconscionable time - 2 minutes or so - displaying 'hc0: Resetting drives..', then quickly goes through the whole routine again, this time following 'Resetting drives' immediately with 'ATA Drive 0 is not present' despite the fact that it was shown as 'detected' just a second previously (!) - then of course it fails to mount root and panics.

If I do a config=Default boot it does NOT load the IDE driver and panics immediately.

If I do an explicit boot ( for instance hd(0,a)mach_kernel ) it makes no difference.

I've taken a small VirtualBox video screen capture so you can see the latter part of the boot. It plays in Firefox; can't vouch for any other browsers:

http://www.corestore.org/Next1.webm

Thoughts? Need a newer NS IDE driver? Or something set up wrong in VirtualBox? What *exactly* should be the disk storage settings? PIIX3 etc?

Mike


Last edited by corestore on Tue Nov 17, 2015 4:59 am; edited 1 time in total
Back to top
View user's profile Send private message
pitz



Joined: 14 Aug 2006
Posts: 122
Location: Oregon, USA

PostPosted: Tue Nov 17, 2015 1:08 pm    Post subject: Reply with quote

Ouch. Yes, there seems to be other potential issues even if we get an IDE driver (old or new) loaded during the boot process.

But first, your experience with the SCSI/EIDE prompts does remind me of a problem when NEXTSTEP loads the device drivers. From what I remember, even on a standard installation on white hardware without a SCSI adapter, I had to select a SCSI controller for the CDROM location even if my CDROM was on the ATAPI/IDE controller. Then, like you've done, selected the IDE controller for the destination hard drive. Somehow, the IDE driver for the hard drive eventually gets used for the CDROM anyway. I've seen this fixed in OPENSTEP where you can already select ATAPI/IDE for your CDROM location during installation.

Back to the topic, note that SCSI-based installations use "sd0", "sd1", etc. for the disk IDs. Even ATAPI CDROMs are masqueraded as SCSI devices and will be assigned an ID of "sdN" (N depends on the order the devices were enumerated at boot). I believe IDE drives are assigned "hd0", "hd1", etc for the disk IDs.

If your disk image was originally from an Adaptec2940 controller (very popular SCSI controller for white hardware) , there are places in the system that references "sd0". I think one example is /etc/fstab. Probably others too. Even the disklabel in the disk image may have some references indicating that it is a SCSI disk.

Because of the virtual machine virtualizing an IDE controller, our root disk is assigned "hd0" at startup and anything in the kernel previously looking for "sd0" will not find it. I don't have a list of places where such references can appear.

One option is to abandon using IDE altogether. VirtualBox is one of the emulators that can emulate a SCSI controller. Just do the same process like you have done of installing the BusLogic driver while at your white hardware. Image the disk and attach the image into the VirtualBox Buslogic controller. During boot in the virtual machine, the system will ignore the Adaptec2940 driver because the controller is not present, then the system will find the image attached to the virtual Buslogic driver and assign it the same "sd0" disk ID.

Another option is to just use the image as a second disk. You can have a standard NEXTSTEP install on a virtual IDE disk image, so all the boot and kernel stuff works properly, then mount your image as a second virtual IDE disk image. You may still at least be able to browse the file system and access/copy your old data.

Hope this helps.
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Tue Nov 17, 2015 2:31 pm    Post subject: Reply with quote

pitz wrote:

One option is to abandon using IDE altogether. VirtualBox is one of the emulators that can emulate a SCSI controller. Just do the same process like you have done of installing the BusLogic driver while at your white hardware. Image the disk and attach the image into the VirtualBox Buslogic controller. During boot in the virtual machine, the system will ignore the Adaptec2940 driver because the controller is not present, then the system will find the image attached to the virtual Buslogic driver and assign it the same "sd0" disk ID.


That is possibly the best idea I've heard this month. The thing is frigging emulated; why waste time trying to make EIDE work when you can just shove in a good solid reliable SCSI controller?

I'll give it a whirl.

BTW just for giggles, I tried something sneaky last night. I let the system boot from the VDI hard disk image, stopped the boot with a ?, then mounted the boot disk floppy image, and incanted the following rune at the boot prompt:

fd()mach_kernel rootdev=hd0a

In other words, boot the installer from floppy but find root on the hard disk image. It duly booted the installer, I selected a 'dummy' Adaptec CD-ROM driver, then when it prompted for the hard disk adaptor I selected the "Primary/Secondary (Dual) EIDE and ATAPI" from the beta drivers disk, and let the boot proceed. The objective was to get the system to use the later EIDE driver from the beta disk rather than whatever one happened to be on the system already - the one I activated via Config.

This produced slightly different and slightly more encouraging results; it appeared to at least try to access the VDI, but encountered "ATA command C4" errors before panicking. See:

http://www.corestore.org/Next1-2.webm

But I won't try further with EIDE at this point; I'll go for BusLogic in Config and re-image.

Thanks!

Mike
Back to top
View user's profile Send private message
corestore



Joined: 03 Nov 2015
Posts: 10

PostPosted: Tue Nov 17, 2015 3:03 pm    Post subject: Reply with quote

And what do you know, BusLogic simply worked...



The graphics are crap, the mouse doesn't work, but that's finger trouble I guess. EDIT may be more serious than that; it boots, you can login as root, but then the desktop is locked solid... neither mouse nor keyboard work... hmmm still needs work.

Main thing is, it's up! And that is likely to be the start of a general solution for getting images of real white hardware systems running in VMs: add a BusLogic controller.

Still an issue in that it relies on the rest of the old hardware working - but you've outlined alternate strategies for cases where we have *just* a working disk.

Now, anyone know where I can get a license code for the 3270Vision app? Or how to fake it... Smile

Mike

Thanks

Mike
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    NeXT Computers Forum Index -> Emulation / Virtualization All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Powered by phpBB © 2017 phpBB Group