Skip to content

Commit

Permalink
changed nmm handlers
Browse files Browse the repository at this point in the history
updated hyper-v install checker
fixed ol nmm
  • Loading branch information
bottkars committed Aug 25, 2015
1 parent e661a67 commit fa79d99
Show file tree
Hide file tree
Showing 7 changed files with 53 additions and 122 deletions.
26 changes: 7 additions & 19 deletions Scripts/E2013/install-nmm.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -25,32 +25,20 @@ $Domain = $env:USERDNSDOMAIN
Write-Verbose $Domain

.$Builddir\test-sharedfolders.ps1
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath




if ($Nmm_ver -lt 'nmm85')
{

$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
$argumentlist = '/s /v" /qn /l*v c:\scripts\nmm.log RMEXCHDOMAIN='+$Domain+' RMEXCHUSER=NMMBackupUser RMEXCHPASSWORD=Password123! RMCPORT=6730 RMDPORT=6731"'
start-process -filepath "$Setuppath\setup.exe" -ArgumentList $argumentlist -wait
}
else
{
Write-Warning "trying nwvss install"
if ($setup = Get-ChildItem "\\vmware-host\shared folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe")
{
Write-Verbose "Installing NMM"
Start-Process -Wait -FilePath "$($Setup.fullname)" -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
Write-Verbose "Configuring NMM Backup User"
Start-Process -Wait -FilePath "C:\Program Files\EMC NetWorker\nsr\bin\UserConfigCLI.exe" -ArgumentList "$nmmusername $nmmPassword $nmmdatabase"
}
else
{
Write-Error "Networker Setup File could not be elvaluated"
}
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
Start-Process -Wait -FilePath $Setuppath -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
Write-Verbose "Configuring NMM Backup User"
Start-Process -Wait -FilePath "C:\Program Files\EMC NetWorker\nsr\bin\UserConfigCLI.exe" -ArgumentList "$nmmusername $nmmPassword $nmmdatabase"
}
if ($PSCmdlet.MyInvocation.BoundParameters["verbose"].IsPresent)
{
Expand Down
26 changes: 7 additions & 19 deletions Scripts/E2016/install-nmm.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -25,32 +25,20 @@ $Domain = $env:USERDNSDOMAIN
Write-Verbose $Domain

.$Builddir\test-sharedfolders.ps1
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath




if ($Nmm_ver -lt 'nmm85')
{

$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
$argumentlist = '/s /v" /qn /l*v c:\scripts\nmm.log RMEXCHDOMAIN='+$Domain+' RMEXCHUSER=NMMBackupUser RMEXCHPASSWORD=Password123! RMCPORT=6730 RMDPORT=6731"'
start-process -filepath "$Setuppath\setup.exe" -ArgumentList $argumentlist -wait
}
else
{
Write-Warning "trying nwvss install"
if ($setup = Get-ChildItem "\\vmware-host\shared folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe")
{
Write-Verbose "Installing NMM"
Start-Process -Wait -FilePath "$($Setup.fullname)" -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
Write-Verbose "Configuring NMM Backup User"
Start-Process -Wait -FilePath "C:\Program Files\EMC NetWorker\nsr\bin\UserConfigCLI.exe" -ArgumentList "$nmmusername $nmmPassword $nmmdatabase"
}
else
{
Write-Error "Networker Setup File could not be elvaluated"
}
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
Start-Process -Wait -FilePath $Setuppath -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
Write-Verbose "Configuring NMM Backup User"
Start-Process -Wait -FilePath "C:\Program Files\EMC NetWorker\nsr\bin\UserConfigCLI.exe" -ArgumentList "$nmmusername $nmmPassword $nmmdatabase"
}
if ($PSCmdlet.MyInvocation.BoundParameters["verbose"].IsPresent)
{
Expand Down
16 changes: 5 additions & 11 deletions Scripts/HyperV/install-nmm.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -23,24 +23,18 @@ $Domain = $env:USERDOMAIN
Write-Verbose $Domain

.$Builddir\test-sharedfolders.ps1
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
if ($Nmm_ver -lt 'nmm85')
{
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
start-process -filepath "$Setuppath" -ArgumentList '/s /v" /qn /l*v c:\scripts\nmm.log' -Wait
start-process -filepath "$Setuppath" -ArgumentList '/s /v" /qn /l*v c:\scripts\nmmglr.log NW_INSTALLLEVEL=200 REBOOTMACHINE=0 NW_GLR_FEATURE=1 WRITECACHEDIR="C:\Program Files\EMC NetWorker\nsr\tmp\nwfs" MOUNTPOINTDIR="C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System" HYPERVMOUNTPOINTDIR="C:\Program Files\EMC NetWorker\nsr\tmp" SETUPTYPE=Install"' -Wait
}
else
{
Write-Warning "trying nwvss install"
if ($setup = Get-ChildItem "\\vmware-host\shared folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe")
{
Start-Process -Wait -FilePath "$($Setup.fullname)" -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 EnableSSMS=1 EnableSSMSBackupTab=1 EnableSSMSScript=1 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
}
else
{
Write-Error "Networker Setup File could not be evaluated"
}
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
Start-Process -Wait -FilePath $Setuppath -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 EnableSSMS=1 EnableSSMSBackupTab=1 EnableSSMSScript=1 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
}
if ($scvmm.IsPresent)
{
Expand Down
19 changes: 6 additions & 13 deletions Scripts/SP2013/install-nmm.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
param(
[ValidateSet('nmm8212','nmm8214','nmm8216','nmm821','nmm300', 'nmm301', 'nmm2012', 'nmm3012', 'nmm82','nmm85','nmm85.BR1','nmm85.BR2','nmm85.BR3','nmm85.BR4')]
$nmm_ver

)
$ScriptName = $MyInvocation.MyCommand.Name
$Host.UI.RawUI.WindowTitle = "$ScriptName"
Expand All @@ -22,26 +23,18 @@ $Domain = $env:USERDOMAIN
Write-Verbose $Domain

.$Builddir\test-sharedfolders.ps1
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath


if ($Nmm_ver -lt 'nmm85')
{
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
start-process -filepath "$Setuppath" -ArgumentList '/s /v" /qn /l*v c:\scripts\nmm.log' -Wait
start-process -filepath "$Setuppath" -ArgumentList '/s /v" /qn /l*v c:\scripts\nmmglr.log NW_INSTALLLEVEL=200 REBOOTMACHINE=0 NW_GLR_FEATURE=1 WRITECACHEDIR="C:\Program Files\EMC NetWorker\nsr\tmp\nwfs" MOUNTPOINTDIR="C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System" HYPERVMOUNTPOINTDIR="C:\Program Files\EMC NetWorker\nsr\tmp" SETUPTYPE=Install"' -Wait
}
else
{
Write-Warning "trying nwvss install"
if ($setup = Get-ChildItem "\\vmware-host\shared folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe")
{
Start-Process -Wait -FilePath "$($Setup.fullname)" -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
}
else
{
Write-Error "Networker Setup File could not be elvaluated"
}
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
Start-Process -Wait -FilePath $Setuppath -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
}
if ($PSCmdlet.MyInvocation.BoundParameters["verbose"].IsPresent)
{
Expand Down
20 changes: 5 additions & 15 deletions Scripts/SQL/install-nmm.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -23,29 +23,19 @@ $Domain = $env:USERDOMAIN
Write-Verbose $Domain

.$Builddir\test-sharedfolders.ps1
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath


if ($Nmm_ver -lt 'nmm85')
{
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\setup.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
start-process -filepath "$Setuppath" -ArgumentList '/s /v" /qn /l*v c:\scripts\nmm.log' -Wait
start-process -filepath "$Setuppath" -ArgumentList '/s /v" /qn /l*v c:\scripts\nmmglr.log NW_INSTALLLEVEL=200 REBOOTMACHINE=0 NW_GLR_FEATURE=1 WRITECACHEDIR="C:\Program Files\EMC NetWorker\nsr\tmp\nwfs" MOUNTPOINTDIR="C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System" HYPERVMOUNTPOINTDIR="C:\Program Files\EMC NetWorker\nsr\tmp" SETUPTYPE=Install"' -Wait
}
else
{
Write-Warning "trying nwvss install"
if ($setup = Get-ChildItem "\\vmware-host\shared folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe")
{
Start-Process -Wait -FilePath "$($Setup.fullname)" -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 EnableSSMS=1 EnableSSMSBackupTab=1 EnableSSMSScript=1 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
}
else
{
Write-Error "Networker Setup File could not be evaluated"
}
$Setuppath = "\\vmware-host\Shared Folders\Sources\$nmm_ver\win_x64\networkr\nwvss.exe"
.$Builddir\test-setup -setup NMM -setuppath $Setuppath
Start-Process -Wait -FilePath $Setuppath -ArgumentList "/s /q /log `"C:\scripts\NMM_nw_install_detail.log`" InstallLevel=200 RebootMachine=0 EnableSSMS=1 EnableSSMSBackupTab=1 EnableSSMSScript=1 NwGlrFeature=1 EnableClientPush=1 WriteCacheFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs`" MountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\nwfs\NetWorker Virtual File System`" BBBMountPointFolder=`"C:\Program Files\EMC NetWorker\nsr\tmp\BBBMountPoint`" SetupType=Install"
}


if ($scvmm.IsPresent)
{
if ($nmm_ver -ge "nmm85" )
Expand Down
28 changes: 21 additions & 7 deletions build-lab.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -1419,13 +1419,12 @@ if ($defaults.IsPresent)


}


if (!($MyInvocation.BoundParameters.Keys.Contains("NMM")))
{
if ($Default.NMM -eq "true")
{
$nmm = $true
$nw = $true
}
}

Expand Down Expand Up @@ -2770,6 +2769,7 @@ else
Write-Host
copy-tovmx -Sourcedir $NodeScriptDir
copy-tovmx -Sourcedir $SourceScriptDir
Write-Warning "Building DC for Domain $BuildDomain, this may take a while"
invoke-vmxpowershell -config $CloneVMX -Guestuser $Adminuser -Guestpassword $Adminpassword -ScriptPath $Targetscriptdir -Script new-dc.ps1 -Parameter "-dcname $DCName -Domain $BuildDomain -IPv4subnet $IPv4subnet -IPv4Prefixlength $IPv4PrefixLength -IPv6PrefixLength $IPv6PrefixLength -IPv6Prefix $IPv6Prefix -AddressFamily $AddressFamily $AddGateway $CommonParameter" -interactive -nowait

status "Preparing Domain"
Expand Down Expand Up @@ -3228,9 +3228,10 @@ switch ($PsCmdlet.ParameterSetName)

##### Hyper-V Block #####
"HyperV" {
$Firstnode = 1 #for later use
$Clusternum = 1 # for later use
$FirstVMX = "$Builddir\HVNODE$Firstnode\HVNODE$Firstnode.vmx"
$Firstnode = "1" #for later use
$Clusternum = "1" # for later use
$LASTVMX = "HVNODE$HyperVNodes"
$FirstVMX = "HVNODE$Firstnode"
$HVLIST = @()
$AddonFeatures = "RSAT-ADDS, RSAT-ADDS-TOOLS, AS-HTTP-Activation, NET-Framework-45-Features, Hyper-V, Hyper-V-Tools, Hyper-V-PowerShell, WindowsStorageManagementService"
if ($ScaleIO.IsPresent)
Expand Down Expand Up @@ -3259,7 +3260,16 @@ switch ($PsCmdlet.ParameterSetName)

}
if ($Cluster.IsPresent) {$AddonFeatures = "$AddonFeatures, Failover-Clustering, RSAT-Clustering, WVR"}
If (!(get-vmx HVNODE))
{
$newdeploy = $true
}
else
{
Write-Warning "Node1 Already Deployed, no autoconfig is done"
}


foreach ($HVNODE in ($Firstnode..$HyperVNodes))
{
if ($HVNODE -eq $HyperVNodes -and $SCVMM.IsPresent)
Expand Down Expand Up @@ -3379,6 +3389,9 @@ switch ($PsCmdlet.ParameterSetName)

} # end HV foreach
########### leaving NMM Section ###################
If ($newdeploy)
{
Write-Warning " Trying New Cluster Deployment !! "
if ($Cluster.IsPresent)
{
write-host
Expand All @@ -3393,13 +3406,13 @@ switch ($PsCmdlet.ParameterSetName)
if ($singlemdm.IsPresent)
{
Write-Warning "Configuring Single MDM"
invoke-vmxpowershell -config $FirstVMX -Guestuser $Adminuser -Guestpassword $Adminpassword -ScriptPath $Targetscriptdir -Script configure-mdm.ps1 -Parameter "-singlemdm -CSVnum 3" -interactive
get-vmx $FirstVMX | invoke-vmxpowershell -Guestuser $Adminuser -Guestpassword $Adminpassword -ScriptPath $Targetscriptdir -Script configure-mdm.ps1 -Parameter "-singlemdm -CSVnum 3" -interactive
}
else
# if ($clusteredmdm.IsPresent)
{
Write-Warning "Configuring Clustered MDM"
invoke-vmxpowershell -config $FirstVMX -Guestuser $Adminuser -Guestpassword $Adminpassword -ScriptPath $Targetscriptdir -Script configure-mdm.ps1 -Parameter "-CSVnum 3" -interactive
get-vmx $FirstVMX | invoke-vmxpowershell -Guestuser $Adminuser -Guestpassword $Adminpassword -ScriptPath $Targetscriptdir -Script configure-mdm.ps1 -Parameter "-CSVnum 3" -interactive
}
}
if ($SCVMM.IsPresent)
Expand Down Expand Up @@ -3431,6 +3444,7 @@ switch ($PsCmdlet.ParameterSetName)
invoke-vmxpowershell -config $CloneVMX -Guestuser $Adminuser -Guestpassword $Adminpassword -ScriptPath $Targetscriptdir -Script install-vmm.ps1 -interactive -nowait
}
} #end SCVMM
}#end newdeploy
} # End Switchblock hyperv
###### new SOFS Block
"SOFS" {
Expand Down
Loading

0 comments on commit fa79d99

Please sign in to comment.