Please see the "gdb_support" in demos to find out how to use GDB to debug your apps running upon Occlum.