8 Tuning systems with saptune
#
This chapter presents information about tuning SUSE Linux Enterprise Server for SAP Applications to work optimally with SAP applications.
Using saptune
, you can tune a system for SAP NetWeaver, SAP HANA/SAP BusinessObjects, and
SAP S/4HANA applications.
This chapter describes saptune
version 3 which does not use
tuned
anymore.
8.1 Enabling saptune
#
To enable saptune
to tune an SAP application, use the following
procedure:
To tune a system, first find a tuning solution. To find the appropriate solution, use:
>
saptune solution list
saptune
recognizes the following tuning solutions (groups of SAP Notes):BOBJ
. Solution for running SAP BusinessObjects.HANA
. Solution for running an SAP HANA database.MAXDB
. Solution for running an SAP MaxDB database.NETWEAVER
. Solution for running SAP NetWeaver application servers.S4HANA-APPSERVER
. Solution for running SAP S/4HANA application servers.S4HANA-APP+DB
. Solution for running both SAP S/4HANA application servers and SAP HANA on the same host.S4HANA-DBSERVER
. Solution for running the SAP HANA database of an SAP S/4HANA installation.SAP-ASE
. Solution for running an SAP Adaptive Server Enterprise database.NETWEAVER+HANA
. Solution for running both SAP application servers and SAP HANA on the same host.NETWEAVER+MAXDB
. Solution for running both SAP application servers and MAXDB on the same host.
Alternatively, you can tune the computer according to recommendations from specific SAP Notes. A list of notes that you can tune for is available via:
#
saptune note list
To set up
saptune
with a preconfigured solution, use:#
saptune solution apply SOLUTION
To set up
saptune
for the recommendations of a specific SAP Note, use:#
saptune note apply NOTE
To start
saptune
and enable it at boot, make sure to run the following command:#
saptune service enablestart
To make sure that
sapconf
andtuned
are stopped and disabled too, run instead:#
saptune service takeover
It is possible to combine solutions and notes. However, only one solution can be active at a time. In rare cases, notes can have conflicting options or parameters. Arrange your notes carefully to avoid conflicts. The last note always takes priority over conflicting options or parameters of previous notes.
8.2 Disabling saptune
#
To disable and stop saptune
, run:
#
saptune service disablestop
8.3 Updating saptune
#
To update saptune to a new version, just update the package.
Since a package update can contain updates of SAP Notes and SAP Solutions,
restart saptune
with saptune service restart
to re-apply
the tuning. Check afterwards with saptune note verify
if all recommendations are still met.
The saptune
tool does not rely on tuned
anymore.
Configuring tuned
to set up saptune
3 will not work.
To start and enable saptune
3 use one of the following methods:
saptune service enablestart
Enables and starts the
saptune.service
.saptune service takeover
Enables and starts the
saptune.service
and also disablessapconf
as well astuned
.saptune daemon start
Deprecated. Gets redirected to
saptune
service takeover.
8.4 Managing SAP Notes #
In the following sections you will learn how to create, delete, and rename SAP Notes and much more.
8.4.1 Customizing an SAP Note #
Every SAP Note can be configured freely with:
#
saptune note customise NOTE
The command includes changing a value or disabling a parameter.
8.4.2 Creating a new SAP Note #
It is possible to create a new SAP Note with:
#
saptune note create NOTE
All features of saptune
are available.
8.4.3 Deleting an SAP Note #
The following command deletes a created note, including the corresponding override file, if available:
#
saptune note delete test
Note to delete is a customer/vendor specific Note. Do you really want to delete this Note (test2)? [y/n]: y
The note may not be applied at the time. Keep in mind the following points:
A confirmation is needed to finish the action.
Internal SAP Notes shipped by
saptune
cannot be deleted. Instead, the override file is removed when available.If the note is already applied, the command is terminated with the information that the note first needs to be reverted before it can be deleted.
8.4.4 Renaming an SAP Note #
This command allows renaming a created note to a new name. If a corresponding override file is available, this file is renamed, too:
#
saptune note rename test test2
Note to rename is a customer/vendor specific Note. Do you really want to rename this Note (test) to the new name 'test2'? [y/n]: y
The note may not be applied at the time. Keep in mind the following points:
A confirmation is needed to finish the action.
Internal SAP Notes shipped by
saptune
cannot be renamed.If the note is already applied, the command is terminated with the information that the note first needs to be reverted before it can be deleted.
8.4.5 Showing the configuration of an SAP Note #
The shipped configuration of a note can be listed with:
#
saptune note show NOTE
8.4.6 Verifying an SAP Note or an SAP Solution #
The commands saptune note verify
NOTE
and saptune solution
verify SOLUTION
list the following
data for each active or requested note:
The parameter name
The expected value (default)
A configured override (created using
saptune customise
)The current system value
Whether the current state follows the SAP recommendation
8.4.7 Simulating the application of an SAP Note or an SAP Solution #
To show each parameter of a note
, use the following command:
#
saptune note simulate
The command to show each parameter of a solution
is as follows:
#
saptune solution simulate
The command lists the current system value and the expected values (default and override).
8.4.8 Reverting an SAP Note #
To revert an SAP Note, run the following command:
#
saptune note revert NOTE
This restores all parameters of the SAP Note to their values at the time of application.
To revert everything, use the following command:
#
saptune note revert all
8.4.9 Editing an SAP Note #
Each custom SAP Note can be edited by:
#
saptune note edit NOTE
8.4.10 Listing all enabled or applied SAP Notes #
To list all enabled SAP Notes, run:
#
saptune note enabled
To list all applied SAP Notes, run:
#
saptune note applied
8.5 Managing SAP Solutions #
This chapter explains how to work with SAP Solutions.
8.5.1 Creating a new SAP Solution #
To create a new SAP Solution, run:
#
saptune solution create SOLUTION
8.5.2 Deleting SAP Solution #
To delete an SAP Solution, run the following command:
#
saptune solution delete myHANA
Solution to delete is a customer/vendor specific Solution. Do you really want to delete this Solution 'myHANA'? [y/n]: y
The SAP Solution may not be applied at the time. Keep in mind the following points:
A confirmation is required to finish the action.
SAP Solutions shipped by
saptune
cannot be deleted.If the SAP Solution is already applied, the command is terminated with the information that the SAP Solution first needs to be reverted before it can be deleted.
8.5.3 Renaming an SAP Solution #
To rename an SAP Solution, run the following command:
#
saptune solution rename myHANA myHANA2
Solution to rename is a customer/vendor specific Solution. Do you really want to rename this Solution 'myHANA' to the new name 'myHANA2'? [y/n]:
The SAP Solution may not be applied at the time. Keep in mind the following points:
A confirmation is needed to finish the action.
SAP Solutions shipped by
saptune
cannot be renamed.If the SAP Solution is already applied, the command will be terminated with the information that the SAP Solution first needs to be reverted before it can be renamed.
8.5.4 Showing the configuration of an SAP Solution #
To list the configuration of an SAP Solution, run the following command:
#
saptune solution show SOLUTION
8.5.5 Switching to another SAP Solution #
Starting with saptune
version 3.1, it is easier to switch to a different solution using the saptune solution change SOLUTION
command.
Keep in mind that internally the current solution is reverted first, and then the new solution is applied. If you have additional notes configured, the order is not preserved.
If the same solution is already applied, no action is taken. Otherwise the current solution gets reverted and the new one applied. The command prompts for confirmation before making the change. This can be disabled by adding the --force
option.
8.5.6 Reverting an SAP Solution #
To revert an SAP Solution, run the following command:
#
saptune solution revert SOLUTION
The SAP Solution must be applied. This reverts all SAP Notes parts of the SAP Solution that are still applied.
8.5.7 Editing a custom SAP Solution #
To edit a custom SAP Solution, run:
#
saptune solution edit SOLUTION
8.5.8 Listing enabled/applied SAP Solution #
To list an enabled SAP Solution, run:
#
saptune solution enabled
To list an applied SAP Solution, run:
#
saptune solution applied
If SAP Notes from an applied SAP Solution have been reverted, the string (partial)
has been added to the solution name.
8.6 Verification and troubleshooting #
To see the current status of saptune
, run the following command:
#
saptune status
The output contains the following:
status of the
saptune
,sapconf
, andtuned
serviceversion of package and running
saptune
details about configured SAP Solution and SAP Notes
details about staging
status of systemd system state
virtualization environment (new in
saptune
version 3.1)tuning compliance (new in
saptune
version 3.1)
If a problem occurs, use the saptune_check
command (in version 3.1, you can also use the command saptune check
) that runs checks, reports problems and offers advice on how to solve them.
8.7 Machine-readable output #
Starting with version 3.1, saptune
supports machine-readable output (JSON) for the following commands:
saptune [daemon|service] status
saptune note list|verify|enabled|applied
saptune solution list|verify|enabled|applied
saptune status
saptune version
The machine-readable output makes it possible to integrate saptune
into scripts and configuration management solutions.
To generate JSON output, add --format json
as the first option, for example:
>
saptune --format json note applied | jq
{
"$schema": "file:///usr/share/saptune/schemas/1.0/saptune_note_applied.schema.json",
"publish time": "2023-08-29 17:05:45.627",
"argv": "saptune --format json note applied",
"pid": 1538,
"command": "note applied",
"exit code": 0,
"result": {
"Notes applied": [
"941735",
"1771258",
"1980196",
"2578899",
"2684254",
"2382421",
"2534844",
"2993054",
"1656250"
]
},
"messages": []
}
If a command does not yet support JSON output, the command fails with the result
block set to "implemented": false
:
[+]
>
saptune --format json staging status | jq
{
"$schema": "file:///usr/share/saptune/schemas/1.0/saptune_staging_status.schema.json",
"publish time": "2023-08-29 17:08:16.708",
"argv": "saptune --format json staging status",
"pid": 1653,
"command": "staging status",
"exit code": 1,
"result": {
"implemented": false
},
"messages": []
}
8.8 Staging #
It is possible that a new saptune
package can contain both binary changes
(for example, bug fixes) and new or altered SAP Notes and SAP Solutions. In certain situations, it is preferable to deploy bug fixes and new features while leaving modifications to the system configuration out.
With staging enabled, SAP Note and SAP Solution changes in a package update are not activated immediately. They are placed in a staging area, which can be reviewed and released later.
With the current implementation, a package update overwrites the staging if staging is enabled.
Staging is disabled by default, and it can be enabled with the following command:
#
saptune staging enable
From that point, SAP Note and SAP Solution changes shipped by a saptune
package are put in the staging area. To view the staging area, run:
#
saptune staging list
You can print a tabular overview of the differences of the SAP Note and SAP Solution in the staging and working area with the following command:
#
saptune staging diff [NOTE...|SOLUTION...|all]
After reviewing the differences, you can perform an analysis to see if a release has potential issues or requires additional steps. To do this, run the following command:
#
saptune staging analysis [NOTE...|SOLUTION...|all]
To release an SAP Note or an SAP Solution from the staging area, use the command as follows:
#
saptune staging [--force|--dry-run] [NOTE..|SOLUTION...|all]
The command presents an analysis (see saptune staging
analysis
) and carries out the release after asking for
confirmation.
8.9 Tuning kernel parameters manually using sysctl
#
In addition to or instead of tuning kernel parameters using saptune
, you
can also use sysctl
to make manual adjustments to kernel
parameters. However, such changes using sysctl
do not
persist across reboots by default. To make them persist across reboots, add
them to one of the configuration files read by sysctl
.
sysctl
and saptune
If you plan to configure sysctl
parameters for your
SAP system, consider using saptune
as the central tool for managing
such configurations.
For more information about sysctl
, see the man pages
sysctl(8)
, sysctl.conf(5)
, and
sysctl.d(5)
.
8.10 For more information #
See the following man pages:
man 8 saptune
man 8 saptune-migrate
man 8 saptune-note
Also see the project home page https://github.com/SUSE/saptune/.