Collecting Build Logs

Logs are spread out among all agents involved in each build. Additionally, for volatile machines such as SUVMs the logs are deleted when the machine is decommissioned. You can collect the logs in a single remote location to help you troubleshoot or understand your builds.

  1. For each non-cloud helper and initiator agents, mount the target remote location to a local path. The remote location must be accessible and writeable for all agent, including cloud helpers if relevant.

  2. For each non-cloud helper and initiator agents, use the CLI to define the log location as the mount location you just created. This can also be done in the user interface in the Agent Settings.

    /opt/incredibuild/management/set_agent_params.py log-mount-directory <path to mount>

    If you do not set this parameter but use the build flag below, the directory /mnt/Incredibuild will be used as the default mount location.

  3. If you are using cloud helpers:

    1. Go the Cloud Settings > Advanced tab and enable Save Logs from Cloud Machines.

    2. Enter the the IP Address or Hostname of the target machine and the path to store your remote logs.

  4. Every time you build, use the --log-remote-path to point to the mount location and define a folder for each build. The folder should have a unique name and help you identify this build. This flag acts as the trigger to use the remote location instead of the default log locations.

    If the value you provide is not unique, we will append a timestamp to the directory to make it unique.

For example, if you used the following commands:

/opt/incredibuild/management/set_agent_params.py log-mount-directory /mnt/incredibuild

ib_console --log-remote-path sprint22/Build123 make -j 100

Build logs for the build will be located at /mnt/Incredibuild/sprint22/Build123.