Privileged Access Manager Server Control ( 以下、PAMSC) をリアルタイム優先度で実行させる方法について説明します。
PAMSC 14.Xでは、最初に OS 側で cgroup 管理ツールがインストールされ、構成されている事をご確認ください。
( 例えば、SLES では libcgroup-tools パッケージ)
正しく設定されていれば、インストール時に下記のスクリプトと同様の処理が行われる予定です。
ただし、何らかの理由で正しく動作しない場合は、下記のスクリプトを追加することで動作するようになります。
Privileged Access Manager Server Control: Linux版の14.x
seosd をリアルタイム優先モードで起動することは必須です。 インストール時にこのように設定されていることがあります。
seload コマンドと区別するために seload-script として、英語版 KB に添付されています。
このスクリプトは PAMSC の bin ディレクトリに配置される必要があります。
なので、最初に問題の Linux システムで以下をチェックしてください。
ls -l /opt/CA/PAMSC/bin/seload*
スクリプトは以下のようになります。
----- ここから -----
#!/bin/bash
# -------------------------------------------------------------------------
# CA Privileged Access Manager Server Control v14.10-60
# Copyright (c) 2018 CA. All rights reserved.
#
#
# VeRsIoN: 14.10-60 (85) Compiled On:Script
# -------------------------------------------------------------------------
# A script for starting PAMSC on Linux systems with or without cgroups.
# The seload binary is now referenced as seload-bin.
# -------------------------------------------------------------------------
SEOSDIR="/opt/CA/PAMSC" # AuTo_InSeRt_CoDe
# The name of hierarchy to associate PAMSC processes with
HIERARCHY=myrt
# If a hierarchy for PAMSC is preconfigured by cgconfig service at boot,
# the PERMANENT_HIERARCHY variable below can be set to yes.
PERMANENT_HIERARCHY=no
# Suggested real-time scheduling values for our hierarchy.
# Please check https://www.kernel.org for details.
RT_RUNTIME_US=1000
RT_PERIOD_US=10000
if [ ! -x $SEOSDIR/bin/seload-bin ]; then
SEOSDIR=`grep "^[ \t]*SEOSPATH *=" /etc/seos.ini 2>/dev/null | awk -F= '{print $2}' | awk '{print $1}'`
fi
if [ ! -x $SEOSDIR/bin/seload-bin ]; then
echo "Cannot locate seload-bin binary. Please check /etc/seos.ini"
exit 1
fi
rm -f $SEOSDIR/lock/.cgexec_start 2>/dev/null
if [ ! -x /usr/bin/cgexec ]; then
$SEOSDIR/bin/seload-bin
else
if [ "$PERMANENT_HIERARCHY" != "yes" ]; then
/usr/bin/cgcreate -g cpu:/$HIERARCHY
/usr/bin/cgset -r cpu.rt_runtime_us=$RT_RUNTIME_US $HIERARCHY
/usr/bin/cgset -r cpu.rt_period_us=$RT_PERIOD_US $HIERARCHY
fi
/usr/bin/cgexec -g cpu:/$HIERARCHY $SEOSDIR/bin/seload-bin
[ $? -eq 0 ] && touch $SEOSDIR/lock/.cgexec_start
fi
----- ここまで -----
インストール後に以下のコンテンツと システムに /usr/bin/cgexec があることをご確認ください。
(RHEL では、libcgroup-tools パッケージに該当します。)
/tmp> find /opt/CA/PAMSC/bin -name 'seload*'
/opt/CA/PAMSC/bin/seload-bin <--- 名前が変更された seload バイナリ
/opt/CA/PAMSC/bin/seload <--- 上記スクリプト
全部が正しく設定されていれば、seosd の起動後以下のようになります。:
/tmp> ps -e -o pid,ppid,pri,rtprio,args | grep seos
9407 1 138 98 /opt/CA/PAMSC/bin/seosd
9426 1 1 - /opt/CA/PAMSC/bin/seoswd AGENT
9611 4233 19 - grep --color=auto seos
PAMSC は適切な場所で起動してください。
起動後は以下のコマンドで正しい優先度で起動されている事を確認してください。
ps -e -o pid,ppid,pri,rtprio,args | grep seosd
もし、想定通りで動いていない場合は、サポートケースをオープンしてください。
こちらの文書は以下の KB から翻訳加筆修正を行いました。
Article ID: 282124: Seload script to run PAMSC seosd in real-time priority mode