Post-Installation Configuration and Startup

Depending on the method you chose to install AnzoGraph DB, there are additional configuration steps you need to perform following installation. This topic describes the required steps as well as other optional configuration steps:

Install Dependencies to Run the C++ Extensions

Required if you installed the C++ extensions. If you installed the AnzoGraph DB UDXs when running the Installer, you also need to install additional C++ dependency and support libraries required to run the extensions. The installer provides a .repo file to aid you in configuring the yum repository and installing the required software packages. The following packages need to be installed on each host server in the cluster:

libarchive13
libarmadillo10
libboost_filesystem1_71_0
libboost_iostreams1_71_0
libboost_system1_71_0
libgrpc++1
libflatbuffers1
libhdfs3
libnfs13
libserd-0-0
libsmb2
shadow-utils

The ability to write to the /etc/yum.repos.d directory requires root access permissions. See Adding, Enabling, and Disabling a YUM Repository for more information on defining and using yum repositories.

This section includes instructions for using the included .repo file to install the C++ dependencies with or without internet access:

Installing the RPMs via the Internet

Follow the steps below if the AnzoGraph DB servers have external internet access.

  1. Copy the csi-obs-cambridgesemantics-udxcontrib.repo file from the <install_path>/examples/yum.repos.d directory to the /etc/yum.repos.d directory. For example, the following command copies the file from the default installation path to /etc/yum.repos.d:
    sudo cp /opt/cambridgesemantics/examples/yum.repos.d/csi-obs-cambridgesemantics-udxcontrib.repo /etc/yum.repos.d
  2. Next, run the following command to enable the repository and install the required packages:
    sudo yum install --enablerepo=csi-obs-cambridgesemantics-udxcontrib libarchive13 libarmadillo10 libboost_filesystem1_71_0 libboost_iostreams1_71_0 libboost_system1_71_0 libgrpc++1 libflatbuffers1 libhdfs3 libnfs13 libserd-0-0 libsmb2 shadow-utils
  3. Repeat these steps on all servers in the cluster.

Installing the RPMs via the Supplied TAR File

