Installing and updating Blackfire should be a quick process. This document will guide you through the steps.
Tell us what you want to do:
To start using Blackfire, we are going to install the following:
BLACKFIRE_CLIENT_ID="CLIENT_ID" \
BLACKFIRE_CLIENT_TOKEN="CLIENT_TOKEN" \
BLACKFIRE_SERVER_ID="SERVER_ID" \
BLACKFIRE_SERVER_TOKEN="SERVER_TOKEN" \
bash -c "$(curl -L https://installer.blackfire.io/installer.sh)"
This installs the APT package for the Blackfire Agent. It might prompt for your password to grant root privileges.
sudo blackfire php:install
It is also possible to install the PHP Probe via the package manager. The step-by-step installation guide covers this way of installing Blackfire.
PHP will likely crash when Blackfire is used when one of the following
extensions is also enabled: XHProf
, Pinba
,
Suhosin
, and Uopz
.
If XDebug
is installed, the PHP engine may not behave as
expected; consider disabling it when profiling.
If pcov
extension is installed, Blackfire will not
behave as expected; consider disabling it when profiling.
You can now enable monitoring for your environments.
To profile applications, you need to use a profiling client:
Profile from a browser via our browser extensions (Web applications only).
Profile from the command line via the blackfire
tool
(Web applications, APIs, command line tools, daemons, and more).
Start profiling via: