I have a requirement to replicate three domains to Azure, they are all different domain names, there is a two way trust between the domains, I’m trying to work out how to use AD connect to replicate the domains to azure, do I need to add a custom domain for each domain and replicate to Azure AD or do I create iaas domain controllers and stretch ad into azure?
Norrin Rad's questions
we are deploying some app services into Azure behind an Azure web application firewall, we already have some applications running on servers behind them, these are secured end to end using SSL. But what I can’t get my head around is what security or protection we are to implement on the app services and how, I’m thinking it must be Azure AD OAuth or something similar, am I on the right track? Or is there a way I’ve missed, or can we use certificates?
would anyone know if we can use a standard MBR boot partition when using the UEFI vm.
Does it need to be a GPT partition? We are migrating machines to Azure and we are setting the hard drive size and want to use the standard MBR, without having to tweak the partition to GPT.
Hope that makes sense.
Thanks
I’m trying to enable security logs for auditing in Azure. I’ve looked at security in the data sources from windows machines, but that says the intelligence pack isn’t installed.
I think they may be in the security Center. I was wondering how to save these logs to a storage account for long term retention.
I hope this makes sense.
Hi Does anyone know a way to automate sending logs to a storage account, I can send the data to log analytics workspace, but also need to have a policy set that keeps logs for 200 days in a storage account?
Thanks in advance.
is there a way to check if a certificate is valid or reporting on certificates that are due to expire for websites in Azure, these are not web apps?
Hope that makes sense
Thanks in advance
we are trying to set up a storage account where a third party company can come and programmatically collect updated files, we upload a new file, then the company gets an email notification but we are stuck where the company needs a sas token, that’s fine but it’s per blob, does anyone know how we can set up access to storage account for third party for them to programmatically collect the latest files in a secure mannner?
Thanks in advance :)
We have configured a failover cluster instance in Azure (iaas), and we are running SQL 2016, and we have a backup directory presented as a csv (which is a mountpoint on the c: drive, under c:\clusterstorage) this is using storage spaces direct s2D.
When we do a file recovery in Azure it restores the drive but the drives are empty, we assume as these are mount points the actual data resides on the actual storage layer, my question is how do we do file level recovery in azure using storage spaces direct S2D?
This has us stumped. Hopefully get some clarity on this. Thanks in advance.
I’m setting up Azure Site Recovery and I’ve been told we can migrate machines and retain the IP addresses in Azure, I thought the azure address space needed to be different than on-premise, is it possible to retain all the IPs when migrating workloads to Azure? We will be doing an application at a time over a period of three months. Any thoughts?
This might be a silly question but when a user resets their password on azure ad, how does it make sure the password is compliant with the onpremise Group Policy which specifies number of characters etc. We have no ad controllers in azure and will use azure ad for all authentication
Thanks and sorry if I’m being a bit dense.
We have built two sql clusters with always on availability groups, based on the windows failover cluster service.
This is done as per Microsoft documented process, however we are getting some strange behaviour, in server manager on the primary node we see the servers being managed, the status of listener, failover cluster, primary and secondary mode as all showing online, however I cannot ping the cluster ip, ping is not blocked.
On node two the server manager shows primary and secondary nodes as online, the cluster and availability listener is not online, which seems ok as this is the secondary node.
The issue is when I failover the cluster goes from primary to secondary with no issues, but the listener doesn’t failover, even if it’s done through sql availability group management.
The cluster, the first node and second node all show online on the secondary node except the listener.
Completely baffled, is there anything I should be aware off, the cluster is built as per Microsoft instructions, not that they’ve helped much ?
All running sql 2016 sp1 on server 2012r2
New to network watcher in azure and just wanted to know if it can watch flow to and from a resource group, as well as to and from a vm?
Thanks
Apologies upfront if this is a silly question, just started with using Azure OMS. We’d like to have a monthly report to show browser usage on our site.
Is there a quick way to configure this?
Thanks
I have the following code, but its not saving the selection into a variable. I'm not the best at these so could do with some help please.
It's supposed to save the selection into the $x variable, which then spits out the selection on the last line.
[void] [System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Forms")
[void] [System.Reflection.Assembly]::LoadWithPartialName("System.Drawing")
$objForm = New-Object System.Windows.Forms.Form
$objForm.Text = "Select a Computer"
$objForm.Size = New-Object System.Drawing.Size(300,200)
$objForm.StartPosition = "CenterScreen"
$objForm.KeyPreview = $True
$objForm.Add_KeyDown({if ($_.KeyCode -eq "Enter")
{$x=$objListBox.SelectedItem;$objForm.Close()}})
$objForm.Add_KeyDown({if ($_.KeyCode -eq "Escape")
{$objForm.Close()}})
$OKButton = New-Object System.Windows.Forms.Button
$OKButton.Location = New-Object System.Drawing.Size(75,120)
$OKButton.Size = New-Object System.Drawing.Size(75,23)
$OKButton.Text = "OK"
$OKButton.Add_Click({$x=$objListBox.SelectedItem;$objForm.Close()})
$objForm.Controls.Add($OKButton)
$CancelButton = New-Object System.Windows.Forms.Button
$CancelButton.Location = New-Object System.Drawing.Size(150,120)
$CancelButton.Size = New-Object System.Drawing.Size(75,23)
$CancelButton.Text = "Cancel"
$CancelButton.Add_Click({$objForm.Close()})
$objForm.Controls.Add($CancelButton)
$objLabel = New-Object System.Windows.Forms.Label
$objLabel.Location = New-Object System.Drawing.Size(10,20)
$objLabel.Size = New-Object System.Drawing.Size(280,20)
$objLabel.Text = "Please select a computer:"
$objForm.Controls.Add($objLabel)
$objListBox = New-Object System.Windows.Forms.ListBox
$objListBox.Location = New-Object System.Drawing.Size(10,40)
$objListBox.Size = New-Object System.Drawing.Size(260,20)
$objListBox.Height = 80
[void] $objListBox.Items.Add("atl-dc-001")
[void] $objListBox.Items.Add("atl-dc-002")
[void] $objListBox.Items.Add("atl-dc-003")
[void] $objListBox.Items.Add("atl-dc-004")
[void] $objListBox.Items.Add("atl-dc-005")
[void] $objListBox.Items.Add("atl-dc-006")
[void] $objListBox.Items.Add("atl-dc-007")
$objForm.Controls.Add($objListBox)
$objForm.Topmost = $True
$objForm.Add_Shown({$objForm.Activate()})
[void] $objForm.ShowDialog()
$x
Thanks in advance :)
I'm trying to restart a list of computers from a text file. To test if the computer is up first. This seems simple, but just can't get it to work.
I can't see where I'm going wrong
$comp = Get-Content C:\temp\srv.txt
$s = Get-Credential
foreach ($comps in $comp)
{
{
if(-not(Test-Connection -ComputerName $comp -Count 1 ))
{
Write-Host "$comp unavailable"
}
}
else
{
Restart-Computer -ComputerName $comp -force -Credential $s
}
}
Thanks for your help in advance :)
I'm trying to deploy two vm's in an avset using visual studio 2015.
I get the error message below when I attempt to deploy:
New-AzureRmResourceGroupDeployment : 2:03:59 AM - Resource Microsoft.Compute/virtualMachines '31' failed with message '{
"error": {
"details": [
{
"target": "vm.properties.storageProfile.networkProfile",
"message": "Could not find member 'networkProfile' on object of type 'StorageProfile'. Path 'properties.storageProfile.networkProfile', line 1, position 893."
},
{
"target": "vm.properties.outputs",
"message": "Could not find member 'outputs' on object of type 'Properties'. Path 'properties.outputs', line 1, position 1072."
}
],
"code": "BadRequest",
"message": "The request message is invalid."
}
}'
At C:\Users\Base\Desktop\Azure-Deploy.ps1:5 char:1
+ New-AzureRmResourceGroupDeployment -Name DCDeploy -ResourceGroupName ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [New-AzureRmResourceGroupDeployment], Exception
+ FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.NewAzureResourceGroupDeploymentCmdlet
New-AzureRmResourceGroupDeployment : 2:03:59 AM - Could not find member 'networkProfile' on object of type 'StorageProfile'. Path 'properties.storageProfile.networkProfile', line 1, position 893.
At C:\Users\Base\Desktop\Azure-Deploy.ps1:5 char:1
+ New-AzureRmResourceGroupDeployment -Name DCDeploy -ResourceGroupName ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [New-AzureRmResourceGroupDeployment], Exception
+ FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.NewAzureResourceGroupDeploymentCmdlet
New-AzureRmResourceGroupDeployment : 2:03:59 AM - Could not find member 'outputs' on object of type 'Properties'. Path 'properties.outputs', line 1, position 1072.
At C:\Users\Base\Desktop\Azure-Deploy.ps1:5 char:1
+ New-AzureRmResourceGroupDeployment -Name DCDeploy -ResourceGroupName ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [New-AzureRmResourceGroupDeployment], Exception
+ FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.NewAzureResourceGroupDeploymentCmdlet
My template is below:
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"stdAdminUserName": {
"type": "string",
"minLength": 1
},
"stdAdminPassword": {
"type": "securestring"
},
"storageAccountName": {
"type": "string",
"minLength": 1
},
"storageAccountType": {
"type": "string",
"allowedValues": [
"Standard_LRS",
"Standard_GRS"
]
},
"faultDomains": {
"type": "int"
},
"updateDomains": {
"type": "int"
},
"applicationid": {
"type": "string",
"minLength": 1
},
"sharedservice": {
"type": "string",
"minLength": 1
},
"msdref": {
"type": "string",
"minLength": 1
},
"project": {
"type": "string",
"minLength": 1
},
"costcentre": {
"type": "string",
"minLength": 1
},
"templateref": {
"type": "string",
"minLength": 1
},
"environment": {
"type": "string",
"minLength": 1
},
"operatingsystem": {
"type": "string",
"minLength": 1
},
"deploymentzone": {
"type": "string",
"minLength": 1
},
"shutdownschedule": {
"type": "string",
"minLength": 1
},
"avSetName": {
"type": "string",
"minLength": 1
},
"vmInstances": {
"type": "int"
},
"vmSize": {
"type": "string",
"minLength": 1
},
"vmDiskSize": {
"type": "string",
"minLength": 1
},
"networkName": {
"type": "string",
"minLength": 1
},
"networkResourceGroup": {
"type": "string",
"minLength": 1
},
"subnetName": {
"type": "string",
"minLength": 1
},
"vmNicNamePrefix": {
"type": "string",
"minLength": 1
},
"vmNamePrefix": {
"type": "string",
"minLength": 1
}
},
"variables": {
"VNetID": "[resourceId(Parameters('networkResourceGroup'), 'Microsoft.Network/virtualNetworks', Parameters('networkname'))]",
"SubnetRef": "[resourceid(variables('VNetID'), '/subnets/', Parameters('subnetName'))]",
"stdVMImagePublisher": "MicrosoftWindowsServer",
"stdVMImageOffer": "WindowsServer",
"stdWindowsOSVersion": "2012-R2-Datacenter",
"stdVHDContainerName": "vhds",
"VMOSDiskNamePrefix": "VMOSDisk",
"VMDATADisk1NamePrefix": "DataDisk1VM",
"VMDATADisk2NamePrefix": "DataDisk2VM"
},
"resources": [
{
"name": "[Parameters('storageAccountName')]",
"type": "Microsoft.Storage/storageAccounts",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"dependsOn": [],
"tags": {
"displayname": "[Parameters('storageAccountName')]",
"applicationid": "[Parameters('applicationid')]",
"sharedservice": "[Parameters('sharedservice')]",
"msdref": "[Parameters('msdref')]",
"project": "[Parameters('project')]",
"costcentre": "[Parameters('costcentre')]",
"operatingsystem": "[Parameters('operatingsystem')]",
"deploymentzone": "[Parameters('deploymentzone')]",
"shutdownschedule": "[Parameters('shutdownschedule')]"
},
"properties": {
"accountType": "[Parameters('storageAccountType')]"
}
},
{
"name": "[parameters('avSetName')]",
"type": "Microsoft.Compute/availabilitySets",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"dependsOn": [],
"tags": {
"displayName": "[parameters('avSetName')]"
},
"properties": {
"platformUpdateDomainCount": "[parameters('updateDomains')]",
"platformFaultDomainCount": "[parameters('faultDomains')]"
}
},
{
"name": "[concat(Parameters('vmNicNamePrefix'), copyindex(1))]",
"type": "Microsoft.Network/networkInterfaces",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"copy": {
"name": "nicLoop",
"count": "[parameters('vmInstances')]"
},
"tags": {
"costcenter": "[Parameters('costcentre')]",
"environment": "[Parameters('environment')]",
"project": "[Parameters('project')]",
"role": "vmnic",
"templateref": "[Parameters('templateRef')]"
},
"properties": {
"ipConfigurations": [
{
"name": "ipconfig1",
"properties": {
"privateIPAllocationMethod": "Dynamic",
"subnet": {
"id": "[variables('SubnetRef')]"
}
}
}
]
}
},
{
"name": "[concat(parameters('vmInstances'), copyindex(1))]",
"type": "Microsoft.Compute/virtualMachines",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"dependsOn": [
"[concat('Microsoft.Storage/storageAccounts/', Parameters('storageAccountName'))]",
"[concat('Microsoft.Compute/availabilitySets/', Parameters('avSetName'))]",
"nicLoop"
],
"copy": {
"name": "virtualMachineLoop",
"count": "[parameters('vmInstances')]"
},
"tags": {
"applicationid": "[Parameters('applicationid')]",
"costcentre": "[Parameters('costcentre')]",
"deploymentzone": "[Parameters('deploymentzone')]",
"displayname": "[concat(parameters('vmInstances'), copyindex(1))]",
"environment": "[Parameters('environment')]",
"msdref": "[Parameters('msdref')]",
"operatingsystem": "[Parameters('operatingsystem')]",
"project": "[Parameters('project')]",
"sharedservice": "[Parameters('sharedservice')]"
},
"properties": {
"availabilitySet": {
"id": "[resourceId('Microsoft.Compute/availabilitySets',parameters('avSetName'))]"
},
"hardwareProfile": {
"vmSize": "[Parameters('vmSize')]"
},
"osProfile": {
"computerName": "[concat(parameters('vmInstances'), copyindex(1))]",
"adminUsername": "[Parameters('stdAdminUserName')]",
"adminPassword": "[Parameters('stdAdminPassword')]"
},
"storageProfile": {
"imageReference": {
"publisher": "[variables('STDVMImagePublisher')]",
"offer": "[variables('STDVMImageOffer')]",
"sku": "[variables('stdWindowsOSVersion')]",
"version": "latest"
},
"osDisk": {
"name": "[concat(variables('VMOSDiskNamePrefix'), copyindex(1))]",
"vhd": {
"uri": "[concat('http://', Parameters('storageAccountName'), '.blob.core.windows.net/', variables('stdVHDContainerName'), '/', variables('VMOSDiskNamePrefix'), copyindex(1), '.vhd')]"
},
"caching": "ReadWrite",
"createOption": "FromImage"
},
"networkProfile": {
"networkInterfaces": [
{
"id": "[resourceId('Microsoft.Network/networkInterfaces', concat(Parameters('vmNicNamePrefix'), copyindex(1)))]"
}
]
}
},
"outputs": {
}
}
}
]
}
I'm trying to deploy two VMs in an avset using Visual Studio 2015.
I get the error message below when I attempt to deploy:
Reference Id 1 is not formatted correctly. The Id is expected to reference resources of type virtualNetworks/subnets. Path properties.ipConfigurations[0].properties.subnet.
Full error:
VERBOSE: 11:43:00 PM - Resource Microsoft.Compute/availabilitySets 'avset-apps2dc' provisioning status is succeeded
New-AzureRmResourceGroupDeployment : 11:43:00 PM - Resource Microsoft.Network/networkInterfaces 'vm-machine2-nic1' failed with message '{
"error": {
"code": "InvalidRequestFormat",
"message": "Cannot parse the request.",
"details": [
{
"code": "InvalidJsonReferenceFormat",
"message": "Reference Id 1 is not formatted correctly. The Id is expected to reference resources of type virtualNetworks/subnets. Path properties.ipConfigurations[0].properties.subnet."
}
It's really got me stumped and I was wondering if anyone has come across this before?
The scripts have been sanitised.
Template file:
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"stdAdminUserName": {
"type": "string",
"minLength": 1
},
"stdAdminPassword": {
"type": "securestring"
},
"storageAccountName": {
"type": "string",
"minLength": 1
},
"storageAccountType": {
"type": "string",
"allowedValues": [
"Standard_LRS",
"Standard_GRS"
]
},
"faultDomains": {
"type": "int"
},
"updateDomains": {
"type": "int"
},
"applicationid": {
"type": "string",
"minLength": 1
},
"sharedservice": {
"type": "string",
"minLength": 1
},
"msdref": {
"type": "string",
"minLength": 1
},
"project": {
"type": "string",
"minLength": 1
},
"costcentre": {
"type": "string",
"minLength": 1
},
"templateref": {
"type": "string",
"minLength": 1
},
"environment": {
"type": "string",
"minLength": 1
},
"operatingsystem": {
"type": "string",
"minLength": 1
},
"deploymentzone": {
"type": "string",
"minLength": 1
},
"shutdownschedule": {
"type": "string",
"minLength": 1
},
"avSetName": {
"type": "string",
"minLength": 1
},
"vmInstances": {
"type": "int"
},
"vmSize": {
"type": "string",
"minLength": 1
},
"vmDiskSize": {
"type": "string",
"minLength": 1
},
"networkName": {
"type": "string",
"minLength": 1
},
"networkResourceGroup": {
"type": "string",
"minLength": 1
},
"subnetName": {
"type": "string",
"minLength": 1
},
"vmNicNamePrefix": {
"type": "string",
"minLength": 1
},
"vmNamePrefix": {
"type": "string",
"minLength": 1
}
},
"variables": {
"VNetID": "[resourceId(Parameters('networkResourceGroup'), 'Microsoft.Network/virtualNetworks', Parameters('networkname'))]",
"SubnetRef": "[concat(variables('VNetID'), '/subnets/', Parameters('subnetName'))]",
"stdVMImagePublisher": "MicrosoftWindowsServer",
"stdVMImageOffer": "WindowsServer",
"stdWindowsOSVersion": "2012-R2-Datacenter",
"stdVHDContainerName": "vhds",
"VMOSDiskNamePrefix": "VMOSDisk",
"VMDATADisk1NamePrefix": "DataDisk1VM",
"VMDATADisk2NamePrefix": "DataDisk2VM"
},
"resources": [
{
"name": "[Parameters('storageAccountName')]",
"type": "Microsoft.Storage/storageAccounts",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"dependsOn": [],
"tags": {
"displayname": "[Parameters('storageAccountName')]",
"applicationid": "[Parameters('applicationid')]",
"sharedservice": "[Parameters('sharedservice')]",
"msdref": "[Parameters('msdref')]",
"project": "[Parameters('project')]",
"costcentre": "[Parameters('costcentre')]",
"operatingsystem": "[Parameters('operatingsystem')]",
"deploymentzone": "[Parameters('deploymentzone')]",
"shutdownschedule": "[Parameters('shutdownschedule')]"
},
"properties": {
"accountType": "[Parameters('storageAccountType')]"
}
},
{
"name": "[parameters('avSetName')]",
"type": "Microsoft.Compute/availabilitySets",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"dependsOn": [],
"tags": {
"displayName": "[parameters('avSetName')]"
},
"properties": {
"platformUpdateDomainCount": "[parameters('updateDomains')]",
"platformFaultDomainCount": "[parameters('faultDomains')]"
}
},
{
"name": "[concat(Parameters('vmNicNamePrefix'), copyindex(1))]",
"type": "Microsoft.Network/networkInterfaces",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"copy": {
"name": "nicLoop",
"count": "[parameters('vmInstances')]"
},
"tags": {
"costcenter": "[Parameters('costcentre')]",
"environment": "[Parameters('environment')]",
"project": "[Parameters('project')]",
"role": "vmnic",
"templateref": "[Parameters('templateRef')]"
},
"properties": {
"ipConfigurations": [
{
"name": "ipconfig1",
"properties": {
"privateIPAllocationMethod": "Dynamic",
"subnet": {
"id": "[parameters('vmInstances')]"
}
}
}
]
}
},
{
"name": "[concat(parameters('vmInstances'), copyindex(1))]",
"type": "Microsoft.Compute/virtualMachines",
"location": "[resourceGroup().location]",
"apiVersion": "2015-06-15",
"dependsOn": [
"[concat('Microsoft.Storage/storageAccounts/', Parameters('storageAccountName'))]",
"[concat('Microsoft.Compute/availabilitySets/', Parameters('avSetName'))]",
"nicLoop"
],
"copy": {
"name": "virtualMachineLoop",
"count": "[parameters('vmInstances')]"
},
"tags": {
"applicationid": "[Parameters('applicationid')]",
"costcentre": "[Parameters('costcentre')]",
"deploymentzone": "[Parameters('deploymentzone')]",
"displayname": "[concat(parameters('vmInstances'), copyindex(1))]",
"environment": "[Parameters('environment')]",
"msdref": "[Parameters('msdref')]",
"operatingsystem": "[Parameters('operatingsystem')]",
"project": "[Parameters('project')]",
"sharedservice": "[Parameters('sharedservice')]"
},
"properties": {
"availabilitySet": {
"id": "[resourceId('Microsoft.Compute/availabilitySets',parameters('avSetName'))]"
},
"hardwareProfile": {
"vmSize": "[Parameters('vmSize')]"
},
"osProfile": {
"computerName": "[concat(parameters('vmInstances'), copyindex(1))]",
"adminUsername": "[Parameters('stdAdminUserName')]",
"adminPassword": "[Parameters('stdAdminPassword')]"
},
"storageProfile": {
"imageReference": {
"publisher": "[variables('STDVMImagePublisher')]",
"offer": "[variables('STDVMImageOffer')]",
"sku": "[variables('stdWindowsOSVersion')]",
"version": "latest"
},
"osDisk": {
"name": "[concat(variables('VMOSDiskNamePrefix'), copyindex(1))]",
"vhd": {
"uri": "[concat('http://', Parameters('storageAccountName'), '.blob.core.windows.net/', variables('stdVHDContainerName'), '/', variables('VMOSDiskNamePrefix'), copyindex(1), '.vhd')]"
},
"caching": "ReadWrite",
"createOption": "FromImage"
},
"networkProfile": {
"networkInterfaces": [
{
"id": "[resourceId('Microsoft.Network/networkInterfaces', concat(Parameters('vmNicNamePrefix'), copyindex(1)))]"
}
]
}
},
"outputs": {
}
}
}
]
}
Parameters file:
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentParameters.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"stdAdminUserName": {
"value": "localadministrator"
},
"storageAccountName": {
"value": "straccforvhdsnstuff1234"
},
"storageAccountType": {
"value": "Standard_LRS"
},
"faultDomains": {
"value": 2
},
"updateDomains": {
"value": 5
},
"applicationid": {
"value": "test-apps2"
},
"sharedservice": {
"value": "No"
},
"msdref": {
"value": "123456"
},
"project": {
"value": "test-apps2"
},
"costcentre": {
"value": "ab1234"
},
"operatingsystem": {
"value": "Windows 2012-R2-Datacenter"
},
"deploymentzone": {
"value": "safe-zone"
},
"avSetName": {
"value": "avset-apps2dc"
},
"vmInstances": {
"value": 1
},
"vmSize": {
"value": "Standard_D3_V2"
},
"vmDiskSize": {
"value": "256"
},
"networkName": {
"value": "vnet-network"
},
"networkResourceGroup": {
"value": "rgp-for-network"
},
"subnetName": {
"value": "subnettest-app2"
},
"vmNicNamePrefix": {
"value": "vm-machine2-nic"
},
"vmNamePrefix": {
"value": "vm-machine2-"
},
"templateref": {
"value": "tempref123"
},
"environment": {
"value": "green"
},
"shutdownschedule": {
"value": "notapp"
}
}
}
I have run the JSON through online validators and no problems highlighted, there are no errors in the script according to VS2015
. However, the deployment fails "reference 1 not formatted properly"
One more point, not sure how much it applies, the networking resource group is independent of the VM resource group.
Is there a way to list all the VMS listed in recovery vault using powershell?
I've been hunting around online and have only seen commands to manage virtual machines but not list them. I'm trying to list all the protected VMS and the last backup date. If it's possible.
Thanks in advance :)
I have a csv file with two columns "Path" and "Owner".
I've created the below script and it can read from the CSV file, but when I attempt to assign the variables from the csv it fails.
Import-Csv C:\test\output.csv | ForEach-Object {
$Path = $_.path
$owner = $_.owner
"The username is $Path and the owner is $owner"
}
ForEach-Object {
$Path = $_.path
$owner = $_.owner
$Account = New-Object -TypeName System.Security.Principal.NTAccount -ArgumentList '$owner'
$Acl = Get-Acl -Path $Path
$Acl.SetOwner($Account)
Set-Acl -Path $owner -AclObject $Acl
}
The output is correct from the first segment and shows the path and the owner, but the second part doesn't set the owner according to the path.
Hi I set up a storage policy last month and every seven days it was meant to back up sql, sql transaction logs and 3 windows servers (full system state), they are located on a remote site. The first time the policy ran everything backed up, however since then the sql and sql transaction logs have been backing up fine but the windows system state on the 3 other servers hasn't ran at all. When I look in jobs and schedule this only has the sql stuff in the schedule. I've configured other sites exactly the same but they all run fine, same server is (2003).
Any help would be greatly appreciated, hope what I've written makes sense :)