(This is called SSH tunneling or SSH port forwarding so that we can access the gdb server running on the CS Lab machine via localhost: on your local machine) Note: Please leave the terminal window open at the background in the following steps. Open another terminal window, and use the following command to forward the port (recorded in step 2) on the remote server to your local machine. Clion linux kernel how to#Please refer to this tutorial if you don't know how to do this.ĥ. Open CLion and sync the folder to your local machine. (What qemu-nox-gdb does is that it runs a gdb server at localhost:25784 so that gdb can later connect to this server to debug the code.)Ĥ. I always have 25784, but it might be different for you. Copy xv6 to your working directory on a CS Lab machine, build the source, and run xv6 in debug mode. emperor-01.cs. through emperor-07.cs.Ģ.rockhopper-01.cs. through rockhopper-09.cs.We don't want to use this because it might change over time.) (best-linux.cs. is the Linux machine in the CS labs that currently has the fewest number of other users logged in to it. Please use a specific server in the following list instead of best-linux.cs. Note: You can skip this part if you are compiling xv6 on your local computer or you are already in the CS Lab.ġ. I highly recommend to watch the video first, but this tutorial doesn't require any prior knowledge about gdb. You can find the recorded video on this piazza page. Shivaram has a great tutorial about using gdb to debug xv6 during the discussion section. I have another tutorial about debugging general C programs here: Remote Debug and Execution using CLion. Since xv6 is running in QEMU (instead of a host machine), we have to manually connect gdb to the gdb server, which complicates the setup process. This tutorial is specifically focused on debugging xv6. If you haven't installed CLion or haven't set up file synchronization, you can read my previous tutorial: Setting up Coding Environment for CS 537. documentation (and declared location) shown for the selected function. Clion linux kernel code#
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |