I trying to follow the instruction on connecting to valgrind using gdb. Valgrind memcheck is starts properly and asks to connect using following gdb command:
target remote | vgdb --pid=53181
but when I run this command, I get an error
Remote communication error. Target disconnected.: Connection reset by peer
what is my mistake?
It appears that error
Remote communication error. Target disconnected.: Connection reset by peer.
is general and may indicate invalid command as well. If you run in gdb
target remote | something
it will give you the same error message.
It appeared for me, that extra space after | symbol was excess.
Correct command was actually
target remote |vgdb --pid=53181
My GDB version is GNU gdb (Ubuntu 10.2-0ubuntu1~18.04~2) 10.2