Follow the steps below if the AnzoGraph DB servers do not have external internet access.

  1. From a computer that does have internet access, download the dependency tarball, csi-obs-cambridgesemantics-udxcontrib.centos7.tar.xz, from the following Cambridge Semantics Google Cloud Storage location: https://storage.googleapis.com/csi-anzograph/udx/csi-os-contrib/centos7/2023-04/202304181246/csi-obs-cambridgesemantics-udxcontrib.centos7.tar.xz.

    You can run the following cURL command to download the tarball:

    curl -OL https://storage.googleapis.com/csi-anzograph/udx/csi-os-contrib/centos7/2023-04/202304181246/csi-obs-cambridgesemantics-udxcontrib.centos7.tar.xz(.sha512)
  2. Also from the computer that has internet access, download the repomd.xml.key from the following Cambridge Semantics Google Cloud Storage location: https://storage.googleapis.com/csi-rpmmd-pd/CambridgeSemantics:/UDXContrib/CentOS-7_SP5/repodata/repomd.xml.key.

    You can run the following cURL command to download the file:

    curl -OL https://storage.googleapis.com/csi-rpmmd-pd/CambridgeSemantics:/UDXContrib/CentOS-7_SP5/repodata/repomd.xml.key
  3. On each of the AnzoGraph DB servers, create a directory called /tmp/repo.
  4. Copy csi-obs-cambridgesemantics-udxcontrib.centos7.tar.xz to the /tmp/repo directory on each server.
  5. Then run the following command to unpack the tarball in the /tmp/repo directory:
    tar -xvf csi-obs*.tar.xz

    The files are unpacked into subdirectories under /tmp/repo/dl/centos7/csi-obs-cambridgesemantics-udxcontrib.

  6. Next, copy the repomd.xml.key file to the /tmp/repo/dl/centos7/csi-obs-cambridgesemantics-udxcontrib directory on each of the AnzoGraph DB servers.
  7. Now, open the csi-obs-cambridgesemantics-udxcontrib.repo file in the <install_path>/examples/yum.repos.d directory. The contents of the file are shown below:
    [csi-obs-cambridgesemantics-udxcontrib]
    name=Contrib directory for CambridgeSemantics AnzoGraph UDX dependencies
    baseurl=https://storage.googleapis.com/csi-rpmmd-pd/CambridgeSemantics:/UDXContrib/CentOS-7_SP5
    gpgkey=https://storage.googleapis.com/csi-rpmmd-pd/CambridgeSemantics:/UDXContrib/CentOS-7_SP5/repodata/repomd.xml.key
    gpgcheck=1
    enabled=1
  8. Edit the csi-obs-cambridgesemantics-udxcontrib.repo file contents to replace the baseurl and gpgkey values so that they point to the repo files that you unpacked in the /tmp/repo directory. In addition, change the gpgcheck and enabled values from 1 to 0. The contents of the updated file are shown below:
    [csi-obs-cambridgesemantics-udxcontrib]
    name=Contrib directory for CambridgeSemantics AnzoGraph UDX dependencies
    baseurl=file:///tmp/repo/dl/centos7/csi-obs-cambridgesemantics-udxcontrib
    gpgkey=file:///tmp/repo/dl/centos7/csi-obs-cambridgesemantics-udxcontrib/repomd.xml.key
    gpgcheck=0
    enabled=0
  9. Save and close the file.
  10. Copy csi-obs-cambridgesemantics-udxcontrib.repo from <install_path>/examples/yum.repos.d to the /etc/yum.repos.d directory. For example, the following command copies the file from the default installation path to /etc/yum.repos.d:
    sudo cp /opt/cambridgesemantics/examples/yum.repos.d/csi-obs-cambridgesemantics-udxcontrib.repo /etc/yum.repos.d
  11. Next, run the following command to enable the repository and install the required packages:
    sudo yum install --enablerepo=csi-obs-cambridgesemantics-udxcontrib libarchive13 libarmadillo10 libboost_filesystem1_71_0 libboost_iostreams1_71_0 libboost_system1_71_0 libgrpc++1 libflatbuffers1 libhdfs3 libnfs13 libserd-0-0 libsmb2 shadow-utils

Repeat the steps above as needed to install the dependencies on all servers in the cluster.

Optimize the Linux Kernel Configuration for AnzoGraph

Recommended for both root and non-root Installer deployments. To streamline the configuration of the operating system for peak AnzoGraph DB performance, the installer includes a tunedAnzoGraph DB profile that you can activate. Tuned is a daemon program that uses the udev device monitor to statically and dynamically tune operating system settings based on the specified profile. It is highly recommended that you activate the AnzoGraph DB tuned profile, unless you deploy some other system-wide method of system configuration and tuning for performance.

Numerous web sites such as the Red Hat Customer portal provide more information on the Linux tuned daemon program and how you can use it to define and customize profiles for various use cases. "Tuned" and "Performance Tuning with Tuned and Tuned-ADM" in the RedHat Performance Tuning Guide provide an overview of the tuned daemon and more information on using the tuned service to improve performance of specific workloads.

Activating the Tuned Profile

The profile, called azg, is in the install_path/examples/tuned-profile directory and consists of two files: tuned.conf and additional-tuneables.sh. For details about the files, see Tuned AnzoGraph Profile Reference below.

You need root permissions to copy the AnzoGraph DB profile files to the /etc/tuned directory as well as to activate the tuned profile.

To activate the azg profile, follow the steps below. Complete these steps on all servers in the cluster:

If you ran the Installer with root (sudo) privileges, you only need to complete step 2 below. The Installer copied the tuned profile to the etc/tuned directory but it did not automatically activate the profile.

  1. Copy the azg directory from install_path/examples/tuned-profile to the /etc/tuned directory. For example, the following command copies azg from the default installation path to /etc/tuned:
    sudo cp -r /opt/cambridgesemantics/examples/azg /etc/tuned
  2. Next, run the following command to activate the azg profile:
    sudo tuned-adm profile azg

The host servers are now configured to use the tuned profile that is optimal for AnzoGraph DB.

