当前位置: 代码迷 >> 综合 >> mac下安装bochs,使用bximage创建磁盘时 报错:could not write disk image
  详细解决方案

mac下安装bochs,使用bximage创建磁盘时 报错:could not write disk image

热度:9   发布时间:2023-11-13 14:55:24.0

人生处处不是坑啊。真的是打死不想当运维。。。

这次这个坑是我们用bochs下的bximage创建磁盘的时候:

$ bximage                                       
========================================================================bximageDisk Image Creation / Conversion / Resize and Commit Tool for Bochs$Id: bximage.cc 12690 2015-03-20 18:01:52Z vruppert $
========================================================================1. Create new floppy or hard disk image
2. Convert hard disk image to other format (mode)
3. Resize hard disk image
4. Commit 'undoable' redolog to base image
5. Disk image info0. QuitPlease choose one [0] 1Create imageDo you want to create a floppy disk image or a hard disk image?
Please type hd or fd. [hd] hdWhat kind of image should I create?
Please type flat, sparse, growing, vpc or vmware4. [flat] flatEnter the hard disk size in megabytes, between 10 and 8257535
[10] What should be the name of the image?
[c.img] hd10m.imgCreating hard disk image 'hd10m.img' with CHS=20/16/63
ERROR: flat file is not writable

注意最后一句ERROR: flat file is not writable报错,解决方法,在第一句bximage前面加上sudo

报错二:Issue 2: install: cannot stat ./bochsdbg: No such file or directory

Solution: #cp bochs bochsdbg

另外,感谢一个博客,没有它,我可能已经放弃这本书的学习了吧。。。
http://imushan.com/2018/07/11/os/Bochs学习-安装配置篇/
对,我真的就是环境装不好,学习的心都没有了,所以,不当运维,不当运维,不当运维。。。

  相关解决方案