Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use Windows performance counter

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

If we want to track performance counters on a single Azure Windows VM, simply copy the binary in Azure Windows VM and run it.

Azure file, which exposes file sharing using the standard SMB 2.1protocol. As introduced by the Azure storage product team, Azure file sharing can also be used to save diagnostic files, such as logs, performance metrics, and troubleshooting. Multiple Azure VM can load the same file and share to write log files in different folders.

The figure in figure 7 shows how to use the Azure file as a repository for performance counter log files generated from different Azure VM.

Figure 7: storing the performance counter log file in the Azure file

You can use simple basic commands to define Azure files through Azure Powershell:

Import-Module Azure

Select-AzureSubscription-SubscriptionName [[SubscriptionName]]

Get-AzureSubscription-current

New-AzureStorageAccount-StorageAccountName [[AzureStorageAccountName]]-Label [[AzureStorageAccountName]]-Location "North Europe"

# find out if you are using the module

(get-module azure). Version

$ctx=New-AzureStorageContext [[AzureStorageAccountName]] [[AzureStorageAccountKey]]

$ctx = New-AzureStorageContext-StorageAccountName [[AzureStorageAccountName]]-StorageAccountKey [[AzureStorageAccountKey]]

# create a new share

$s = New-AzureStorageShare [[shareName]]-Context $ctx

In our example, we define a share name equal to "logshare01":

$s = New-AzureStorageShare logshare01-Context $ctx

To install a shared folder in Azure Windows VM, we can use this command in two Azure Windows VM:

Net use z:\ [[AzureStorageAccountName]]. File.core.windows.net\ logshare01 / u: [[AzureStorageAccountName]] [[AzureStorageAccountKey]]

This command installs the shared folder "logshare01" of the Azure storage account as driver Z:

To store the log files in a different folder, we can change the SysField.XML file value

Z:\ SysParamsLog1\

Fftest01.txttrue201

The contents of the SysField.XML file in test02 Azure VM:

Z:\ SysParamsLog2\

Fftest02.txt true

twenty

one

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report