Posts

Showing posts from July, 2021

How to download a file using PowerShell?

Image
Today I came across a nice and simple command for downloading files from the web. It is very simple but also very powerful. Command:   Invoke-WebRequest -Uri http://ipv4.download.thinkbroadband.com/50MB.zip -OutFile .\50MB.zip What this command does is, downloading a 50 MB test file from thinkbroadband.com to your own computer and put it in your current path. In this example on my Desktop. You can of cause easily change both the url for the file you want to download and the target location changing the -Outfile parameter. Lets say you want to download a file every day and name the file with day of the day, you can use the following two commands: $filename = Get-Date -Format "dd-MM" Invoke-WebRequest -Uri http://212.183.159.230/200MB.zip -OutFile .\$filename.zip

How to check if your computer have a TPM chip

Image
How to detect a TPM chip using PowerShell Microsoft have stated that a TPM chip will be a hardware requirement for running Windows 11 . To help you detect if your computer is compliant with that I would like to share a script for just that. Be aware that not just your computer need a TPM chip. It also has to be a version 2.0 chip. Get-Tpm command can help you detect if you have a TPM chip in your computer. In order to detect of your computers TPM chip is version 2.0 you can run the following command: Get-WMIObject -computer localhost -class Win32_Tpm -Namespace root\cimv2\Security\MicrosoftTpm  | select PsComputerName,SpecVersion,manufacturerVersion,manufactureridtxt | fl If the first command state that TPMPresent is False, you might want to check if it is because the chip has just been disabled in BIOS/UEFI. That was the case on my computer. Check the manual of your motherboard. It might not be called TPM in your BIOS/UEFI settings. Here is an example:  

Popular posts from this blog

Use PowerShell to Discover Network Switch and port number

How to get Public IP Using PowerShell

Use ChatGPT to write PowerShell Scripts