NMT CSE Wiki

Dept. of Computer Science & Engineering

User Tools

Site Tools


commons:xv6

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
commons:xv6 [2017/01/27 23:16]
ljencka
commons:xv6 [2019/10/16 16:45] (current)
Line 1: Line 1:
-How to run xv6/jos on a CSE machine+==== How to run xv6/jos on a CSE machine ====
  
-## 0: Get a CSE account+===**Note: Due to the magic of mainline code, a custom qemu package is no longer required**=== 
 + 
 +== 0: Get a CSE account ==
  
 First, you'll need a CSE account. The instructions for getting one can be First, you'll need a CSE account. The instructions for getting one can be
Line 8: Line 10:
 You can use the *guest* account on a lab machine, but your data will be deleted on logout! You can use the *guest* account on a lab machine, but your data will be deleted on logout!
  
-## 1: Log into a CSE machine+== 1: Log into a CSE machine ==
  
 You can SSH into a CSE login machine like so: You can SSH into a CSE login machine like so:
  
-```+<code>
 $ ssh USER@login.cs.nmt.edu $ ssh USER@login.cs.nmt.edu
-```+</code>
  
 If you'd like to use qemu graphically, you should use this ssh command If you'd like to use qemu graphically, you should use this ssh command
 instead: instead:
  
-```+<code>
 $ ssh -XYC USER@login.cs.nmt.edu $ ssh -XYC USER@login.cs.nmt.edu
-```+</code>
  
 There are more in-depth instructions [[ssh|here]]. Or, of course, you can log into any CSE lab machine. There are more in-depth instructions [[ssh|here]]. Or, of course, you can log into any CSE lab machine.
  
-## 2: Make and run xv6/jos+== 2. Running xv6 == 
 + 
 +Clone xv6 into your home directory as such: 
 + 
 +<code> 
 +$ git clone git://github.com/mit-pdos/xv6-public.git 
 +</code> 
 + 
 +Then build it: 
 + 
 +<code> 
 +$ cd xv6-public 
 +$ make 
 +</code> 
 + 
 +You can then run xv6 in qemu using gdb by running: 
 + 
 +<code> 
 +$ make qemu-nox-gdb 
 +</code>
  
-We've created a wrapper script that'll run `make` with the right variables! It's as simple as:+And then connect to qemu's gdb by running the following in gdb:
  
-``` +<code> 
-$ 325make ++ target remote localhost:26000 
-```+</code>
  
-If you'd like to also launch gdb at the same time you can run:+Note that the port number is subject to change and can be found as output when ''make qemu-nox-gdb'' is run, this should be shown more in detail in your Lab 1 PDF.
  
-``` +==== Alternate Method ==== 
-$ 325make --gdb +If you prefer to use the magic of containers, either on your own machine or on the CSE machines, there is a Ubuntu 16.04 Dockerfile created for this class located on [[https://github.com/oparkins/nmt-class-helpers/tree/master/CSE325/xv6-docker|github]].
-```+
  
-Both of these commands will start up a tmux session. There's a good primer on tmux [[https://danielmiessler.com/study/tmux/#gs.t9gaMWc|here]]. 
commons/xv6.1485558979.txt.gz · Last modified: 2019/10/16 16:45 (external edit)