In linux terminal 1
$ sudo apt-get install qemu-kvm qemu virt-manager virt-viewer
$ git clone git@github.com:mit-pdos/xv6-public.git
$ cd xv6-public
$ make
$ make qemu
$ make qemu-nox-gdb
In linux terminal 2
$ gdb kernel
> target remote localhost:26000
> b exec
> c
> file _cat
> b main
> c
In linux terminal 1
$ cat README
look gdb stoped in breakpoint in terminal 2