bochs 2.4.2 ubuntu 安装运行问题《orange's 一个操作系统的
用源码安装完后会遇到的问题: 《1》 运行可能碰到如下问题: Event type: PANIC Device: [ ] Message: dlopen failed for module 'x': file not found 这是由于在 安装 的时候,少 安装 了个 bochs -x 包 这个包可以在 http://packages . ubuntu . com/dapp
用源码安装完后会遇到的问题:
《1》
运行可能碰到如下问题:
Event type: PANIC
Device: [ ]
Message: dlopen failed for module 'x': file not found
这是由于在安装
的时候,少安装
了个bochs
-x
包
这个包可以在
http://packages.
ubuntu
.
com/dapper/misc/bochs
-x
找到
也可以在terminal下面输入
sudo apt-get install bochs
-x
这样才算安装
完毕了。
《2》
、启动问题
点进入系统后控制台出现下面的提示:
Please choose one: [6] 6
00000000000i[ ] installing win32 module as the Bochs
GUI
00000000000i[ ] using log file bochsout.
txt
========================================================================
Event type: PANIC
Device: [MEM0 ]
Message: ROM: System BIOS must end at 0xfffff
A PANIC has occurred.
Do you want to:
cont - continue execution
alwayscont - continue execution, and don't ask again.
This affects only PANIC events from device [MEM0 ]
die - stop execution now
abort - dump core
Choose one of the actions above: [die]
问题原因:
在2.
3.
5以前的bochs
使用的BIOS-bochs
-latest是64k的,那个时候需要加上
romimage: file=BIOS-bochs
-latest,address=0xf0000
在2.
3.
5中的BIOS-bochs
-latest更新了,变成了128k的,这个时候配置
需要改为
romimage: file=$BXSHARE/BIOS-bochs
-latest
解决方法:
去掉配置
文件中的address那个
《3》
、bochs
的启动配置
文件bochsrc
一般网上的资料都会提示你安装
好后会有如下工具:
/usr/bin/bochs
Bochs
启动程序
/usr/bin/bximage Bochs
带的制作磁盘镜像文件的工具
/usr/bin/bxcommit 把redolog放进flat磁盘镜像文件中去的交互工具
/usr/share/doc/bochs
/bochsrc-sample.
txt Bochs
配置
文件的例子
/usr/share/bochs
/BIOS-bochs
-* ROM BIOS镜像文件
/usr/share/bochs
/VGABIOS-* 与VGA BIOS镜像文件相关的文件
/usr/bin/bochs
-dlx 启动Bochs
中DLX linux的程序
/usr/share/bochs
/dlxlinux/ DLX Linux的目录,包含它的磁盘镜像文件和配置
文件
/usr/share/bochs
/keymaps/*.
map X11和SDL的keymap列表
其实在终端安装
的却没有第四、第七和第八项,就连第二第三项也要另外安装
:
sudo apt-get install bximage
sudo apt-get install bxcommit
所以,网上那些bochsrx在Ubuntu
是运行不了的,就因为这点,我搞近一个下午,开始我老以为是配置
文件不对呢。
普通的bochsrc:
romimage: file=$BXSHARE/BIOS-bochs
-latest, address=0xf0000
vgaromimage: file=$BXSHARE/VGABIOS-lgpl-latest
但是在Ubuntu
下压根就没有VGABIOS-lgpl-latest
例如:
lzel@lzel-desktop:/usr/share/bochs
$ ls
BIOS-bochs
-latest BIOS-bochs
-legacy BIOS-qemu-latest keymaps
lzel@lzel-desktop:/usr/share/bochs
$
后来我才发现,从终端下安装
bochs
时它把VGA专门作为了一个程序安装
在了/usr/share/vgabios/中了。
lzel@lzel-desktop:/usr/share/bochs
$ ls /usr/share/vgabios/
vgabios.
bin vgabios.
cirrus.
bin vgabios.
cirrus.
debug.
bin vgabios.
debug.
bin
lzel@lzel-desktop:/usr/share/bochs
$
这样配置
文件就要改为:
romimage: file=$BXSHARE/BIOS-bochs
-latest
megs:4
floppya: image=.
/boot.
img,status=inserted
vgaromimage: file=/usr/share/vgabios/vgabios.
bin
boot:a
log:out.
bochs
最 后在是《orange's 一个操作系统的实现》第二章关于bochsrc配置文件内容的修改:
安装好bochs之后,我们需要对bochs进行配置,其实就是对文件bochrsc进行修改!
《orange's :一个操作系统的实现》的附带光盘里有一个已经配置好的bochrsc,但
是它是针对bochs2.3版本的,所以不能用!!!我们需要重新修改bochrsc!
首先将附带光盘里的chapter1子目录下的文件夹a 移动到/home/roothoo/,(主要是为
是让a.img 和 bochsrc在同一文件夹下),然后对bochrc进行修改如下:
注意,#是注释符号!即#之后的语句是无效的,其实#就相当于C+语言中的//
###############################################################
# Configuration file for Bochs
###############################################################
# how much memory the emulated machine will have
megs: 32
# filename of ROM images
#romimage: file=/usr/local/share/bochs/BIOS-bochs-latest
romimage: file=$BXSHARE/BIOS-bochs-latest
#vgaromimage: /usr/local/share/vgabios/vgabios.bin
vgaromimage: file=$BXSHARE/VGABIOS-lgpl-latest
# what disk images will be used
floppya: 1_44=a.img, status=inserted
# choose the boot disk.
boot: floppy
# where do we send log messages?
# log: bochsout.txt
# disable the mouse
mouse: enabled=0
# enable key mapping, using US layout as default.
keyboard_mapping: enabled=1, map=/usr/local/share/bochs/keymaps/x11-pc-us.map
注意看字体为红色的那两句!
修改好之后,别忘了保存!
最后,我们运行bochs
cd /home/roothoo/a #我们切换到a.img 和 bochsrc所在的文件夹,
bochs -f bochsrc #以bochsrc为配置文件启动bochs
然后选择6,
然后再按c键,
OK!!!
ENJOY! -_-

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics











Solution to the problem that Win11 system cannot install Chinese language pack With the launch of Windows 11 system, many users began to upgrade their operating system to experience new functions and interfaces. However, some users found that they were unable to install the Chinese language pack after upgrading, which troubled their experience. In this article, we will discuss the reasons why Win11 system cannot install the Chinese language pack and provide some solutions to help users solve this problem. Cause Analysis First, let us analyze the inability of Win11 system to

You may not be able to install guest additions to a virtual machine in OracleVirtualBox. When we click on Devices>InstallGuestAdditionsCDImage, it just throws an error as shown below: VirtualBox - Error: Unable to insert virtual disc C: Programming FilesOracleVirtualBoxVBoxGuestAdditions.iso into ubuntu machine In this post we will understand what happens when you What to do when you can't install guest additions in VirtualBox. Unable to install guest additions in VirtualBox If you can't install it in Virtua

In Ubuntu systems, the root user is usually disabled. To activate the root user, you can use the passwd command to set a password and then use the su- command to log in as root. The root user is a user with unrestricted system administrative rights. He has permissions to access and modify files, user management, software installation and removal, and system configuration changes. There are obvious differences between the root user and ordinary users. The root user has the highest authority and broader control rights in the system. The root user can execute important system commands and edit system files, which ordinary users cannot do. In this guide, I'll explore the Ubuntu root user, how to log in as root, and how it differs from a normal user. Notice

If you have successfully downloaded the installation file of Baidu Netdisk, but cannot install it normally, it may be that there is an error in the integrity of the software file or there is a problem with the residual files and registry entries. Let this site take care of it for users. Let’s introduce the analysis of the problem that Baidu Netdisk is successfully downloaded but cannot be installed. Analysis of the problem that Baidu Netdisk downloaded successfully but could not be installed 1. Check the integrity of the installation file: Make sure that the downloaded installation file is complete and not damaged. You can download it again, or try to download the installation file from another trusted source. 2. Turn off anti-virus software and firewall: Some anti-virus software or firewall programs may prevent the installation program from running properly. Try disabling or exiting the anti-virus software and firewall, then re-run the installation

How to execute .sh file in Linux system? In Linux systems, a .sh file is a file called a Shell script, which is used to execute a series of commands. Executing .sh files is a very common operation. This article will introduce how to execute .sh files in Linux systems and provide specific code examples. Method 1: Use an absolute path to execute a .sh file. To execute a .sh file in a Linux system, you can use an absolute path to specify the location of the file. The following are the specific steps: Open the terminal

Angular.js is a freely accessible JavaScript platform for creating dynamic applications. It allows you to express various aspects of your application quickly and clearly by extending the syntax of HTML as a template language. Angular.js provides a range of tools to help you write, update and test your code. Additionally, it provides many features such as routing and form management. This guide will discuss how to install Angular on Ubuntu24. First, you need to install Node.js. Node.js is a JavaScript running environment based on the ChromeV8 engine that allows you to run JavaScript code on the server side. To be in Ub

For many users, hacking an Android TV box sounds daunting. However, developer Murray R. Van Luyn faced the challenge of looking for suitable alternatives to the Raspberry Pi during the Broadcom chip shortage. His collaborative efforts with the Armbia

Installing Android applications on Linux has always been a concern for many users. Especially for Linux users who like to use Android applications, it is very important to master how to install Android applications on Linux systems. Although running Android applications directly on Linux is not as simple as on the Android platform, by using emulators or third-party tools, we can still happily enjoy Android applications on Linux. The following will introduce how to install Android applications on Linux systems.
