Hello, guest. We have noticed that you are not registered at this bug tracker. Your experience will be greatly enhanced if you log in. To do so, you first must register by clicking on the Register tab at the top. If you are already registered, you can login at the Login tab.
Syndicate Syndicate Listing Display Search Login/Register
Bug Id ?
252
Reporter ?
MacGDBp / 1.5
Status ?
Closed
Severity ?
Major
Duplicate Of ?
- none -
Fixed in Revision ?
Mstone ?
Summary ?
MacGDBp 1.5 'Could not open socket' on OS X 10.11.5, Apache 2.4, PHP Version 5.6.24
Report Time ?
August 1, 2016 11:31 PM
Assignment ?
Resolution ?
Fixed
Priority ?
Normal
Dependencies ?
- none -
Mstone (old) ?


Votes
For: 0 (0%)
Against: 0 (0%)
Total: 0

August 1, 2016 11:31 PM NSCF Admin
I am running OS X 10.11.5 and using homebrew to compile Apache/2.4.18 (Unix) PHP/5.6.24.

Homebrew php56-xdebug compiled and enabled. Shows up in PHP Info.

This program makes use of the Zend Scripting Language Engine:
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
with XCache v3.2.0, Copyright (c) 2005-2014, by mOo
with Xdebug v2.4.0, Copyright (c) 2002-2016, by Derick Rethans
with XCache Cacher v3.2.0, Copyright (c) 2005-2014, by mOo

Version 2.4.0
IDE Key netbeans-xdebug
Supported protocols DBGp - Common DeBuGger Protocol
Revision: 1.145

MacGDBp prefs set to port 9000

Network Utility reports:

Port Scanning host: 127.0.0.1
Open TCP Port: 9000 cslistener

PHP.ini configure reads:

[xdebug]
zend_extension=/usr/local/opt/php56-xdebug/xdebug.so
xdebug.remote_enable=On
xdebug.remote_autostart=On
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.idekey=netbeans-xdebug

So: Xdebug is compiled and loading, shows up in phpinfo().
Port 9000 is open.


Everytime I launch MacGDBp @ 9000, there is a message in red in the bottom status bar of the main debugging window that says:


Could not open socket.


Any suggestions on why this is happening? No discussion in the docs or FAQ's

Thanks In Advance.

August 2, 2016 04:24 PM NSCF Admin
For the record:

MacGDBp Version 1.5 (104.0)

August 3, 2016 02:32 AM NSCF Admin

Well, It Turns Out that... Homebrew PHP uses port 9000 to talk, I think, to Apache.

So I configured PHP.so and MacGDBp to use port 9001.

And now it works.

Worth pointing out in the docs somewhere...

August 4, 2016 02:16 AM Robert
Thanks for figuring that out. I added a note about FastCGI to the help page: https://www.bluestatic.org/software/macgdbp/help.php#socket-errors

On August 4, 2016 02:16 AM, Robert changed:
August 4, 2016 02:07 PM NSCF Admin

This might be sound redundantly obvious, but the example would be :

Set the Port Directive in PHP.ini to (say) 9001.
Set the Port Preference in MacGDBp to 9001.

Adding that to your docs would provide a working example.