> # Configuring SequeLink® Services

> This section describes how to create and manage SequeLink services locally on z/OS.

> To do this... | See...
> --- | ---
> Create a SequeLink service | "Creating a SequeLink® Service"
> Delete a SequeLink service | "Deleting a SequeLink® Service"
> View service attributes | "Viewing SequeLink® Service Attributes"
> Change a service attribute | "Changing a SequeLink® Service Attribute"
> Add a service attribute | "Adding a SequeLink® Service Attribute"
> Delete a service attribute | "Deleting a SequeLink® Service Attribute"
> Configure monitoring | "Configuring Monitoring"
> Configure event tracing | "Configuring Event Tracing"

> ### Creating a SequeLink® Service

> NOTE: You can create only one service for any SequeLink Server. Usually, you will be prompted to create a service while you are creating a SequeLink Server. You can also create or recreate a service after you delete an existing service.

> To create a SequeLink service:

> 1. Type `A` beside the SequeLink Services node to add a service to the SequeLink Server; then, press ENTER.
> 2. The Add service panel or Add DB2 Interface panel appears. Complete the panel as described in "Creating a SequeLink® Server".

> See "Changing a SequeLink® Service Attribute" for instructions on changing SequeLink service attributes.

> NOTE: You must restart the SequeLink Server before this change will take effect.

> ### Deleting a SequeLink® Service

> 1. From the server management tree, type `D` beside the SequeLink service you want to delete; then, press ENTER. The Delete Service panel appears, prompting you to confirm the deletion of the SequeLink service.

> 2. Confirm or cancel the deletion:
> - Type `1` to confirm the deletion; then, press ENTER
> - Type `2` to cancel the deletion; then, press ENTER.

> The SequeLink service is deleted, and you are returned to the server management tree.

> NOTE: Create a new service before restarting the SequeLink Server.

> ### Viewing SequeLink® Service Attributes

> 1. From the server management tree, type `/` beside the Service Settings node of the SequeLink service to expand it. The server management tree shows the attribute categories for the service.
> 2. Type `S` beside the attribute category for which you want to view attributes; then, press ENTER. The AttributeList panel appears for that category, listing all the attributes and their values.

> For example, if you select the Logging category, the following AttributeList panel appears:

> For information about:

> - Changing the value of an attribute, see "Changing a SequeLink® Service Attribute".
> - Adding attributes, see "Adding a SequeLink® Service Attribute".
> - Deleting an attribute, see "Deleting a SequeLink® Service Attribute".

> NOTE: To display help about an attribute, type `?` beside the attribute; then, press ENTER.

> ### Changing a SequeLink® Service Attribute

> 1. From the server management tree, type `/` beside the Service Settings node of a SequeLink service to expand it. The server management tree shows the attribute categories for the service.
> 2. Type `S` beside an attribute category to select it; then, press ENTER. The AttributeList panel appears for that category, listing all the attributes and their values.

> For example, if you select the Logging attribute category, the following AttributeList panel appears:

> NOTE: To display help about an attribute, type `?` beside the attribute; then, press ENTER.

> 3. Type `C` beside the attribute you want to change; then, press ENTER. The Attribute Display panel appears with the cursor positioned at the value field of the attribute.

> For example, to change the value of the ServiceDebugLogLevel attribute to 4 (Debug), the following Attribute Display panel appears:

> 4. Type the new value of the attribute; then, press ENTER. You are returned to the AttributeList panel, and the attribute value, if valid, is changed.
> 5. Press F3 to return to the server management tree.

> ### Adding a SequeLink® Service Attribute

> 1. From the server management tree, type `/` beside the Service Settings node of the SequeLink service to expand it. The server management tree shows the attribute categories for the service.
> 2. Type `S` beside the attribute category to select it; then, press ENTER. The AttributeList panel appears for that category, listing all the attributes and their values.

> For example, if you select the Logging category, the following AttributeList panel appears:

> 3. Type `Add` at the command prompt to add an attribute; then, press ENTER. A panel appears listing the attributes you are allowed for that category.

> For example, to add an attribute to the Logging category, the following panel appears:

> NOTE: To display help about an attribute, type `?` beside the attribute; then, press ENTER.

> 4. Type `S` beside the attribute you want to add; then, press ENTER. The Attribute Display panel appears with the cursor positioned at the value field of the attribute.

> NOTE: When you add an attribute, the Value field will display the default value, if a default exists for the attribute. To accept the default, press ENTER.

> For example, to add the ServiceEventTraceSize attribute, the following Attribute Value panel appears:

> 5. Type a value for the attribute or use the default if one is available; then, press ENTER.
> 6. You are returned to the AttributeList panel. Press F3 to return to the server management tree.

> ### Deleting a SequeLink® Service Attribute

> 1. From the server management tree, type `/` beside the Service Settings node of the SequeLink service to expand it. The server management tree shows the attribute categories for the service.
> 2. Type `S` beside the attribute category to select it; then, press ENTER. The AttributeList panel appears for that category, listing all the attributes and their values.

> For example, if you select the Logging category, the following AttributeList panel appears:

> 3. Type `D` beside the attribute you want to delete; then, press ENTER. The attribute is deleted.

> ### Configuring Monitoring

> SequeLink provides the following levels of monitoring for SequeLink data access services, listed here from highest-level to lowest-level. Some of the monitoring levels are also supported for the SequeLink Agent service.

