Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Ubuntu 16.04 lts desk; Ubuntu 14.04 server
Posts: 366
Rep:
Win95 install under qemu
Hi--
Hope someone can help me with this. I have tried to install Win95 under qemu and can get only so far.
The key, it seems to me, is that Win95 needs both a CD and a floppy to install.
I have done apt-get install qemu, created the virtual disk, etc.
I got a boot disk image from http://www.bootdisk.com and created a boot disk. Then I did this:
Code:
# qemu -boot a -fda /dev/fd0 -hda /home/doug/qemu/hd.img
It got as far as to create an R:\ mapping, but it then when I try to switch to drive R:\ says "Not ready reading drive R:." Drives C: and D: are invalid drive specs. Yes, the Win95 CD is in the drive.
I tried to pkunzip the image file, got winb95b.IMA which I renamed to winb95b.img, and then used this code on it--it gets to "booting from floppy" and then hangs:
Code:
$ qemu -boot a -fda /path/to/my/bootdisk.img - hda /home/doug/qemu/hd.img
What I am missing it seems to me is a way to tell it to look to the bootdisk for the boot sequence, and then the CD for what to install. But I have not found an answer to this in any g4l searches.
Is this peculiar just to Win95?
And the big question: How can I get this to install?
Thanks for your help. I rely on you guys a lot. Maybe some day I can give advice to new(er) people, just like you folks!
Drives C: and D: are invalid drive specs. Yes, the Win95 CD is in the drive.
Two things. First, I don't see on the command line where you specified the CD drive. If you don't tell QEMU what file to use for the CD drive, I don't think it will use one at all. Second, did you partition and format the C: drive before trying to access it? If not, that would explain why it isn't a valid drive.
Distribution: Ubuntu 16.04 lts desk; Ubuntu 14.04 server
Posts: 366
Original Poster
Rep:
AdaHacker--
Thanks, you are giving me hope!
So after a few false starts from the hint to specify the cd drive, I did this:
Code:
qemu -boot a -fda /dev/fd0 -cdrom /dev/hda -hda /home/doug/qemu/hd.img
Then when it came to the A:> prompt I typed fdisk, chose large disk support, and let the defaults go for the rest of it. That completed, I typed format C: /s and got a drive formatted.
But I cannot seem to get any further--Can't actually get Win95 to install.
Restarting the original linux command just gives me an a:/ prompt and I can switch to a c: prompt. Perhaps I need to have some sort of cdrom support.
So what's next?
Thanks! I can almost taste getting this thing installed!
Restarting the original linux command just gives me an a:/ prompt and I can switch to a c: prompt. Perhaps I need to have some sort of cdrom support.
Well, now that you've copied the system files to the formatted drive, it's no longer to use A: as the boot drive, so you can change that option to '-boot c'.
I don't know exactly what boot disk you're using, but there's a chance that you'll need to install some generic ATAPI CD-ROM drivers before DOS will be able to see the CD drive. I know I've had to do that in the past.
Distribution: Ubuntu 16.04 lts desk; Ubuntu 14.04 server
Posts: 366
Original Poster
Rep:
AdaHacker--
OK, I changed the command line to:
Code:
# qemu -boot c -cdrom /dev/hda -hda /home/doug/qemu/hd.img
And got the same thing--except it flashed the Win95 splash screen for a split second. But it does not show any other drives, and indeed the A: drive is not a valid filespec either. I tried all drives from d: through z: one at a time.
So the question of the hour seems to be, where do I find the CD driver, and then how do I get it to where the virtual machine can see it? Copy it to the floppy and boot one more time from the floppy?
OK, I just noticed this - you're giving the wrong device for the CD drive. Your CD drive is almost certainly not /dev/hda, unless you have a really bizarre hardware setup. More likely it's /dev/hdc or /dev/hdd.
As for the A: drive no longer being valid, that's because you didn't specify it on the command line this time. Try something like this:
Code:
# qemu -boot c -fda /dev/fd0 -cdrom /dev/hda -hda /home/doug/qemu/hd.img
At this point, you should at least be able to boot from the C: drive. I suggest you copy all the files from your boot disk over to C: and set yourself up a bare-bones DOS environment, just to make things a little easier.
Concerning CD-ROM drivers, Google is your friend. A quick search for "DOS generic ATAPI CD-ROM drivers" turned up this file, which may meet your needs. Note that I haven't tried this, so I can't vouche for its quality. The page I found that on also has lots of other drivers and information.
As to the cd drive, when under gnome I go to system|administration|disks, this is what it tells me it is, unusual as it seems. I have tried running the qemu command with both the /dev/hda and /media/cdrom0 locations, both with the same (non)results.
Is there a command line way to find out where the cdrom actually is? I want to believe you are right, because it seems reasonable.
Is it possible that cdsys stuff is the cd drivers I need? What do I do with them.
Thanks AdaHacker for sticking with me on this. We are making progress!
Distribution: Ubuntu 16.04 lts desk; Ubuntu 14.04 server
Posts: 366
Original Poster
Rep:
OK, found a sloppy way to do what I asked: I put a cd in the cdrom drive and typed mount. What I got was:
Code:
/dev/hda on /media/cdrom0 type iso9660 (ro,noexec,nosuid,nodev,user=doug)
So it seems that /dev/hda is right, as is /media/cdrom0.
So it tells us, it seems to me, that we have to look elsewhere other than the possibility of the cdrom not being specified correctly. Do you see it the same way?
So it seems that /dev/hda is right, as is /media/cdrom0.
Well that's wierd. Not that it makes any difference what the device is as long as you know it's the right one. As for the mount point, qemu doesn't care about that. If all else fails, you could always rip an image of the CD and use that.
From the listing you posted, it looks like you probably already have CD drivers on your boot disk. Check your config.sys and autoexec.bat to see if they're being loaded. If you're booting from the C: drive, make sure you've copied both those files into C:\, otherwise the drivers won't be loaded on boot.
Distribution: Ubuntu 16.04 lts desk; Ubuntu 14.04 server
Posts: 366
Original Poster
Rep:
AdaHacker--
Somehow you got me installed! I "din't change nuthin'!" I restarted qemu using
Code:
# qemu -boot c -fda /dev/fd0 -cdrom /dev/hda -hda /home/doug/qemu/hd.img
and this time the Win95 splash screen stayed on longer, then it reported there was an r:\ drive, and I could read the CDrom. I rechecked, and the config.sys already had the stuff in it as you suggested--must have somehow been added on this boot, although the file still had a 1999 date on it!
So is that the same code I will use to start up qemu from now on? Or should I switch it?
I have a bunch of new questions about what to do with it now that I have it installed, so I will start some new threads with those questions, since they are off topic for this thread.
Thanks AdaHacker for sticking with me and for all your help--you are a life saver!
So is that the same code I will use to start up qemu from now on? Or should I switch it?
If it works, stick with it. Strictly speaking, you only need to use the same image file, but if you leave out the fda or cdrom options, you won't have access to that hardware.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.