davidstamen 09月29日 10:50
UCS多域Syslog配置脚本
index_new5.html
../../../zaker_core/zaker_tpl_static/wap/tpl_guoji1.html

 

本文介绍了如何使用UCS Powertool脚本来配置多个UCS域的Syslog,通过定义变量和执行脚本,实现快速部署。

Time for more UCS Scripting! This time to configure Syslog. The script is pretty straightforward, but nice to have to easily set up Syslog across multiple UCS domains.

Pre-Requsites

Preparing to Execute the Script

The script is pretty straight forward, just need to define a few variables seen below and then you execute the script. I will walk you through the process.

 1# UCS PowerTool Script that to set Syslog 2# @davidstamen 3# http://davidstamen.com 4 5#Define Variables 6$cred = Get-Credential 7$domains = "ucs01.lab.local","ucs02.lab.local" 8$SyslogServer = "syslog.lab.local" 9$Name = "primary"10$Facility = "local7"11$AdminState = "enabled"12$Severity = "notifications"1314#Cycles through each UCS setting values15Foreach ($ucs in $domains) {16 Connect-UCS $ucs -Credential $cred17 Get-UcsSyslogClient -Name $Name | Set-UcsSyslogClient -AdminState $AdminState -ForwardingFacility $Facility -Hostname $SyslogServer -Severity $Severity -Force18 Disconnect-UCS19}

Execute the Script

Fish AI Reader

Fish AI Reader

AI辅助创作,多种专业模板,深度分析,高质量内容生成。从观点提取到深度思考,FishAI为您提供全方位的创作支持。新版本引入自定义参数,让您的创作更加个性化和精准。

FishAI

FishAI

鱼阅,AI 时代的下一个智能信息助手,助你摆脱信息焦虑

联系邮箱 441953276@qq.com

相关标签

UCS Syslog 脚本配置
相关文章