This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#■ ADDS FSMO 確認 | |
Get-ADDomain | Select-Object *master,PDC* | FL | |
Get-ADForest | Select-Object *master | FL | |
#■ ADDS FSMO 移行 | |
Move-ADDirectoryServerOperationMasterRole <<移行先ADDCホスト名>> -OperationMasterRole InfraStructureMaster,RIDMaster,PDCEmulator,DomainNamingMaster,SchemaMaster | |
#■ ADDS FSMO 確認 | |
Get-ADDomain | Select-Object *master,PDC* | FL | |
Get-ADForest | Select-Object *master | FL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Set-Location $PSScriptRoot | |
Invoke-WebRequest -Uri 'http://aka.ms/azStackPsh' -OutFile ((Invoke-WebRequest -Uri http://aka.ms/azStackPsh).Headers.'Content-Disposition'.Split('=')[1] | Where-Object {$_ -like "*.exe"}) | |
Invoke-WebRequest -Uri 'http://aka.ms/massqlrprfrsh' -OutFile MSSQLRP.exe | |
Invoke-WebRequest -Uri 'http://aka.ms/MASMySQLRP' -OutFile mySQLRP.exe | |
Invoke-WebRequest -Uri 'http://aka.ms/azasinstaller' -OutFile AppService.exe | |
Invoke-WebRequest -Uri 'http://aka.ms/azashelper' -OutFile AppServiceHelperScripts.zip | |
.\MSSQLRP.exe -s2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#get list | |
$AdapterList = @(Get-NetAdapter | Where-Object {$_.InterfaceDescription -match 'Eth' } | Select-Object MacAddress,Name,InterfaceDescription|Sort-Object MacAddress); | |
$AdapterList; | |
#change name | |
for ($i = 0; $i -lt $AdapterList.Count; $i++) | |
{ | |
if ($AdapterList[$i].InterfaceDescription.IndexOf("SFP") -eq -1) | |
{ | |
$newname = "Eth0{0}-T" -f ($i+1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$pass = "<<password>>" | |
$AAD = "xxxx.onmicrosoft.com" | |
$HostIP = "10.10.10.xx" | |
New-Item -Path "c:\work" -ItemType Directory -Force | Out-Null | |
Set-Location "C:\work" | |
Install-Module -Name AzureRm -RequiredVersion 1.2.6 -Scope CurrentUser | |
Invoke-WebRequest -Uri https://github.com/Azure/AzureStack-Tools/archive/master.zip -OutFile master.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Convert-MacToVender ($Mac ,$IP) | |
{ | |
try | |
{ | |
"$Mac : $IP : " + (Invoke-WebRequest -Uri ("http://api.macvendors.com/$Mac")) | |
} | |
catch [System.Net.WebException],[System.Exception] | |
{ | |
"$Mac : $IP :" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$i = 0 | |
do | |
{ | |
$MountVHDMessage = "Mounting Nested Azure Stack HOST VHDX" | |
if (Test-Path "c:\CloudDeployment\Configuration\Roles\Infrastructure\BareMetal\OneNodeRole.xml") | |
{ | |
Write-Progress $MountVHDMessage -Status " updating C:\CloudDeployment\Configuration\Roles\Infrastructure\BareMetal\OneNodeRole.xml" -PercentComplete 40 | |
$BareMetalRole = Get-Content "c:\CloudDeployment\Configuration\Roles\Infrastructure\BareMetal\OneNodeRole.xml" | |
$BareMetalRole = $BareMetalRole.Replace("<MinimumSizeOfSystemDiskGB>180</MinimumSizeOfSystemDiskGB>","<MinimumSizeOfSystemDiskGB>80</MinimumSizeOfSystemDiskGB>") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$i = 0 | |
do | |
{ | |
$MountVHDMessage = "Mounting Nested Azure Stack HOST VHDX" | |
if (Test-Path "c:\CloudDeployment\Configuration\Roles\Infrastructure\BareMetal\OneNodeRole.xml") | |
{ | |
Write-Progress $MountVHDMessage -Status " updating C:\CloudDeployment\Configuration\Roles\Infrastructure\BareMetal\OneNodeRole.xml" -PercentComplete 40 | |
$BareMetalRole = Get-Content "c:\CloudDeployment\Configuration\Roles\Infrastructure\BareMetal\OneNodeRole.xml" | |
$BareMetalRole = $BareMetalRole.Replace("<MinimumNumberOfCoresPerMachine>12</MinimumNumberOfCoresPerMachine>","<MinimumNumberOfCoresPerMachine>0</MinimumNumberOfCoresPerMachine>") |
OlderNewer