SECUREXSECURITY ENGINEERINGNVR 文档

高级设置

Securex NVR 配置采用 YAML,并支持“全局默认 + 摄像头级覆盖”的层级。最重要的规则是:先保证 YAML 语法有效,再保证字段属于当前 Securex 核心版本,最后才检查运行时设备/网络。

层级与覆盖

可以把通用的 ffmpeg、objects、record、snapshots 等设置放在全局,然后只在某台摄像头覆盖差异项。这样更容易维护,也能避免多台摄像头复制出不一致的配置。

示例

mqtt:
  enabled: true
  host: 192.168.1.210

cameras:
  front:
    enabled: true
    detect:
      fps: 5

修改流程

  1. 导出/备份当前可用配置。
  2. 只修改一个功能块。
  3. 使用内置配置验证器。
  4. 应用后立即查看启动日志。
  5. 确认 Live、Detect、Record 状态,再继续下一项。

YAML 常见错误

  • 缩进必须使用空格,不要混用 Tab。
  • 布尔值、数字、列表和字符串的数据类型要符合 Schema。
  • 同一键重复定义时可能覆盖前值。
  • 旧版本示例里的字段可能在新版本被移动或删除。

环境变量

密码、API Key 和可变部署参数尽量通过环境变量注入,并在配置中引用。发布文档、截图或备份给第三方前应先脱敏。

验证错误的处理

出现“extra fields not permitted / field required / invalid type”等错误时,先按报错路径定位 YAML 节点,再查当前版本配置参考。不要因为字段“看起来合理”就强行保留。

Advanced Settings

Securex NVR uses YAML with global defaults and camera-level overrides. Troubleshoot in this order: YAML syntax, schema compatibility with the current core, then runtime devices/network.

Inheritance and overrides

Keep common FFmpeg/object/record/snapshot settings global, then override only camera-specific differences. This reduces duplication and drift.

Example

mqtt:
  enabled: true
  host: 192.168.1.210

cameras:
  front:
    enabled: true
    detect:
      fps: 5

Change workflow

  1. Export a known-good config.
  2. Change one functional block.
  3. Run configuration validation.
  4. Apply and inspect startup logs immediately.
  5. Verify Live/Detect/Record before continuing.

Common YAML errors

  • Use spaces, not tabs.
  • Types must match the schema.
  • Duplicate keys can overwrite earlier values.
  • Fields from old examples may be moved or removed in newer cores.

Environment variables

Inject secrets and deployment-specific values through environment variables where possible, and redact them before sharing logs/configs.

Validation errors

For “extra fields”, “field required”, or “invalid type”, follow the error path to the exact YAML node and compare it to the configuration reference for the installed core.

Ajustes avanzados

Securex NVR usa YAML con valores globales y sobrescrituras por cámara. Diagnostique en este orden: sintaxis, schema de la versión y después dispositivos/red.

Herencia

Mantenga ajustes comunes globales y sobrescriba solo diferencias por cámara.

Ejemplo

mqtt:
  enabled: true
  host: 192.168.1.210

cameras:
  front:
    enabled: true
    detect:
      fps: 5

Proceso de cambio

  1. Exporte una configuración válida.
  2. Cambie un bloque.
  3. Valide.
  4. Aplique y revise logs.
  5. Compruebe Live/Detect/Record.

Errores YAML

  • Use espacios, no Tab.
  • Respete tipos del schema.
  • Claves duplicadas pueden sobrescribir.
  • Campos antiguos pueden haber cambiado.

Variables de entorno

Use variables para secretos y oculte datos antes de compartir.

Errores de validación

Siga la ruta exacta del error y compárela con la referencia de la versión instalada.

输入关键词开始搜索