Commit a74c8b10 by Rinat K. Nugaev

Added some fixes

parent de16030f
...@@ -23,7 +23,8 @@ Break ...@@ -23,7 +23,8 @@ Break
} }
#Getting and defining some vars #Getting and defining some vars
$PathZabbix = ${env:ProgramFiles} + '\Zabbix' $PathZabbix = ${env:ProgramFiles} + '\Zabbix'
$osarch = wmic os get OSArchitecture /value
#$osarch = wmic os get OSArchitecture /value
$ZabbixConf = $PathZabbix + '\conf\zabbix_agentd.conf' $ZabbixConf = $PathZabbix + '\conf\zabbix_agentd.conf'
#Getting monitoring server ip for Firewall Rule #Getting monitoring server ip for Firewall Rule
$monserverip = (Test-Connection -ComputerName monitoring.nugaev.net -count 1).IPV4Address.ipaddressTOstring $monserverip = (Test-Connection -ComputerName monitoring.nugaev.net -count 1).IPV4Address.ipaddressTOstring
...@@ -54,6 +55,7 @@ function Unzip ...@@ -54,6 +55,7 @@ function Unzip
Unzip $output\zabbix_agent.zip $PathZabbix Unzip $output\zabbix_agent.zip $PathZabbix
#Defining platform for version of zabbix agent #Defining platform for version of zabbix agent
<#
if ($osarch -eq "OSArchitecture=64-bit") if ($osarch -eq "OSArchitecture=64-bit")
{ {
$osarch = "win64" $osarch = "win64"
...@@ -62,6 +64,7 @@ else ...@@ -62,6 +64,7 @@ else
{ {
$osarch = "win32" $osarch = "win32"
} }
#>
#Getting computer hostname for config file #Getting computer hostname for config file
$HostnameFull ="$env:computername.$env:userdnsdomain" $HostnameFull ="$env:computername.$env:userdnsdomain"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment