0

I'm unable to run gdb. After break main and after i type run, i get the below error and nothing happens.

Error: Error disabling address space randomization: Operation not permitted

I tried running gdb on initials program from pset2, which works perfectly fine and GDB is working fine for the same program when i run it in online ide.

Also, when i tried to run the gdb using the new gui, i get the following errors

gdbserver: linux_ptrace_test_ret_to_nx: Cannot PTRACE_TRACEME: Operation not permitted gdbserver: linux_ptrace_test_ret_to_nx: status 256 is not WIFSTOPPED! gdbserver: Error disabling address space randomization: Operation not permittedenter image description here

Please help.

enter image description here

5
  • what if you execute set disable-randomization off in gdb?
    – kzidane
    Commented Mar 21, 2016 at 20:52
  • @Kareem after executing the command, i'm no longer getting the error. But i GDB is not working as expected after i run the program in gdb it just prints out ""O hai! How much change is owed" in one go even though they are in different lines and then waits for input and nothing will work even after giving the input ( No [gdb] prompt) and i can't even quit the gdb Commented Mar 22, 2016 at 15:35
  • @Kareem added a screenshot of the same Commented Mar 22, 2016 at 15:45
  • what happens if you break 15 instead of break main?
    – kzidane
    Commented Mar 22, 2016 at 17:08
  • @Kareem no change. Commented Mar 22, 2016 at 17:41

0

You must log in to answer this question.

Browse other questions tagged .