Difference between revisions of "Amazon EC2"

From DevOps Notebook
(Created page with "=== Initialize disks in Amazon EC2 in Windows === <pre> PS C:\> C:\ProgramData\Amazon\EC2-Windows\Launch\Scripts\InitializeDisks.ps1 </pre>")
 
Line 2: Line 2:
 
<pre>
 
<pre>
 
PS C:\> C:\ProgramData\Amazon\EC2-Windows\Launch\Scripts\InitializeDisks.ps1
 
PS C:\> C:\ProgramData\Amazon\EC2-Windows\Launch\Scripts\InitializeDisks.ps1
 +
</pre>
 +
 +
=== Check if instance returns meta-data info and fix routes on windows server ===
 +
<pre>
 +
ps> Invoke-RestMethod -uri http://169.254.169.254/latest/meta-data/
 +
ps> Import-Module c:\ProgramData\Amazon\EC2-Windows\Launch\Module\Ec2Launch.psm1 ; Add-Routes
 
</pre>
 
</pre>

Revision as of 21:33, 9 September 2021

Initialize disks in Amazon EC2 in Windows

PS C:\> C:\ProgramData\Amazon\EC2-Windows\Launch\Scripts\InitializeDisks.ps1

Check if instance returns meta-data info and fix routes on windows server

ps> Invoke-RestMethod -uri http://169.254.169.254/latest/meta-data/
ps> Import-Module c:\ProgramData\Amazon\EC2-Windows\Launch\Module\Ec2Launch.psm1 ; Add-Routes