Debugging on remote machine

46 views
Skip to first unread message

Jan Honza Odvarko

unread,
Nov 13, 2010, 9:54:33 AM11/13/10
to ndb - the node.js debugger
I can't connect ndb to a node process (launched as $ node --debug
script.js) that is running on a different machine, it works only with
127.0.0.1 host. Is that known limitation or I am rather doing
something wrong?

Honza

Scott Taylor

unread,
Nov 13, 2010, 6:23:36 PM11/13/10
to ndb - the node.js debugger

Yeah - just use the --host option (see --help for other options like --port if you need them).

HTH,

Scott

Jan Honza Odvarko

unread,
Nov 15, 2010, 7:32:32 AM11/15/10
to ndb - the node.js debugger
I did use the --host option.

Here is my scenario.

1) I have ran the node process one the first machine (10.0.0.2) as
follows:
$ node --debug-brk main.js
debugger listening on port 5858

2) Consequently I ran the ndb on the second machine:
$ ./bin/ndb --host 10.0.0.2
Could not connect to host 10.0.0.2 on port 5858. Will try again in 2
seconds.
Could not connect to host 10.0.0.2 on port 5858. Will try again in 2
seconds.

Both machines in the local network and there is no firewall.

Honza

Scott Taylor

unread,
Nov 16, 2010, 10:16:06 AM11/16/10
to nodejsd...@googlegroups.com

I'd do a head check to make sure that port is actually open:

nmap 10.0.0.2 -p 5858

If it *is* open, then please file a bug report:


Thanks,

Scott

On Nov 13, 2010, at 9:54 AM, Jan Honza Odvarko wrote:

Jan Honza Odvarko

unread,
Nov 17, 2010, 1:36:40 PM11/17/10
to ndb - the node.js debugger
I have found some more info and a solution here:
http://groups.google.com/group/nodejs/browse_thread/thread/bc7a1fec84c55128/2d0daacf500b730f?lnk=gst&q=debugging#2d0daacf500b730f

The problem is that V8 debugger thread listens only on 127.0.0.1

Honza
Reply all
Reply to author
Forward
0 new messages