bx_dbg_read_linear: physical memory read error on chapter 2 First Steps #20
-
Hii all. I followed the exact steps and copied the code verbatim under https://ordoflammae.github.io/littleosbook/#hello-cafebabe. This is what I get when I run 00000000000i[ ] LTDL_LIBRARY_PATH not set. using compile time default '/usr/lib/x86_64-linux-gnu/bochs/plugins'
========================================================================
Bochs x86 Emulator 2.8
Built from GitHub snapshot on March 10, 2024
Timestamp: Sun Mar 10 08:00:00 CET 2024
========================================================================
00000000000i[ ] BXSHARE not set. using compile time default '/usr/share/bochs'
00000000000i[ ] lt_dlhandle is 0x55da8b081160
00000000000i[PLUGIN] loaded plugin libbx_parallel.so
00000000000i[ ] lt_dlhandle is 0x55da8b082e00
00000000000i[PLUGIN] loaded plugin libbx_speaker.so
00000000000i[ ] lt_dlhandle is 0x55da8b083ee0
00000000000i[PLUGIN] loaded plugin libbx_biosdev.so
00000000000i[ ] lt_dlhandle is 0x55da8b084920
00000000000i[PLUGIN] loaded plugin libbx_gameport.so
00000000000i[ ] lt_dlhandle is 0x55da8b0851b0
00000000000i[PLUGIN] loaded plugin libbx_extfpuirq.so
00000000000i[ ] lt_dlhandle is 0x55da8b085a10
00000000000i[PLUGIN] loaded plugin libbx_iodebug.so
00000000000i[ ] lt_dlhandle is 0x55da8b086290
00000000000i[PLUGIN] loaded plugin libbx_serial.so
00000000000i[ ] lt_dlhandle is 0x55da8b08a490
00000000000i[PLUGIN] loaded plugin libbx_unmapped.so
00000000000i[ ] reading configuration from bochsrc.txt
00000000000i[ ] lt_dlhandle is 0x55da8b08af50
00000000000i[PLUGIN] loaded plugin libbx_textconfig.so
00000000000i[ ] lt_dlhandle is 0x55da8b08b6e0
00000000000i[PLUGIN] loaded plugin libbx_sdl2_gui.so
00000000000i[ ] installing sdl2 module as the Bochs GUI
00000000000i[SDL2 ] maximum host resolution: x=1920 y=1080
00000000000i[ ] using log file bochslog.txt
Bochs internal debugger, type 'help' for help or 'c' to continue
Switching to CPU0
Next at t=0
(0) [0x0000fffffff0] f000:fff0 (unk. ctxt): jmpf 0xf000:e05b ; ea5be000f0
<bochs:1> c
bx_dbg_read_linear: physical memory read error (phy=0x0000322f3331, lin=0x00000000322f3331)
Next at t=662802
(0) [0x0000fffffff0] f000:fff0 (unk. ctxt): jmpf 0xf000:e05b ; ea5be000f0
<bochs:2> c
bx_dbg_read_linear: physical memory read error (phy=0x0000322f3331, lin=0x00000000322f3331)
Next at t=1325794
(0) [0x0000fffffff0] f000:fff0 (unk. ctxt): jmpf 0xf000:e05b ; ea5be000f0
<bochs:3> c
bx_dbg_read_linear: physical memory read error (phy=0x0000322f3331, lin=0x00000000322f3331)
Next at t=1988672
(0) [0x0000fffffff0] f000:fff0 (unk. ctxt): jmpf 0xf000:e05b ; ea5be000f0
<bochs:4> q
(0).[1988672] [0x0000fffffff0] f000:fff0 (unk. ctxt): jmpf 0xf000:e05b ; ea5be000f0 This is my bochslog.txt. I'm on Debian GNU/Linux Trixie/Sid with Bochs 2.8. What am I doing wrong, thanks in advance! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
The files of concern as discussed in #18 |
Beta Was this translation helpful? Give feedback.
-
@arun-mani-j, I stepped through all the different steps, comparing my files to yours, and it appears that everything becomes different when you create your ISO file. All the binaries before that are identical. Additionally, when I run my ISO, it works perfectly. What is your grub setup? Any logs or warnings when running |
Beta Was this translation helpful? Give feedback.
I must have been wearing my lucky hat - I got so nervous, I tried the images available in Bochs' sample images and they also had the same issue. I reinstalled packages, changed memory limits but everything failed with same error.
Then I tried searching for the errors in web, though most of them were due to buggy programs... then I found this AskUbuntu post - https://askubuntu.com/questions/1521719/bochs-cant-access-bootloader-address-0x7c00-error-physical-memory-read-error and the answer by the OP themselves: