giip

CQE Repository Script Management Guide

Learn how to manage, execute, and monitor script registration in the CQE (Custom Query Engine) Repository.

🤖 CQE リポジトリ一覧ページへ →

📋 Overview

The CQE Repo List provides a centralized repository for your maintenance and diagnostic scripts. You can store scripts once and deploy them across any number of logical servers (LSVR) with custom execution parameters.

🔍 Script Details & Execution

When you click on a script in the list, the detail modal opens with the following capabilities:

1. Script Content

View the full source code of the script. This is read-only in the list view; use the edit feature if modifications are needed.

2. Execution Settings (NEW)

Before registering a script to a server, you can configure how it should run:

  • Active: Toggle whether the script is enabled for the selected servers.
  • Repeat: If enabled, the script will run periodically.
  • Interval (min): Set the frequency for repeated execution (in minutes).
  • Start Date: Specify when the first execution should occur.

3. Server Registration (LSVR Queue Put)

You can select one or more servers from your current project to receive this script.

  • LSVR Selector: Use the checkboxes to choose target servers.
  • Add to Queue: Click this button to register the script with the defined settings for all selected servers.

📊 Script Usage Status

At the bottom of the modal, the Usage Status Table displays all servers currently registered for this specific script.

  • Hostname: The name of the server using the script.
  • Usage: The logical server's defined purpose.
  • Settings: View the active/repeat/interval status for each registration.
  • Last Run: Tracks the last time the script was successfully executed on that machine.

API リファレンス

この機能の API 詳細仕様は専用ガイドを参照してください。

📘 システム管理 API リファレンス

トラブルシューティング

症状原因解決
キュー登録後もスクリプトが実行されない実行設定で 有効 (Active) がオフになっている詳細モーダルで Active をオンにして再度キューに登録します。
LSVR セレクターに対象サーバーが表示されない選択中のプロジェクトにサーバーがない、またはサーバーが別プロジェクトに属している上部で正しいプロジェクトを選択しているか確認します。
繰り返し実行が動作しない繰り返し (Repeat) はオンだが 実行間隔 (分) が空になっている実行間隔を 1 以上に設定して再登録します。
登録状況の 最終実行 が更新されない対象サーバーのエージェントがまだキューを受信していないエージェントの接続状態と、開始日時が過去の時刻かを確認します。

🔌 CQE API (自動化向け)

上記のUI操作は次のCQE APIバーブ(byAK/bySkディスパッチャ)に対応します。リクエストは text(バーブ+パラメータ名)、jsondata(値)、token を送信します。

  • CQERepoPut msName msDetail msBody msPer msPrice msType — スクリプトをリポジトリに登録。msTypeps1 / cmd / wsf のいずれか。
  • CQEQueuePut mssn lssngroup csn interval active script_type custom_values repeat startdate auid — サーバーにスクリプトを割り当て。
    • lssngroup: カンマ区切りのLSSN一覧(サーバーごとに1件)。
    • interval: 分。repeat: 0/1 = 一回のみ, 2 = 繰り返し(intervalごとに再実行)。
    • custom_values: サーバー別の注入値 → スクリプト本文の {{CustomVariables}} を置換。
  • CQEQueueGet lssn hostname os op — エージェントがポーリングして次のスクリプト本文を受信。

スクリプト本文のプレースホルダ: {{CustomVariables}}(割り当てごとのcustom_values、サーバー側で注入)、{{sk}}(エージェントトークン)、{{lssn}}(エージェントLSSN)。

実行制限: エージェントは各スクリプトを一時ファイルで60秒のタイムアウトで実行し、ps1 は Windows PowerShell 5.1 で実行されます。スクリプトは短く保ってください。

完全な仕様: giipdb docs/30_Specs/CQE_SPECIFICATION.md


Version: 1.2 Last Updated: 2026-07-23 Source File: giipv3/public/help/cqerepolist.en.md