Found 975 Articles for Software & Coding

How to install MSI file using batch file in PowerShell?

Chirag Nagrekar
Updated on 17-May-2021 12:17:21

3K+ Views

Let say we have one MSI file and we need to install the MSI file on the remote computers using PowerShell but that MSI file should be deployed with the Batch file and should be executed using PowerShell.In this example, we have a 7-zip MSI file and batch file we will first write the installation instructions as shown below.msiexec /i "C:\temp\7z1900-x64.msi" /quietWe have the installation MSI package located at the C:\temp location. We will save the above instruction inside the 7ZipInstaller.bat file.Now we need to call the batch file as shown below. −Wait will wait for the batch file to ... Read More

How to retrieve the Azure VM RAM and CPU size using PowerShell?

Chirag Nagrekar
Updated on 17-May-2021 12:08:03

7K+ Views

Azure VM RAM and CPU size depend on the hardware profile chosen for the VM. In this example, we will retrieve VM (TestMachine2k16) hardware profile and then we can find how much RAM or CPU is allocated to it.To get the Size of the Azure VM, PS C:\> $azvm = Get-AzVM -VMName 'TestMachine2k16' PS C:\> $azvm.HardwareProfile.VmSizeOutputStandard_DS2_v2You can check the above size on the Microsoft Azure website to know how much RAM and CPU are associated with it and another way using the PowerShell by using the Get-AZVmSize command.PS C:\> $vmsize = $azvm.HardwareProfile.VmSize PS C:\> Get-AzVMSize -VMName $azvm.Name -ResourceGroupName $azvm.ResourceGroupName | ... Read More

How to retrieve the Azure VM Subscription Name using PowerShell?

Chirag Nagrekar
Updated on 17-May-2021 12:07:25

2K+ Views

Once you are connected to the Azure Account, there are possibilities that the Get-AzVM will display the VMs from all the Azure Subscriptions.To find the specific Azure VM Subscription name, we will first retrieve the details of the VM using the Get-AzVM and it has an ID property that contains the Subscription ID and from the subscription ID property, we can retrieve the name of the Azure Subscription Name.PS C:\> $azvm = Get-AzVM -Name TestMachine2k16 PS C:\> $subid = ($azvm.Id -split '/')[2] PS C:\> (Get-AzSubscription -SubscriptionId $subid).NameThe above will retrieve the name of the subscription.

How to retrieve the Azure VM resource group using PowerShell?

Chirag Nagrekar
Updated on 17-May-2021 12:06:52

2K+ Views

To retrieve the azure VM resource group using PowerShell, we first need to retrieve the Azure VM details using Get-AZVm and then we can use its property called ResourceGroup.Before getting the details of the Azure VM, make sure that you are connected to the Azure Account using the Connect-AzAccount command.In this example, we are going to retrieve the Azure VM named TestMachine2k16 to retrieve the VM details.$azvm = Get-AzVM -Name TestMachine2k16To get the resource group name, use its property ResourceGroupName.PS C:\> $azvm.ResourceGroupName ANSIBLETESTRG

How to eject the USB device from the system using PowerShell?

Chirag Nagrekar
Updated on 17-May-2021 12:05:55

5K+ Views

To eject the USB device from the system, we first need to get the USB device using PowerShell. WMI class Win32_Volume will help us to find the USB device.We know that all removal devices using the DriveType '2'. So we will filter out the USB device among the listed devices.PS C:\> $usbdev = gwmi win32_volume | where{$_.DriveType -eq '2'}The below commands will helpful to unallocated the USB from the system.PS C:\> $usbdev.DriveLetter = $null PS C:\> $usbdev.Put()OutputPath : \localhost\root\cimv2:Win32_Volume.DeviceID="\\?\Volume{6e4d6f1e-a8c2-11eb-9493-005056c00008}\" RelativePath : Win32_Volume.DeviceID="\\?\Volume{6e4d6f1e-a8c2-11eb-9493-005056c00008}\" Server : localhost NamespacePath : root\cimv2 ClassName : Win32_Volume IsClass : False IsInstance : True IsSingleton : FalseAnd ... Read More

How to check if the USB device is connected to the system using PowerShell?

Chirag Nagrekar
Updated on 17-May-2021 12:01:49

3K+ Views

To retrieve the USB-connected devices using Powershell, we need to retrieve all the drives using the WMI object or CIM Instance and need to filter the win32_diskdrive class with the USB as shown below.So basically, USB devices and other removable devices have the drivetype '2'. You can search with the InterfaceType or the DriveType.WMI commands, gwmi win32_diskdrive | where{$_.Interfacetype -eq "USB"}Alternatively, With the CIM commands, Get-CimInstance -ClassName Win32_DiskDrive | where{$_.InterfaceType -eq 'USB'}orGet-CimInstance -ClassName Win32_LogicalDisk | where{$_.DriveType -eq '2'}If there is no USB device connected to the system, there will be no output. To retrieve the USB disk on the remote ... Read More

What is Non-Functional Testing? Types with Example

Vineet Nanda
Updated on 13-May-2021 12:37:07

6K+ Views

What is Non-Functional Testing?Non-functional Testing is a method of software testing that examines a software application's non-functional attributes (productivity, compatibility, functionality, and many more). It is intended to assess a system's preparation based on nonfunctional conditions that never get covered by functional tests.A good example of a non-functional test is seeing how many users would sign into a program at the same time.Non-functional testing is almost as critical as functional testing, and it has an effect on customer satisfaction.We will discover the following in this tutorial−Non-functional testing objectivesNon-functional testing CharacteristicsTesting for non-functionality variablesSoftware Testing TypesTypes of Non-functional TestingTest Case Examples ... Read More

Top Performance or Load Testing Tools

Vineet Nanda
Updated on 13-May-2021 12:30:52

366 Views

Performance testing is conducted to know how an application responds under extreme load. Such tests are performed using metrics like speed, scalability and stability. Choosing the right performance or load testing tool can offer a wide range of beneficial features. Besides, it also eliminates massive cost and time consumption associated with the manual testing process.Types of performance testsAn application or software goes through several tests to determine its performance. Not all tools support all types of performance testing. Therefore, you may have to determine what type of testing you require and choose the tools as needed.Load testingLoad tests help testers ... Read More

Software Testing Metrics: Definition, Types & Example

Vineet Nanda
Updated on 13-May-2021 12:21:51

7K+ Views

Software Testing metrics are quantitative steps taken to evaluate the software testing process's quality, performance, and progress. This helps us to accumulate reliable data about the software testing process and enhance its efficiency. This will allow developers to make proactive and precise decisions for upcoming testing procedures.What is a metric in software testing metrics?A Metric is a degree to which a system or its components retains a given attribute. Testers don't define a metric just for the sake of documentation. It serves greater purposes in software testing. For example, developers can apply a metric to assume the time it takes ... Read More

How to create a Test Strategy Document?

Vineet Nanda
Updated on 13-May-2021 12:19:32

480 Views

Before learning about Test Strategy Document, you must understand Test Plan. A test plan is a document containing the scope, methods, and objectives of software testing. Since many companies deal with multiple projects, the project team needs to prepare a goal-centric test plan considering the specific requirements of each project.Regardless of the nature of the project (support or development), proper planning remains the significant stepping stone for any testing process. Apart from a brief introduction to the project, the test plan also contains methods and types of testing that testers should execute during the testing.The Test strategy is a document ... Read More

Advertisements