• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Think PowerShell

Think PowerShell

PowerShell for IT Pros

  • About
    • Who I Am
    • Why I Blog
    • Privacy Policy
  • Resources
    • More PowerShell Sites
    • Post Series Index
  • Get Help
  • Show Search
Hide Search

Beginner

Use PowerShell to Set Up a Hyper-V Lab

Aaron Rothstein · October 11, 2016 · 2 Comments

Hyper-V Manager desktop app
Hyper-V Manager desktop app

A Hyper-V lab for your PowerShell sandbox

When learning and playing with new technology like PowerShell, a lab environment is extremely beneficial. Some of the benefits are:

  • A lab environment can be torn down and and rebuilt as needed.
  • Components can be added to or removed from a lab as needed.
  • Actions that are considered risky to perform in a production environment can be performed safely in a contained lab.

Windows 10 Pro, Enterprise, and Education (as well as Windows 8 Pro and Enterprise) come with the same Hyper-V technology that runs in the datacenter, just waiting to be enabled. Here is how to get it installed and configured using PowerShell.

[Read more…] about Use PowerShell to Set Up a Hyper-V Lab

Try PowerShell “-Verbose” to Troubleshoot Errors

Aaron Rothstein · October 5, 2016 · 2 Comments

-Verbose example output.
-Verbose example output.

A real-world example of where using PowerShell “-Verbose” parameter is more efficient than a Google search.

“Couldn’t connect to the source mailbox.”

Recently I needed to export an Exchange 2010 mailbox to a PST file. I opened my Exchange Management Shell and ran New-MailboxExportRequest, only to get the following error:

[PS] C:\Windows\system32>New-MailboxExportRequest -Mailbox jdoe -FilePath \\FileServer1\Exports\jdoe.pst
Couldn't connect to the source mailbox.
    + CategoryInfo          : NotSpecified: (0:Int32) [New-MailboxExportRequest], RemotePermanentException
    + FullyQualifiedErrorId : C7D44FB7,Microsoft.Exchange.Management.RecipientTasks.NewMailboxExportRequest

Why couldn’t it connect to the source mailbox?

[Read more…] about Try PowerShell “-Verbose” to Troubleshoot Errors

PowerShell Replacement for ‘nslookup’

Aaron Rothstein · March 2, 2016 · 9 Comments

nslookup options screenshot

The fourth post in my PowerShell Beginner series, “Daily Tasks, The PowerShell Way“. Use PowerShell’s Resolve-DnsName cmdlet as a more powerful successor to ‘nslookup’.

What’s in a name?

Any seasoned IT Pro knows that the names we see for servers or in web URLs ultimately need to “resolve” or translate to a numerical IP address. Computers perform this resolution using a worldwide network of Domain Name System (DNS) servers. When your browser attempts to go to https://thinkpowershell.com, your computer will send a query to a DNS server with the hostname “thinkpowershell.com”, and the DNS server will return the IP address of the server hosting the website. Your DNS server will likely have to forward a query to other DNS servers to get the correct IP address.

nslookup (name server lookup) is a command line tool that has been around for years for performing this lookup activity on demand. You can specify the hostname or website domain name for which you want to “lookup” the IP address. Additionally, with the second positional parameter you can specify the IP address of a specific DNS server you want to query. It is a helpful tool, but it only returns CNAME , A, and AAAA record information, and not as a script-usable object.

[Read more…] about PowerShell Replacement for ‘nslookup’

PowerShell Replacements for ‘ipconfig’ Client DNS Functions

Aaron Rothstein · February 29, 2016 · Leave a Comment

Screenshot of ipconfig DNS functions.

The third post in my PowerShell Beginner series, “Daily Tasks, The PowerShell Way“. Use PowerShell to replace ipconfig‘s /registerdns, /displaydns, and /flushdns functions, and use for both local and remote computers.

ipconfig: a longtime member of the IT Pro toolbox

Much like ping, ipconfig was a frequently used command line tool for IT Pros. Whether it was getting assigned IP information, releasing and renewing DHCP leases, or investigating DNS client issues, ipconfig was quick go to troubleshooting tool. However, recent versions of Windows and PowerShell have added easy to use cmdlets to replace some of these functions. This post will take a look at the cmdlets related to the DNS client.

[Read more…] about PowerShell Replacements for ‘ipconfig’ Client DNS Functions

Configure Static IP Address or DHCP

Aaron Rothstein · February 23, 2016 · 3 Comments

Windows 10 network connections screenshot.

The second post in my PowerShell Beginner series, “Daily Tasks, The PowerShell Way“. Learn how to get network connection information and configure a static IP or DHCP using PowerShell.

Are you connected?

In my previous post we covered how to use Test-NetConnection for network connectivity troubleshooting. If you connected to a DHCP enabled network, you will likely have successful tests without any action on your part. However, if your network environment requires static configuration of IP addresses and DNS servers for servers and/or workstations, you need to configure the correct network settings for a newly provisioned computer.

[Read more…] about Configure Static IP Address or DHCP

  • « Go to Previous Page
  • Page 1
  • Page 2
  • Page 3
  • Page 4
  • Page 5
  • Go to Next Page »

Primary Sidebar

Aaron

Think PowerShell

Copyright © 2025 · Monochrome Pro on Genesis Framework · WordPress · Log in