> - Service monitoring monitors these activities by service:
> - Statistics of received packets and sent packets
> - Sessions started and statements opened
> - Active statements and sessions
> - Fetched rows and affected rows
> - Transactions
> - Session monitoring monitors these activities by session within a service:
> - Statistics of received packets and sent packets
> - Statements opened and active statements
> - Fetched rows and affected rows
> - Transactions
> - Information about each session, such as start time, client information (network address, data source used by the client, and type of client), native database session identification, and database user
> - Statement monitoring monitors these activities by statement within a session:
> - Fetched rows and affected rows
> - SQL statements issued

> To enable monitoring at one of the listed levels, higher-level monitoring must be enabled. For example, you cannot monitor Session information unless Service monitoring is enabled. Similarly, you cannot monitor Statement information unless both Service monitoring and Session monitoring are enabled.

> See "Managing Data Access Activity Using the SequeLink® Manager Snap-in" for information about using the SequeLink Manager Snap-in to monitor SequeLink service activity.

> To configure monitoring locally on the z/OS:

> 1. From the server management tree of the SequeLink Server, type `/` beside Configuration node of the SequeLink service for which you want to turn on monitoring; then, press ENTER.
> 2. Type `/` beside the Profiles node to expand it, if necessary; then, press ENTER.

> The Profiles node lists all monitoring and event tracing profiles enabled for the SequeLink service. You can perform the following actions:

> - To add a profile, see "Creating a Monitoring Profile".
> - To change a profile, see "Changing a Monitoring Profile".
> - To delete a profile, see "Deleting a Monitoring Profile".

> #### Creating a Monitoring Profile

> 1. Type `A` beside the Profiles node to add a profile to the SequeLink service; then, press ENTER. The Add Profile panel appears prompting you to select the type of profile to add.

> 2. Type `1` to add a monitoring profile; then, press ENTER. The Monitor Profile panel appears.

> 3. Type `/` beside an option to enable it or clear the `/` to disable an option. When you are satisfied with your settings, press F3. You are returned to the server management tree.
> 4. Restart the SequeLink Server to activate the profile you just created.

> #### Changing a Monitoring Profile

> 1. From the server management tree, type `S` beside the profile you want to change; then, press ENTER. The Monitor Profile panel appears.

> 2. Type `/` beside an option to enable it or clear the `/` to disable an option. When you are satisfied with your settings, press ENTER.
> 3. Restart the SequeLink Server to activate the monitoring profile you just changed.

> #### Deleting a Monitoring Profile

> 1. From the server management tree, type `D` beside the profile you want to delete; then, press ENTER. The profile is deleted.
> 2. Restart the SequeLink Server.

> ### Configuring Event Tracing

> Events are generated when the client application accesses data and when specific server activities occur, such as when a service starts or an error occurs. Depending on which SequeLink profiles are active, the information generated by the event is displayed as it occurs in the runtime monitor and is stored persistent in the event trace file.

> On z/OS, the event trace file must be created using the EVLDEF member from the server's CNTL library.

> See "Managing Data Access Activity Using the SequeLink® Manager Snap-in" for information about using the SequeLink Manager Snap-in for event tracing.

> To configure event tracing locally on the z/OS:

> 1. From the server management tree, type `/` beside Configuration node of the SequeLink service for which you want to turn on monitoring; then, press ENTER.
> 2. Type `/` beside the Profiles node to expand it, if necessary; then, press ENTER.

> The Profiles node lists all monitoring and event tracing profiles enabled for the SequeLink service. You can perform the following actions:

> - To add a profile, see "Creating an Event Trace Profile".
> - To change a profile, see "Changing an Event Trace Profile".
> - To delete a profile, see "Deleting an Event Trace Profile".

> #### Creating an Event Trace Profile

> 1. From the server management tree, type `A` beside the Profiles node to add a profile to the SequeLink service; then, press ENTER. The Add Profile panel appears prompting you to select the type of profile you want to add.

> 2. Type `2` to add an event tracing profile; then, press ENTER. The Event Trace Profile panel appears, listing the event tracing options available.

> 3. Type `/` beside an option to enable it or clear the `/` to disable an option. When you are satisfied with your settings, press F3.

> NOTE: Optionally, you can type `F` beside an event trace option to define a filter for the option. A panel appears allowing you to set the filter for that event trace option. Type the filter; then, press ENTER. See "Filtering Events" for more information about filtering and the syntax of filter statements.

> You are returned to the server management tree.

> 4. Restart the SequeLink Server to activate the profile you just created.

> #### Changing an Event Trace Profile

> 1. From the server management tree, type `S` beside the profile you want to change; then, press ENTER. The Event Trace Profile panel appears.

> 2. Type `/` beside an event trace option to enable it or disable it; then, press ENTER.

> NOTE: Optionally, you can type `F` beside an event trace option to define a filter for the option. A panel appears allowing you to set the filter for that event trace option. Type the filter; then, press ENTER. See "Filtering Events" for more information about filtering and the syntax of filter statements.

> You are returned to the server management tree.

> 3. Restart the SequeLink Server to activate the profile you just changed.

> #### Deleting an Event Trace Profile

> 1. From the server management tree, type `D` beside the profile you want to delete; then, press ENTER. The profile is deleted.
> 2. Restart the SequeLink Server.