To disable tuned profiles, you can run the following command:

sudo tuned-adm off

After running the command, no tuned profiles will be active.

Tuned AnzoGraph Profile Reference

This section describes the tuned AnzoGraph DB profile files and the kernel configuration changes that they apply.

tuned.conf

The tuned.conf file optimizes network throughput performance by increasing the number of kernel network buffers and tuning the values for the following Linux kernel configuration settings:

  • vm.dirty_ratio: This setting specifies the percentage of system memory that can be occupied by "dirty" data before flushing the cache to disk. Dirty data are pages in memory that have been updated and do not match what is stored on disk. The AnzoGraph DB tuned profile reduces vm.dirty_ratio to 2% to increase the frequency with which the system cache is flushed.
  • vm.swappiness: This setting controls the tendency of the kernel to move processes out of physical memory and onto the swap disk. A value of 0 means the kernel avoids swapping processes out of physical memory for as long as possible. A value of 100 tells the kernel to aggressively swap processes out of physical memory to the swap disk. The AnzoGraph DB tuned profile sets vm.swappiness to 30.
  • vm.max_map_count: This setting sets the limit on the maximum number of memory map areas a process can use. Since AnzoGraph DB is memory intensive, it may reach the default maximum map count of 65535 and be shut down by the operating system. The tuned profile increases vm.max_map_count to 2097152.
  • transparent_hugepages: This setting controls whether Transparent Huge Pages (THP) is enabled or disabled system-wide. When THP is enabled system-wide, it can dramatically degrade AnzoGraph DB performance. So the AnzoGraph DB tuned profile disables THP by setting transparent_hugepages to never.

additional-tunables.sh

The additional-tuneables.sh script is called by tuned.conf and configures the following settings so that they are optimal for AnzoGraph DB:

  • overcommit_memory: This setting controls whether obvious overcommits of the address space are allowed. The profile sets overcommit_memory to 0 (the default value for the kernel), which ensures that very large overcommits are not allowed but some overcommits can be used to reduce swap usage.
  • overcommit_ratio: This setting controls the percentage of memory that is allowed to be used for overcommits. The tuned profile sets overcommit_ratio to 50% (the default value for the kernel).
  • transparent_hugepage/defrag: Though the AnzoGraph DB tuned profile disables Transparent Huge Pages (THP) system-wide, this setting controls whether huge pages can still be enabled on a per process basis (inside MADV_HUGEPAGE madvise regions). The profile sets transparent_hugepage/defrag to madvise so that the kernel only assigns huge pages to individual process memory regions that are specified with the madvise() system call.
  • tcp_timestamps: This setting controls whether TCP timestamps are enabled or disabled. The profile sets tcp_timestamps to 0, which disables TCP timestamps in order to reduce performance spikes related to timestamp generation.

Set up the AnzoGraph Services

When running the Installer as root (sudo), the Installer automatically creates AnzoGraph DB systemd services in the /etc/systemd/system directory for azgmgrd, anzograph, and jetty (if the front end user interface is installed). In addition, the Installer prompts whether you want to automatically start the services at the end of the installation.

When running the Installer as a non-root user, the Installer does not automatically create systemd services in the /etc/systemd/system directory, but example service files are available in the <install_path>/examples/systemd-services directory for you to customize and enable manually. It is highly recommended that you implement the services because they are configured to tune user resource limits (ulimits) for the AnzoGraph DB process as well as set JAVA_HOME so that AnzoGraph DB can find the OpenJDK installation.

After tailoring the service files to your environment, copy the azgmgrd service file to the /etc/systemd/system directory on each host server (standalone single server or each server in a cluster). The anzograph and jetty services are only installed on the host server in a standalone single server environment or on the leader node in cluster deployment. For additional information about AnzoGraph DB services, see Starting and Stopping AnzoGraph DB.

If you do not employ the AnzoGraph DB systemd services, make sure you manually set $JAVA_HOME to the OpenJDK installation path. If you set up a cluster, set $JAVA_HOME on each server in the cluster.

Where to Go From Here

For next steps on using AnzoGraph DB, see Get Started.

Related Topics