[DEPRECATED] Hypernode Vagrant is deprecated. Although you may continue to use it, we recommend you to use the Hypernode Docker instead.

Xdebug is a debugger for PHP. It can be used to retrieve extended debug information and stacktraces from your development environment and send it to a log file or to your IDE or browser. As Xdebug has a massive performance impact, it’s not possible to use this debugger on the Hypernode itself.

Xdebug is already installed on Hypernode Vagrant. If you prefer a newer version, you can use this howto to manually build and install xdebug.

Prerequisites

First, setup your Vagrant node and copy your Magento to the Hypernode Vagrant.

Now login as user Vagrant and use sudo to become root:

Install Xdebug

Install all required packages:

  • For PHP7:

  • For PHP5:

Download Xdebug

First we download the latest version of Xdebug. This version can change in time, so check the Xdebug Website to get the preferred sources.

Download the source tarbal:

Build Xdebug from source

When Xdebug is downloaded and unpacked, we can build the extension. This works the same on all PHP versions:

Move xdebug.so in place:

  • For PHP7:

  • For PHP5:

Load the Xdebug PHP extension in your PHP settings

After building, load the zend_extension for both CLI and FPM:

  • For PHP7:

  • For PHP5:

And after that restart PHP-FPM and Nginx:

  • For PHP7:

  • For PHP5:

That’s it 🙂 Xdebug is now installed and configured.

Configuration

See Configuring Xdebug for configuring xdebug and examples to send debug data to your IDE.

31