I'm trying to remotely debug a cgi program running on a remote webserver from my local machine. The remote machine is my dedicated server running CentOS 3, the local machine Ubuntu 10.04, and I have root access to both. My understanding from documentation I've read is that when properly configured I should be able to run the ptkdb debugger on the remote webserver (invoked via a browser) and have the display appear on my local machine for interaction via my local keyboard.
I have the ptkdb debugger installed on the remote machine and know it works since from an X window to the cgi-bin directory on the remote machine via ssh I can run "/usr/bin/perl -d:ptkdb test.cgi" and an X window appears on my local machine with the ptkdb display.
To enable remote debugging from my local machine, I added the following to the remote test.cgi:
and then tried running test.cgi using my local machine's browser, expecting an X window to appear on my local machine with the ptkdb display, ala my first paragraph test. However the browser just spins and eventually times out. No /var/log/error_log entry appears.#!/usr/bin/perl -d:ptkdb sub BEGIN { $ENV{'DISPLAY'} = "local.router+firefall.ip:0.0" ; }
On my local machine I have run, as both user and root,
xhosts webserver.ipnumber webserver.domainname
If what I am trying to do is possible, as the documentation I've found seems to indicate, then I assume that the problem lies in the firewall behind which my local machine resides, and the need to forward the display to the correct ip behind the firewall. I have in the past been able to successfully ssh into my local machine from outside by altering the Lynksys router/firewall - but for that case I knew what application name and port to specify, as the firewall setup requires, and here I know neither. I've tried using "ptkdb" and "perl" with ports 1-6000 with no success.
Advice would be appreciated (and I suspect would also be appreciated by others seeking to do the same - my google search did not seem to find anything addressing this issue). Or perhaps remotely debugging from behind a firewall in Perl cannot in reality be done.
In reply to Remote ptkdb behind firewall by glendeni
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |