最近在读《Orange's一个操作系统的实现》,开始部分介绍了虚拟机Bochs的安装及调试,本文把折腾过程做下记录。
操作系统:Ubuntu10.04(最新的版本老是有问题)
软件版本:bochs 2.3.5(和书中保持一致)
1 更新Ubuntu
由于ubuntu 10.04是很老的版本,早在2016年已停止了更新支持,直接sudo apt-get update会失败,好在ubuntu提供了old-release的方案,通过编辑sources.list更新软件源,打开/etc/apt/sources.list,把里面内容全部删除(如果不放心,可以先将原文件备份),然后换上如下地址:
deb http://old-releases.ubuntu.com/ubuntu lucid main restricted universe multiverse
deb http://old-releases.ubuntu.com/ubuntu lucid-security main restricted universe multiverse
deb http://old-releases.ubuntu.com/ubuntu lucid-updates main restricted universe multiverse
deb http://old-releases.ubuntu.com/ubuntu lucid-proposed main restricted universe multiverse
deb http://old-releases.ubuntu.com/ubuntu lucid-backports main restricted universe multiverse
deb-src http://old-releases.ubuntu.com/ubuntu lucid main restricted universe multiverse
deb-src http://old-releases.ubuntu.com/ubuntu lucid-security main restricted universe