Lets you set up and manage the load profile for the logical cluster.
sp_cluster profile, [ "show" [, profile_name ] | "create", profile_name | "drop", profile_name | "set", profile_name [, weight [, wt_metric [, wt_value ] | threshold [, thr_metric [, thr_value ] ] ]
show – displays configured load profiles and their settings.
profile_name – is the name of a load profile.
creates – creates a new load profile.
drop – drops a load profile.
set – specifies attributes of a load profile. You must set each attribute individually.
weight – specifies a weight attribute.
wt_metric – specifies an individual weight metric. Values are:
user connections – the capacity of an instance to accept a new connection, based on resource availability.
cpu utilization – the capacity of an instance to accept a new connection, based on resource availability.
run queue – the capacity of an instance to accept a new connection, based on resource availability.
io load – outstanding asynchronous I/Os.
engine deficit – the difference in the number of online engines among instances in the cluster.
engine deficit is measurable only
when instances in the cluster have unequal numbers of engines. engine
deficit adds a metric for maximum relative capacity to
the load score.
user metric – an optional, user-supplied metric.
wt_value – specifies a weight value. Valid values are 0 to 255. A weight of zero (0) excludes the metric from calculation.
threshold – specifies a threshold attribute.
thr_metric – specifies a particular threshold attribute. Values are:
dynamic – specifies a threshold for dynamic load distribution.
login – specifies a threshold for login redirection
hysteresis – specifies a minimum load score for any connection redirection.
thr_value – depends on value of thr_metric:
When thr_metric is dynamic or login, thr_value is the percentage difference between the the load scores of two instances. Valid values are 0 to 100. A weight of zero (0) disables this form of load distribution.
When thr_metric is hysteresis, thr_value is the minimum load score for the target instance that must be met before dynamic load distribution or login redirection can occur.
The user metric value must be normalized so that it is compatible with values for metrics provided by Sybase. Consider a user metric that measures response times. If the maximum acceptable response time is 10 seconds and the measured value is 5, the metric value is 50 (5/10 x 100 = 50).
Threshold metrics let you configure at what point a load imbalance should cause connections to be redirected from one instance to another. The workload manager redirects connections when the load score difference (as a percent) between the target instance and the least loaded instance meets or exceeds the threshold value.
The hysteresis value guards against redirection when the load score difference meets the threshold value, but the instance load scores (for example, 2 and 8) are so low that redirection is not appropriate.
Example 1 Creates the load profile “my_profile”:
sp_cluster profile, "create", my_profile
Example 2 Specifies the metric weights for “my_profile.” “user connections” is set to zero, which excludes that metric from the profile.
sp_cluster profile, "set", my_profile, weight, "user connections", '0' sp_cluster profile, "set", my_profile, weight, cpu utilization, '20' sp_cluster profile, "set", my_profile, weight, runqueue, '30' sp_cluster profile, "set", my_profile, weight, io load, '10' sp_cluster profile, "set", my_profile, weight, engine deficit, '10' sp_cluster profile, "set", my_profile, weight, user metric, '30'
See “Using Monitoring Tables in a Clustered Environment.”
Example 3 Sets the login redirection threshold to 80 and the hysteresis value to 10 for “my_profile.”
sp_cluster profile, "set", my_profile, threshold, login, '80' sp_cluster profile, "set", my_profile, threshold, hysteresis, '10'
Example 4 Displays information about a configured profile.
sp_cluster profile, "show", my_profile
ID Profile Type Connections CPU Run Queue ------------- ------------------------- ------- ------------- --- ------------- --------- -------- ------ ------- ------ --------- 100 my_profile user 0 20 30 10 10 30 30 0 20 Profile Logical Cluster ------------------------- -------------- my_profile SalesLC
Profile Logical Cluster Instance Load Score Connections Score CPU Score Run Queue Score IO Load Score User Score ---------------------------------- -------------------- ----------- ------------------------------------ ------------------------------ ------------------------------------ ------------------------------ ------------------------------------ ------------------------------ ---------------------------------- my_profile SalesLC ase1 0.028871 0.000000 0.028871 0.000000 0.000000 0.000000 0.000000 my_profile ase2 0.029474 0.000000 0.029474 0.000000 0.000000 0.000000 0.000000 my_profile ase3 0.019503 0.000000 0.019503 0.000000 0.000000 0.000000 0.000000 my_profile ase4 0.582675 0.000000 0.290930 0.291745 0.000000 0.000000 0.000000