Skip to main content

General installation (0.7.0 or later)

Apply WhaTap monitoring to applications built with Go 1.26 or 1.27. Installation takes three steps with no source code changes. For Go 1.25 or earlier, see General installation for versions earlier than 0.7.0.

Tip

Before starting the installation, prepare the following information:

  • WhaTap project access key (check from [Project menu] > [Management] > [Agent installation])
  • WhaTap collection server IP address

1. Build the application​

Run the following commands on the build server. Monitoring code is added automatically at build time.

wget https://repo.whatap.io/golang-apm/0.7.0/whatap-golang-apm-0.7.0-linux-amd64.tar.gz
sudo tar -xzf whatap-golang-apm-0.7.0-linux-amd64.tar.gz -C /opt
export PATH=/opt/whatap-golang-apm-0.7.0-linux-amd64/bin:$PATH

Prefix your usual go build command with whatap-go-inst. Your source code and go.mod stay unchanged.

whatap-go-inst go build -o myapp .

If the last line shows instrumented build complete, monitoring code has been added.

2. Start the data relay agent​

Run the following commands on the server that runs the application. Go does not need to be installed on this server.

wget https://repo.whatap.io/golang-apm/0.7.0/whatap-go-0.7.0-linux-amd64.tar.gz
sudo tar -xzf whatap-go-0.7.0-linux-amd64.tar.gz -C /opt
sudo /opt/whatap-go-0.7.0-linux-amd64/bin/whatap-daemon start

If whatap-go started appears, the agent is running. Run this once per server. The commands are the same on all Linux distributions.

3. Configure and run​

Create whatap.conf in the working directory where the application runs. Then run the application from that directory.

echo "license={access key}" >> ./whatap.conf
echo "whatap.server.host={collection server IP address}" >> ./whatap.conf
echo "app_name={application name}" >> ./whatap.conf

./myapp

To place whatap.conf elsewhere, set WHATAP_HOME to that directory. For example, run WHATAP_HOME=/etc/myapp ./myapp.

Verify the installation​

Installation is complete when data appears on the Application Dashboard screen in WhaTap monitoring service. If no data appears, check the following.

ItemExpected state
Build outputinstrumented build complete on the last line
whatap-daemon statuswhatap-go running (pid …, listening on port 6600)
FirewallOutbound connections allowed from the application server to TCP port 6600 on the collection server

If the server previously used 0.6.x, see Upgrade from 0.6.x.