This content has been machine translated dynamically.
Dieser Inhalt ist eine maschinelle Übersetzung, die dynamisch erstellt wurde. (Haftungsausschluss)
Cet article a été traduit automatiquement de manière dynamique. (Clause de non responsabilité)
Este artículo lo ha traducido una máquina de forma dinámica. (Aviso legal)
此内容已经过机器动态翻译。 放弃
このコンテンツは動的に機械翻訳されています。免責事項
이 콘텐츠는 동적으로 기계 번역되었습니다. 책임 부인
Este texto foi traduzido automaticamente. (Aviso legal)
Questo contenuto è stato tradotto dinamicamente con traduzione automatica.(Esclusione di responsabilità))
This article has been machine translated.
Dieser Artikel wurde maschinell übersetzt. (Haftungsausschluss)
Ce article a été traduit automatiquement. (Clause de non responsabilité)
Este artículo ha sido traducido automáticamente. (Aviso legal)
この記事は機械翻訳されています.免責事項
이 기사는 기계 번역되었습니다.책임 부인
Este artigo foi traduzido automaticamente.(Aviso legal)
这篇文章已经过机器翻译.放弃
Questo articolo è stato tradotto automaticamente.(Esclusione di responsabilità))
Translation failed!
日志收集
概述
默认情况下,Linux VDA 已启用日志收集功能。
配置
Linux VDA 发布包中包含 ctxlogd 守护程序和 setlog 实用程序。默认情况下,在安装和配置 Linux VDA 后,ctxlogd 守护程序将启动。
ctxlogd 守护程序
所有其他受跟踪的服务都依赖于 ctxlogd 守护程序。如果您不想继续跟踪 Linux VDA,可以停止 ctxlogd 守护程序。
setlog 实用程序
日志收集是使用 setlog 实用程序配置的,该实用程序位于 /opt/Citrix/VDA/bin/ 路径下。只有 root 用户才有权运行它。您可以使用 GUI 或运行命令来查看和更改配置。运行以下命令以获取有关 setlog 实用程序的帮助:
setlog help
<!--NeedCopy-->
值
默认情况下,日志输出路径设置为 /var/log/xdl/hdx.log,最大日志大小设置为 200 MB,并且您可以在日志输出路径下最多保存两个旧日志文件。
查看当前的 setlog 值:
setlog values
log_path (Log Output Path) = /var/log/xdl/hdx.log
log_size (Max Log Size (MiB)) = 200
log_count (Max Old Log Files) = 2
<!--NeedCopy-->
查看或设置单个 setlog 值:
setlog value <name> [<value>]
<!--NeedCopy-->
例如:
setlog value log_size 100
<!--NeedCopy-->
级别
默认情况下,日志级别设置为 warning(不区分大小写)。
要查看为不同组件设置的日志级别,请运行以下命令:
setlog levels
<!--NeedCopy-->
要设置日志级别(包括 Disabled、Inherited、Verbose、Information、Warnings、Errors 和 Fatal Errors),请运行以下命令:
setlog level <class> [<level>]
<!--NeedCopy-->
| 日志级别 | 命令参数(不区分大小写) |
|---|---|
| Disabled | none |
| Inherited | inherit |
| Verbose | verbose |
| Information | info |
| Warnings | warning |
| Errors | error |
| Fatal Errors | fatal |
<class> 变量指定 Linux VDA 的一个组件。要涵盖所有组件,请将其设置为 all。例如:
setlog level all error
<!--NeedCopy-->
标志
默认情况下,标志设置如下:
setlog flags
DATE = true
TIME = true
NAME = true
PID = true
TID = false
SID = true
UID = false
GID = false
CLASS = false
LEVEL = false
FUNC = true
FILE = false
<!--NeedCopy-->
查看当前标志:
setlog flags
<!--NeedCopy-->
查看或设置单个日志标志:
setlog flag <flag> [<state>]
<!--NeedCopy-->
恢复默认值
将所有级别、标志和值恢复为默认设置:
setlog default
<!--NeedCopy-->
重要提示:
ctxlogd服务是使用 /var/xdl/.ctxlog 文件配置的,该文件只能由 root 用户创建。其他用户没有对此文件的写入权限。我们建议 root 用户不要向其他用户授予写入权限。不遵守此规定可能会导致ctxlogd出现任意或恶意配置,从而影响服务器性能和用户体验。
故障排除
当 /var/xdl/.ctxlog 文件丢失(例如,意外删除)时,ctxlogd 守护程序会失败,并且您无法重新启动 ctxlogd 服务。
/var/log/messages:
Apr 1 02:28:21 RH72 citrix-ctxlogd[17881]: Failed to open logging configuration file.
Apr 1 02:28:21 RH72 systemd: ctxlogd.service: main process exited, code=exited, status=1/FAILURE
Apr 1 02:28:21 RH72 systemd: Unit ctxlogd.service entered failed state.
Apr 1 02:28:21 RH72 systemd: ctxlogd.service failed.
<!--NeedCopy-->
要解决此问题,请以 root 用户身份运行 setlog 以重新创建 /var/xdl/.ctxlog 文件。然后重新启动其他服务所依赖的 ctxlogd 服务。
共享
共享
This Preview product documentation is Citrix Confidential.
You agree to hold this documentation confidential pursuant to the terms of your Citrix Beta/Tech Preview Agreement.
The development, release and timing of any features or functionality described in the Preview documentation remains at our sole discretion and are subject to change without notice or consultation.
The documentation is for informational purposes only and is not a commitment, promise or legal obligation to deliver any material, code or functionality and should not be relied upon in making Citrix product purchase decisions.
If you do not agree, select I DO NOT AGREE to exit.