giip
SES 商机登记
5分钟阅读

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 (自动化)

上述界面操作对应以下 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 列表(每台服务器一条分配)。
    • 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