Setting Up an Eggplant Performance Injector on Mac

The following instructions describe how to set up and run injectors on Mac systems without the full the Eggplant Performance installation. The instructions are divided into the following tasks:

Step by Step: Install Java

The Mac injector runs using Java, but the application package (.pkg file) does not include it. Verify that a JDK (Java Development Kit) is installed before you install the Eggplant Performance injector.

Note: This quote from the Oracle Mac FAQ explains why you need a JDK: "Installing a JRE from Oracle does not update java -version symlinks or add java to your path. For this functionality, you must install the full JDK."
  1. Check whether a JDK is installed by entering the following command in a Terminal window:

    java -version

    Mac message when no JDK is installed

  2. If you need to download a JDK, click More Info to open the Oracle website.
  3. Download a JDK and follow the installation procedure.

    Installing Java for use with a Mac injector in Eggplant Performance

  4. After you install Java, enter java -version in a Terminal window again to display and verify the new version information.

    OS-X-injector_java-version

Step by Step: Install the Mac Injector

Install the Eggplant Performance injector as follows:

  1. Verify the machine on which you want to install the injector meets the system requirements as described in Injector Installation.
  2. Download the latest Eggplant Performance Injector (Mac OS) from the Eggplant website. The Mac injector is available to download as an application package .pkg file.
    Note: Injectors do not require a license to operate.
  3. Click to install the package file using Apple's Installer application.

    Installing the Mac injector, step 1

  4. During the installation, you may be asked to provide your Mac user account username and password.

    Password prompt during Mac injector installation

  5. Proceed through the injector installation wizard.

    Successful installation screen

Run the Injector

The Mac injector runs as a daemon, which starts as soon as the installation process is finished, and runs automatically whenever the Mac boots up. You should be able to connect to it from Eggplant Performance Studio.

You can also start the injector daemon as described in Starting the Injector Manually, but you must first stop it as described in Stopping the Injector Daemon below.

Note: The user specified to start the daemon must have superuser permissions. Otherwise, the daemon starts with insufficient permissions to write to the log files. When the injector runs with insufficient permissions, it responds to commands from Eggplant Performance Studio, but it does not work properly.

Stopping the Injector Daemon

  1. To stop the injector daemon, run the following command in a Terminal:

    sudo launchctl unload /Library/LaunchDaemons/com.testplant.injector.Injector.plist

    Note: You must have superuser permissions in order to stop the daemon. Otherwise, you will see the following error when you execute the command above:

    launchctl: Error unloading: com.testplant.injector.Injector

  2. Verify the injector stopped by checking the system log for a message that says the injector "Exited...."

    Mac injector stopping message

Starting the Injector Daemon Manually

As explained above, the daemon restarts automatically when the Mac boots up. You can also restart it manually using the command below if you stop first it as described in Stopping the Injector above.

sudo launchctl load /Library/LaunchDaemons/com.testplant.injector.Injector.plist

Note: You must have superuser permissions to start the daemon. Otherwise, the daemon starts with insufficient permissions to write to the log files, as seen below in Console. When you start the daemon with insufficient permissions, it responds to commands from Eggplant Performance Studio, but it does not work properly.

Mac injector restarting

Configure the Port

By default, the injector listens for connections from the Test Controller machine on port 39000. However, you can change the port by performing the following steps:

  1. Stop the injector daemon.
  2. Using a user with superuser permissions, open the .plist file, which is located at:

    /Library/LaunchDaemons/com.testplant.injector.Injector.plist

    Note: You must have superuser permissions in to edit the .plist file.
  3. Edit the line in the .plist file with the contents of the final <string> tag inside the <array> tag after <key>ProgramArguments</key> as shown where the cursor is in the sample screen below. By default this is 39000.

    Mac injector change port commands

View the Injector Logs

You can view the injector logs as follows:

  1. Open the Console application by navigating to Applications > Utilities.
  2. In the list on the left, click to expand /var/log.
  3. Click eggPlantPerformanceInjectorOut.log or eggPlantPerformanceInjectorErr.log.

    Mac injector logs

 

This topic was last updated on January 13, 2022, at 02:42:23 PM.

Eggplant icon Eggplantsoftware.com | Documentation Home | User Forums | Support | Copyright © 2022 Eggplant