Sunday, July 24, 2011

Install Zend_Debugger on CENTOS

In setting up a local development server, I need to enable zend_debugger on centos server.

The newer version of the debugger is renamed as Studio Web Debugger (http://www.zend.com/en/products/studio/downloads). Download the debugger and follow the instruction.

However, on CentOS there might be some additional issue:

  1. if SELinux is enabled, you will get warnings like
Failed loading /usr/lib/php/modules/ZendDebugger.so: /usr/lib/php/modules/ZendDebugger.so: cannot enable executable stack as shared object requires: Permission denied.

To fix this, mark ZendDebugger as not need an executable stack.
        execstack -c /usr/lib/php/modules/ZendDebugger.so

To verify ZendDebugger.so does not need an executable stack, use the following command
        readelf -l /usr/lib/php/modules/ZendDebugger.so | grep STACK

outputs:
        GNU_STACK 0x000000 0x00000000 0x00000000 0x00000 0x00000 RW 0x4

The second to last column shows “RW” indicates that it does not need an executable stack.

If it shows “RWX/RWE”, the module does require an executable stack. In that case, an non-preferred approach is to turn off SELinux.

  1. Please also make sure libssl.so.0.9.8 is on the system. If the system has been updated, the entry libssl.so.0.9.8 might be missing from /usr/lib.
To fix that make symbolic link for libssl.so.0.9.8 in /usr/lib.






No comments: