Bug 5574 - ptrace: No such process (op 0x11 (PTRACE_DETACH), pid 11371, addr 0x0, data 0x0)
Summary: ptrace: No such process (op 0x11 (PTRACE_DETACH), pid 11371, addr 0x0, data 0x0)
Status: ASSIGNED
Alias: None
Product: frysk
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Tim Moore
URL:
Keywords:
Depends on:
Blocks: 2246 5572
  Show dependency treegraph
 
Reported: 2008-01-09 17:14 IST by Andrew Cagney
Modified: 2008-04-03 20:41 IST (History)
2 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Cagney 2008-01-09 17:14:33 IST
Sometimes:

$ ./frysk/bindir/fhpd 
(fhpd) load /bin/bash
Loaded executable file: /bin/bash
(fhpd) start
Attached to process 11371
(fhpd) break main
breakpoint 0
(fhpd) run
Killing process 11371
Loaded executable file: /bin/bash
Exception in thread "Thread-1" frysk.sys.Errno$Esrch: ptrace: No such process
(op 0x11 (PTRACE_DETACH), pid 11371, addr 0x0, data 0x0)
   at frysk.proc.live.LinuxPtraceTask.sendDetach(fhpd)
   at frysk.proc.live.LinuxPtraceTaskState$BlockedSignal.handleDetach(fhpd)
   at frysk.proc.live.LinuxPtraceTask.performDetach(fhpd)
   at frysk.proc.live.LinuxPtraceProcState$Detaching.<init>(fhpd)
   at frysk.proc.live.LinuxPtraceProcState$3.handleDetach(fhpd)
   at frysk.proc.live.LinuxPtraceProc$6.execute(fhpd)
   at frysk.event.EventLoop.runEventLoop(fhpd)
   at frysk.event.EventLoop.run(fhpd)
Comment 1 Rick Moseley 2008-04-03 20:41:16 IST
This bug seems to have morphed into something different at this point in time. 
This sequence now aborts when the breakpoint is set.  I am assigning to you Tim,
but if this is incorrect pass it on to whoever.

The following sequence fails for bash right now.  I am running on an x86_64
machine with both bash and bash-debuginfo installed at version/revision 3.2-20.

 ./fhpd
(fhpd) load bash
[0.0] Loaded executable file: /bin/bash
(fhpd) start
Attached to process 1093
starting with this command: bash
(fhpd) break main
breakpoint 0
(fhpd) Exception in thread "main" frysk.sys.Errno$Eio: ptrace: Input/output
error (op 0x2 (PTRACE_PEEKDATA), pid 1093, addr 0x81a380, data 0x0)
   at frysk.sys.ptrace.AddressSpace.peek(AddressSpace.cxx:67)
   at frysk.sys.ptrace.AddressSpace.peek(AddressSpace.java:76)
   at
frysk.proc.live.AddressSpaceByteBuffer$PeekRequest.request(AddressSpaceByteBuffer.java:93)
   at frysk.proc.live.AddressSpaceByteBuffer.peek(AddressSpaceByteBuffer.java:103)
   at inua.eio.ByteBuffer.getByte(ByteBuffer.java:387)
   at frysk.proc.live.IA32InstructionParser.parse(IA32InstructionParser.java:79)
   at frysk.proc.live.X8664InstructionParser.parse(X8664InstructionParser.java:52)
   at frysk.proc.live.LinuxX8664.getInstruction(LinuxX8664.java:69)
   at frysk.proc.live.Breakpoint.set(Breakpoint.java:153)
   at frysk.proc.live.Breakpoint.install(Breakpoint.java:140)
   at frysk.proc.live.LinuxPtraceProc$BreakpointAction.run(LinuxPtraceProc.java:557)
   at frysk.proc.live.TaskObservation.add(TaskObservation.java:140)
   at
frysk.proc.live.LinuxPtraceTaskState$BlockedSignal.handleAddObservation(LinuxPtraceTaskState.java:1304)
   at frysk.proc.live.LinuxPtraceTask.handleAddObservation(LinuxPtraceTask.java:442)
   at frysk.proc.live.TaskObservation.handleAdd(TaskObservation.java:87)
   at
frysk.proc.live.LinuxPtraceProcState$3.handleAddObservation(LinuxPtraceProcState.java:405)
   at frysk.proc.live.LinuxPtraceProc.handleAddObservation(LinuxPtraceProc.java:427)
   at frysk.proc.live.LinuxPtraceProc$10.execute(LinuxPtraceProc.java:585)
   at frysk.event.EventLoop.runEventLoop(EventLoop.java:365)
   at frysk.event.EventLoop.run(EventLoop.java:482)
   at frysk.bindir.fhpd.main(fhpd.java:185)