An engine definition pairs a Postgres server type with the server image on which it will reside. Only an EDB Ark administrative user can define an engine. Once defined, all of the engines that reside within a specific tenant will be made available to all users with access to that tenant. You can use the DB Engine Administration section of the Admin tab to create and manage database engines (see Figure 4.15).Ark 2.2 ships with a number of default engine definitions. Before using an engine, you must create servers (see Section 4.1.2) and edit the engine details, associating a server with the engine you wish to use and enabling the engine.The following engines are shipped with Ark 2.2. Please note that Advanced Server engine definitions must specify multiple repositories to provide access to all of the packages required to complete the installation. Advanced Server repositories require you to provide a USERNAME and associated PASSWORD; to request a username and password for a repository, visitRepository Location:
postgresql94-server pgpool-II-94Repository Location:
postgresql94-server pgpool-II-94Repository Locations:
ppas94-server ppas-pgpool34 ppas95-pgpool34-extensionsRepository Location:
postgresql95-server pgpool-II-95Repository Location:
postgresql95-server pgpool-II-95Repository Locations: http://USERNAME:PASSWORD@yum.enterprisedb.com/9.5/redhat/rhel-$releasever-$basearch
ppas95-server ppas-pgpool34 ppas95-pgpool34-extensionsRepository Location:
postgresql96-server pgpool-II-96Repository Location:
postgresql96-server pgpool-II-96Repository Locations: http://USERNAME:PASSWORD@yum.enterprisedb.com/9.6/redhat/rhel-$releasever-$basearch
edb-as96-server edb-pgpool35 edb-as96-pgpool35-extensionsUse the Add Engine dialog (see Figure 4.16) to define an engine. To access the Add Engine dialog, connect to the Ark console as a user with administrative privileges, navigate to the Admin tab, and select Add Engine.Use the fields on the Add Engine dialog to define a new server image/database pairing:
• Use the ID field to provide an identifier for the engine. Please note that the identifier must be unique, and may not be modified after saving the engine.
• Use the drop-down listbox in the DB Type field to select the type of database used in the pairing.
• Use the drop-down listbox in the Version field to specify the server version.
• Use the Name field to provide a name for the pairing. When the engine is enabled, the specified name will be included for use on the Create Cluster dialog.
• Use the drop-down listbox in the Server Type field to specify the server image on which the database will reside. The drop-down listbox displays those images previously defined on the Add Server dialog.
• Use the drop-down listbox in the RHEL Subscription field to select the Red Hat Subscription Manager service that will be used by the engine. To populate the RHEL Subscription drop-down, describe your subscription services in the RHEL Subscription Management section of the Admin tab. RHEL Subscription Manager services are only applicable for RHEL 7 clusters.Please note that you must delete any instances that use an engine that is associated with a RHEL subscription before you can delete the RHEL subscription.
• Use the Yum repo URL field to provide the URL of the yum repository that will be used to initially provision database packages and to later update the database packages during cluster upgrade operations.http://[user_name[:password]@]repository_urluser_name specifies the name of a user with sufficient privileges to access the repository.password specifies the password associated with the repository user. Please note that if your password contains special characters (such as a $), you may need to percent-encode the characters.repository_url specifies the URL of the repository.Please contact your EnterpriseDB account manager for connection credentials (the values specified in the user_name and password placeholders) for the EnterpriseDB repositories.When specifying multiple repositories in the Yum repo URL field, specify one repository per line. When you perform an update, any available updates in all of the specified repositories will be applied.
• Use the Required DB Packages field to provide a space-delimited list of packages that have been tested by EDB as the required minimum set to build a functional cluster instance.When defining a database engine, you must specify the required package list for the installation in the Required DB packages field on the Edit Engine Details dialog.
• Use the Optional Node Packages field to provide the names of any packages that should be installed (from the specified repository) on every cluster node during provisioning.Please note: packages added via the Optional Node Packages field on the master node of the cluster will also be provisioned on any standby nodes that are subsequently created. If the package requires manual configuration steps, you will be required to repeat those steps on each node of the cluster; package configurations will not be propagated to standby nodes. If you add a node through cluster operations (such as failover, scaling, or restoring a node from backup), any packages on the new node will require manual configuration.When you have completed the dialog, click Save to create the engine definition, or Cancel to exit without saving.For information about using the EnterpriseDB repository, and the Advanced Server packages available, please see the EDB Postgres Advanced Server Installation Guide, available at:To modify an engine, use the Edit Engine Details button to open the Edit Engine Details dialog (see Figure 4.17).Use fields on the Edit Engine dialog to specify property changes to an engine. When you’re finished, click the Save button to make the changes persistent and exit, or Cancel to exit without saving.You can use the disabled box to specify that an engine is (or is not) available for use in new clusters without removing the engine definition:Click the Save button to make any changes to the Edit Engine Details dialog persistent, or select Cancel to exit without modifying the engine definition.Please note that disabling an engine has no impact on any running clusters; it simple prevents users from creating new clusters with the engine. You can use this feature to phase out the use of older engines.To delete an engine, highlight an engine name in the DB Engine Administration list, and select the Delete Engine button. A dialog will open, asking you to confirm that you wish to delete the selected engine (see Figure 4.18).Click the Delete button to remove the engine definition, or select Cancel to exit without removing the engine definition.Please note that you cannot remove an engine that is referenced by one or more clusters and/or backups; if you attempt to remove an engine that is in use, EDB Ark will display the warning shown in Figure 4.19.When you create a cluster, you select the engine that EDB Ark will use when provisioning the cluster. If you modify the engine description, adding the list of RPM packages that will be installed when that engine is provisioned, each node of any cluster provisioned with that engine will include the functionality of the supporting component.To simplify PostGIS installation, add a list of the required RPM packages to the Optional Node Packages field of the Edit Engine Details dialog (see Figure 4.20). To provision replicas that contain the PostGIS functions, perform the installation and create the extensions on the master node of the cluster before adding replica nodes to your cluster.To modify an engine description, use Administrator credentials to connect to the Ark console, and navigate to the Admin tab. Select an engine ID from the list of engines in the DB Engine Administration list, and click Edit Engine Details.When the Edit Engine Details dialog opens (see Figure 4.21), use the fields on the dialog to specify the repository information and the names of optional RPM packages that the installer should provision on each node of the cluster.
• The PostGIS RPM packages are distributed from the enterprisedb tools repository; by default, the enterprisedb tools repository is included in the Yum Repo URL field.
• Add the names of the PostGIS RPM packages to the Optional Node Packages field on the Edit Engine Details dialog.Any EDB Ark clusters that are subsequently provisioned with that engine will automatically include an installation of the PostGIS on all nodes of the cluster (see Figure 4.22).For detailed information about creating a new server cluster, please see the EDB Ark Getting Started Guide, available through the EDB Ark Dashboard tab.After adding the packages to the master node of a cluster, you can use the psql client or the EDB Postgres Enterprise Manager (PEM) client to create the extensions. Before connecting with a client, an Administrator must open the listener port (by default, 5444 on an Advanced Server instance) of the node for connections.Use a client to connect to the database in which you wish to create the extensions, and enter the following commands:CREATE EXTENSION postgis;
CREATE EXTENSION fuzzystrmatch;
CREATE EXTENSION postgis_topology;
CREATE EXTENSION postgis_tiger_geocoder;The client will confirm that the extensions have been created successfully. The PostGIS functions are created in the public schema of the database.The PEM agent is responsible for executing tasks and reporting statistics from a monitored Postgres instance to the PEM server. The PEM agent can be installed with an RPM package; if you have administrative access to the Ark console, you can configure the console to automatically install the PEM agent on Master and Standby nodes when provisioning a cluster.After installing the PEM agent, the agent must be registered on each node that will be monitored by the PEM server. The steps that follow detail installing a PEM agent on an EDB Ark cluster, registering the agent with the server, and configuring the server to monitor the agent.You must be an EDB Ark Administrative user to modify an engine description. Using Administrative credentials, connect to the Ark console, and navigate to the Admin tab. Select an engine ID from the list of engines in the DB Engine Administration list, and click Edit Engine Details. The Edit Engine Details dialog opens (see Figure 4.24).The name of the package that installs the PEM agent is named pem-agent. The package is distributed from the enterprisedb tools repository; by default, the enterprisedb tools repository is included in the Yum Repo URL field.Add the name of the PEM agent RPM package (pem-agent) to the Optional Node Packages field on the Edit Engine Details dialog. Any EDB Ark clusters that are subsequently provisioned with that engine will automatically include an installation of the PEM agent on all nodes of the cluster. Please note that before monitoring a node, you must:
• modify the pg_hba.conf file on the node hosting the server to allow connections from any monitored node.
• modify the pg_hba.conf file on any monitored node, allowing connections from the PEM server.For more information about administrative features of the EDB Ark console, please see the EDB Ark Administrator's Guide, available through the EDB Ark Dashboard tab.Navigate to the Clusters tab, and create a new cluster that is provisioned using the engine definition modified in Step 1 (see Figure 4.25). As the cluster spins up, each node of the cluster will include the pem-agent RPM package.For detailed information about creating a new server cluster, please see the EDB Ark Getting Started Guide, available through the EDB Ark Dashboard tab.
Please note: by default, a replica node on an OpenStack host does not have a public IP address. After creating the cluster, you must manually assign a public IP address to each node you wish to monitor with PEM. For more information, please see:The PEM server consists of an instance of PostgreSQL, an associated PostgreSQL database for storage of monitoring data, and a server that provides web services for the PEM client. The PEM server may reside on a host outside of a monitored EDB Ark cluster, or on the master node of an Ark cluster.Before a PEM agent that resides on an Ark cluster can communicate with the PEM server, you must modify the pg_hba.conf file (see Figure 4.26) of the PostgreSQL database that stores PEM statistics to allow connections from any monitored servers as well as the PEM client.With your choice of editor, modify the pg_hba.conf file (located by default in the data directory under the PostgreSQL installation), adding entries for the IP address of the EDB Ark cluster. The connection properties should allow connections that use cert and md5 authentication.For detailed information about modifying the pg_hba.conf file, please see the PostgreSQL documentation, available from the EnterpriseDB website at:After modifying the pg_hba.conf file for the PostgreSQL installation that stores statistical information for PEM, you must restart the PEM backing database server to apply the changes. The name of the PEM service is:Where x specifies the version. For example:Use the Download SSH Key icon on the Clusters tab to download the SSH key for your cluster. When you download the key, a popup will open, informing you of the steps required to connect to the master node of your cluster (see Figure 4.27).Open a terminal window, modify the permissions on the downloaded file, and use the command shown on the popup to establish a connection with the server.Use your choice of editor to modify the pg_hba.conf file on the Ark node. By default, the pg_hba.conf file is located in /var/lib/ppas/9.5/data.Add entries to the pg_hba.conf file that allow connections from the PEM server (see Figure 4.28).After modifying the pg_hba.conf file, you must restart the server to apply the changes. The name of the service is Arkdb. Use the platform and version specific command for your cluster to restart the Arkdb service.You must register each PEM agent that resides in an Ark cluster with the PEM server. Using the SSH connection to the cluster node on which the agent resides, navigate into the directory that contains the PEM agent installation:PGPASSWORD=password ./pemagent --register-agent --pem-server x.x.x.x --pem-port port --pem-user user_namex.x.x.x specifies the IP address of the PEM server.port specifies the port on which the server is listening for connectionsuser_name specifies the name of the PEM user.After registering the agent, use the following command to ensure that the service is configured to restart when if the node restarts, and that the pemagent service is running:For more information about Postgres Enterprise Manager, and to download PEM documentation, please visit the EnterpriseDB website at:You can use the Ark Administrative console to attach Red Hat Subscription Manager information to engines hosted on Red Hat consoles. The Red Hat Subscription Manager tracks installed products and subscriptions to implement content management with tools like yum. For information about Red Hat Subscription Manager, visit the Red Hat website at:When you create a new cluster that uses an engine that is associated with a Red Hat subscription, Ark registers the cluster nodes with Red Hat; when you terminate the node, the system's subcription is unregistered.Use the RHEL Subscription Management section of the Admin tab to define and manage Red Hat Subscription Manager access for your Ark consoles that reside on Red Hat Linux instances (see Figure 4.30).After creating a subscription definition, use options in the DB Engine Administration section of the Admin tab to associate the definition with database engines.Use fields on the Add RHEL Subscription dialog (see Figure 4.31) to describe a Red Hat subscription service:
• Use the Subscription Id field to provide a user-friendly name for the subscription. The name will identify the subscription in the RHEL Subscription drop-down on the Add Engine Details dialog.
• Use the Username field to provide the name of the user account registered with the Red Hat content server.
• Use the Password field to provide the password associated with the user account.
• Use the Server Url field to provide the host name of the subscription server used by the service; if left blank, the default value of subscription.rhn.redhat.com will be used.
• Use the Base Url field to provide the host name of the content delivery server used by the service; if left blank, the default value of https://cdn.redhat.com will be used.
• Use the Org field to provide the organization that will be registered with the Red Hat subscription system.
• Use the Environment field to provide the name of the environment (within the organization that will be registered).
• Use the Name field to provide the name of the system that will be registered.
• Use the Activation Key field to provide the activation key of the Red Hat subscription.
• If enabled, use the Auto-attach checkbox to instruct any node associated with the subscription to automatically attach to the service.
• If applicable, use the Pool field to provide the pool identifier for the Red Hat subscription service.
• If applicable, check the Auto checkbox to indicate that nodes provisioned with engines associated with the pool will automatically attach to the subscription service.
• If applicable, use the Quantity field to provide the number of subscriptions in the subscription pool.
• Use the Service Level field to provide the service level of the subscription.
• Use the Release field to provide the operating system minor release that will be used when identifying updates to any nodes provisioned with the subscription.
• Check the Force checkbox to indicate that the node should be registered, even if it is already registered.
• Use the Type field to specify the type of consumer that is being registered; the default is system.
• The Required Repos list is populated by the Ark console, and displays a list of the repositories required by the subscription definition.
• Use the Additional Repos field to provide the names of any additional repositories that should be enabled on the cluster node(s).
• Use the Disabled Repos field to provide the names of any repositories that should be disabled on the cluster node(s).When you've completed the dialog, click the Save button to add the repository to the table in the RHEL Subscription Management section, or Cancel to exit without saving. If you choose to save the definition, the Ark console will display a popup that lists the subscription manager commands that were generated as a result of your selections (see Figure 4.32).After creating a subscription definition, use options in the DB Engine Administration section of the Admin tab to associate the definition with database engines; see Section 4.1.3 for detailed information.To modify the description of a Red Hat Subscription Manager service, highlight the name of a subscription in the RHEL Subscription Management table, and click the Edit RHEL Subscription button. The Edit RHEL Subscription Details dialog opens, allowing you to modify the subscription definition.After modifying the subscription definition, click Save to preserve your changes and exit the dialog; to exit without saving, click the Cancel button. Please note that changes made to a definition are applied only to those instances that are created after the changes are saved; changes are not propagated to existing instances.
• Then, to delete a Red Hat Subscription Manager service from the list in the Ark console, highlight the name of a service and click the Delete RHEL Subscription button.Click the Delete button to confirm that you wish to delete the subscription definition, or Cancel to exit without deleting the definition (see Figure 4.33).4.1.5 User AdministrationOptions in the User Administration section of the Admin tab allow an administrative user to access a list of connected users or to display a message to all connected users (see Figure 4.34).Click the Show logged in users button to display the Logged in users dialog (see Figure 4.35).
• When you’re finished reviewing the list, use the X in the upper-right corner of the popup to close the dialog.Provide a message in the Message field (shown in Figure 4.36) and click the Display Message button to add an announcement to the top of the user console. A message may include HTML tags to control the displayed format, and will wrap if the message exceeds the width of the screen.The console may take a few seconds to refresh. Once processed by the server, the message will be displayed to console users when their screens refresh (see Figure 4.37).Use the Remove Message button to remove the banner. Please note that the wall banner content is stored in the console database, and will persist after a server restart; you must use the Remove Message button to remove a banner.If your console resides on an Amazon AMI, the Ark administrative console provides a user management interface that allows you to:A table with detailed information about each user is displayed in the User Administration section of the Admin tab (see Figure 4.38).
• The user's login name is displayed in the ID column.
• The user's first name is displayed in the FIRST NAME column.
• The user's last name is displayed in the LAST NAME column.
• If the user has administrative access to the console, the ADMIN column displays a blue check mark.
• If the user account is currently active (the user can log in), the ENABLED column displays a blue check mark.
• The number of cluster snapshots owned by the user is displayed in the SNAPSHOTS column.
• The date and time of the last login is displayed in the LAST LOGIN column. The time zone displayed is based on the time zone used by the operating system.
• The LOGINS column displays a cumulative total of the number of times that the user has logged in.Use the buttons below the AWS user table to manage user accounts for the AWS console and user-owned objects.Click the Add User button to access the Add User dialog (see Figure 4.39) and create a new user account for the current console.
• Use the Login field to provide the identifier that the user will provide when logging in to the console; each identifier must be unique.
• Provide the user's first name in the First Name field.
• Provide the user's last name in the Last Name field.
• Check the box next to Enabled if the user should be allowed to log in to the console.
• Provide a password associated with the user account in the Password field.
• Confirm the password in the Verify Password field.
• Select a previously defined Amazon role ARN from the drop-down list in the Role field, or copy a different role ARN into the field. The role ARN must be defined on the AWS console by an Amazon administrator. Each role will be able to access all clusters that are created by users that share the common role ARN. To create an isolated user environment, a user must have a unique Amazon role ARN.If you copy an Amazon role ARN into the Role field, a popup will open, prompting you for the AWS ExternalId associated with the user. To locate the ExternalId, connect to the Amazon management console, and navigate to the IAM Roles page. Select the role name from the list, and then click Trust Relationships tab. The ExternalId associated with the Role ARN is displayed in the Conditions section of the Summary page.Click the Edit User button to open a dialog that allows you to modify user properties for the user that is currently highlighted in the user table (see Figure 4.40).If the backing host of your Ark console is Amazon AWS, you can use features on the Admin tab to delete objects that belong to a user, and the user account. Highlight a user name in the User Administration table, and click:
• The Delete Clusters button to delete all clusters that belong to the selected user.
• The Delete Snapshots button to delete any cluster backups that belong to the selected user.
• The Delete Keypair button to delete the SSH keypair associated with the selected user account.After deleting the objects owned by a user, you can use the Delete User button to remove the user account. To delete a user, highlight the name of a user in the user table, and click the Delete User button.The Ark console will open a popup, asking you to confirm that you wish to delete the selected user (see Figure 4.41). Click Delete to remove the user account, or Cancel to exit the popup without deleting the account.Use the Download button in the Download Console Logs panel of the Admin tab to download a zip file that contains the server logs for the underlying application server. You can confirm changes to server status or verify server activity by reviewing the application server log file (see Figure 4.42).When the server.log file fills, EDB Ark attaches a unique identifier to the file name, and rotates the file into storage. You can use the Linux tail utility (shown in Figure 4.43) to display the most recent entries in any of the server logs. For example, to review the last 10 lines in the server log file, connect to the console host with ssh and enter:tail file_nameWhere file_name specifies the complete path to the log file.You can include the -F option to instruct the tail utility to display the last 10 lines of the log file, and new log file entries as they are added to the file:tail -F file_nameThe tail utility will continue to display new log file entries if the server log rotates to a new file. Enter Ctrl-C to exit tail and return to the command prompt.To review the tail command options, enter the command:Use the option displayed in the Edit Installation Properties section to access and modify Ark console properties (see Figure 4.44).Click the Edit installation properties button to open the Edit Installation Properties dialog (see Figure 4.45). Use fields on the Edit Installation Properties dialog to modify the properties of the Ark console. For detailed descriptions of each field:When you've finished, click Save to preserve your changes and restart the console server, or Cancel to exit the dialog without saving the changes.