Instantly share code, notes, and snippets.

View config-vwan.json
"configurationVersion": {
"LastUpdatedTime": "2018-10-19T12:52:06.6227301Z",
"Version": "fdafcc0e-6e60-42a9-a694-b566c6b0caa3"
"vpnSiteConfiguration": {
"Name": "fortigate",
"IPAddress": "",
"BgpSetting": {
View gist:5a16e31965ce71761ca2dda0a7565b25

The alerts of Azure Stack 1808 update


  • "Backup failed because of an unknown error"
    • "Critical"
    • "Infrastructure backup failed because of an unknown error."
  • "Backup failed because can't access backup share"
    • "Critical"
    • "Infrastructure backup failed because the backup file share is not accessible. This might be because of an authent ication issue, or access is denied by the external file server."
View Get-AzureRmCostsPerRG.ps1
Add-Type -AssemblyName System.Web
$subscriptionId = (Get-AzureRmSubscription | Out-GridView -PassThru).SubscriptionId
Select-AzureRmSubscription -Subscription $subscriptionId
$context = Get-AzureRmContext
Write-Output "Calculating costs of $subscriptionId"
View Set-AzureRmNetworkWatcherConfigFlowLog.ps1
$Region = "westus2"
$NsgName = "vyos-nsg"
$NsgRsgName = "virtualwan"
$LogstorageRsgName = "azs"
$LogStorageName = "azsdiag457"
$NetworkWatcherName = "NetworkWatcher_" + $Region
$NW = Get-AzurermNetworkWatcher -ResourceGroupName NetworkWatcherRG -Name $NetworkWatcherName
$nsg = Get-AzureRmNetworkSecurityGroup -ResourceGroupName $NsgRsgName -Name $NsgName
View gist:4955f82c0a2f272e9a213a0e92349ea8
Weighted load balancer is needed to simplify the design of clustered virtual firewall appliance. The necessary weight is only 100 vs 0.
In the senarios that Azure Load Balancer which faces to internet balances to two virtual firewall appliances, firewalls must transrate a source ip address to avoid asymmetric routing. So the servers which recieve packets from firewalls don't know the ip address of real client. The details are in attached picture.
If Azure Load Balancer have the avility of weight balancing, firewalls don't transrate a source ip address. Because Every packet always pass through one firewall . The design of clustering two firewall become very simple in using the ha port of standard load balancer.

Title: author Azure Function uses deferral: ongou_ye

date: 2017-12-14 url: /archives/2017-12-14-using-asyncawait-on-azure-function categories:

*   Azure

View moment.js
let main = async() =>{
const moment = require('moment');
let m = moment()
let res = m.utc().format('MM')
View gist:a068ffd32d938c94e649e3e5371523e1