Sometimes a PowerShell script should just produce something, for example a report, which then opens in Excel or notepad. You don’t want to...
posts-powershell
Categories
- Free tools
- SQL Admin Toolset
- SQL Compliance Manager
- SQL Defrag Manager
- SQL Diagnostic Manager for MySQL
- SQL Diagnostic Manager for SQL Server
- SQL Diagnostic Manager Pro
- SQL Doctor
- SQL Enterprise Job Manager
- SQL Inventory Manager
- SQL Query Tuner for SQL Server
- SQL Safe Backup
- SQL Secure
- SQL Workload Analysis for SQL Server
- Uptime Infrastructure Monitor Formerly Uptime
Tags
Administration agent-based monitoring Agentless Monitoring alert responses alert thresholds alerting Alerts Amazon Aurora Amazon EC2 Amazon RDS Amazon RDS / Aurora Amazon RDS for SQL Server Amazon Redshift Amazon S3 Amazon Web Services (AWS) Analytics application monitoring Aqua Data Studio automation availability Azure Azure SQL Database azure sql managed instance Azure VM backup Backup and recovery backup and restore backup compression backup status Backup Strategy backups big data Blocking bug fixes business architecture business data objects business intelligence business process modeling business process models capacity planning change management cloud cloud database cloud database monitoring cloud infrastructure cloud migration cloud providers Cloud Readiness Cloud Services cloud storage cloud virtual machine cloud VM clusters code completion collaboration compliance compliance audit compliance audits compliance manager compliance reporting conference configuration connect to database cpu Cross Platform custom counters Custom Views customer survey customer testimonials Dark Theme dashboards data analysis Data Analytics data architect data architecture data breaches Data Collector data governance data lakes data lineage data management data model data modeler data modeling data models data privacy data protection data security data security measures data sources data visualization data warehouse database database administration database administrator database automation database backup database backups database capacity database changes database community database connection database design database developer database developers database development database diversity Database Engine Tuning Advisor database fragmentation database GUI database IDE database indexes database inventory management database locks database management database migration database monitoring database navigation database optimization database performance Database Permissions database platforms database profiling database queries database recovery database replication database restore database schema database security database support database synchronization database tools database transactions database tuning database-as-a-service databases DB Change Manager DB Optimizer DB PowerStudio DB2 DBA DBaaS DBArtisan dBase DBMS DDL Debugging defragmentation Demo diagnostic manager diagnostics dimensional modeling disaster recovery Download drills embedded database Encryption End-user Experience entity-relationship model ER/Studio ER/Studio Data Architect ER/Studio Enterprise Team Edition events execution plans free tools galera cluster GDPR Getting Started Git GitHub Google Cloud Hadoop Healthcare high availability HIPAA Hive hybrid clouds Hyper-V IDERA IDERA ACE Index Analyzer index optimization infrastructure as a service (IaaS) infrastructure monitoring installation Integrated Development Environment interbase Inventory Manager IT infrastructure Java JD Edwards JSON licensing load test load testing logical data model macOS macros managed cloud database managed cloud databases MariaDB memory memorystorage memoryusage metadata metric baselines metric thresholds Microsoft Azure Microsoft Azure SQL Database Microsoft PowerShell Microsoft SQL Server Microsoft Windows MongoDB monitoring Monitoring Tools Monyog multiple platforms MySQL news newsletter NoSQL Notifications odbc optimization Oracle PeopleSoft performance Performance Dashboards performance metrics performance monitoring performance schema performance tuning personally identifiable information physical data model Platform platform as a service (PaaS) PostgreSQL Precise Precise for Databases Precise for Oracle Precise for SQL Server Precise Management Database (PMDB) product updates Project Migration public clouds Query Analyzer query builder query monitor query optimization query performance Query Store query tool query tuning query-level waits Rapid SQL rdbms real time monitoring Real User Monitoring recovery regulations relational databases Releases Reporting Reports repository Restore reverse engineering Roadmap sample SAP Scalability Security Policy Security Practices server monitoring Server performance server-level waits Service Level Agreement SkySQL slow query SNMP snowflake source control SQL SQL Admin Toolset SQL CM SQL code SQL coding SQL Compliance Manager SQL Defrag Manager sql development SQL Diagnostic Manager SQL Diagnostic Manager for MySQL SQL Diagnostic Manager for SQL Server SQL Diagnostic Manager Pro SQL DM SQL Doctor SQL Enterprise Job Manager SQl IM SQL Inventory Manager SQL Management Suite SQL Monitoring SQL Performance SQL Quality SQL query SQL Query Tuner SQL Safe Backup SQL script SQL Secure SQL Security Suite SQL Server sql server alert SQL Server Migration SQL Server Performance SQL Server Recommendations SQL Server Security SQL statement history SQL tuning SQL Virtual Database sqlmemory sqlserver SQLyog Storage Storage Performance structured data Subversion Support tempdb tempdb data temporal data Tips and Tricks troubleshooting universal data models universal mapping unstructured data Uptime Infrastructure Monitor user experience user permissions Virtual Machine (VM) web services webinar What-if analysis WindowsPowerShellTime Zone Management in PowerShell 5.1
PowerShell 5.1 (available on Windows 10 and Server 2016) comes with some new cmdlets to manage computer time zones. Get-TimeZone returns the current...
Exploring Function Source Code
The only fundamental difference between cmdlets and functions in PowerShell is the way how they are programmed: functions use plain PowerShell code,...
Running 32-bit Code on the Same Machine
If you need to run 32-bit PowerShell code from within a 64-bit script, and provided you are Administrator and use remoting, you can remote against...
Modern Replacement for systeminfo.exe
For ages, systeminfo.exe returned all profiling information for a computer, and could made object-oriented in Powershell – somewhat: PS...
Built-In Support for Local Accounts
Beginning in PowerShell 5.1, there is finally built-in support for local user accounts. PowerShell 5.1 is currently available with Windows 10 and...
Careful with Add-Member!
Frequently, Add-Member is used to create custom objects, for example like this: $o = New-Object -TypeName PSObject $o | Add-Member -MemberType...
How PSCustomObject Really Works
In a previous tip we explained how PSCustomObject can create new objects really fast: $o = [PSCustomObject]@{ Date = Get-Date BIOS = Get-WmiObject...
Fast Approach to Creating New Objects
To wrap up multiple pieces of information, you best store them in custom objects. The easiest and fastest way is to use the PSCustomObject:...
Exploiting Your Command History
PowerShell “records” all your interactive command input to its command history, and Get-History shows them. If you played around with...
Getting Latest PowerShell Gallery Module Version
On www.powershellgallery.com, Microsoft hosts a public script and module repository where you can exchange PowerShell code with others (see more on...
Testing Files and Folders (separately)
Test-Path is highly useful to test whether a file or folder exists, and it can be used with any of the PowerShell drives, so it can also test...
Getting Help for Cmdlet Parameters
There seems to be a bug in PowerShell 5.0 that limits the usefulness of the built-in help window. Whenever you run Get-Help with -ShowWindow, the...
Updating PowerShell Help with One-Liner
To get the most out of PowerShell, you should at least update PowerShell help once. This downloads and installs the base set of help files that show...
Getting IntelliSense for Cmdlet (PowerShell ISE)
If you’re reviewing some PowerShell code loaded into the PowerShell ISE, it’s really simple to get additional information. Click the...
Downloading Pictures from Website
There are awesome websites out there, and one is www.metabene.de (at least for German visitors)-- on 33 pages, the artist presents his drawings for...
Simple Strategy for Cmdlet Error Reporting
In PowerShell, you can create complex error handlers but sometimes you might just want to know what went wrong so you can log it. No overkill...
Check File Names for Illegal Characters
File names are quite sensitive and may not contain a number of reserved characters. To validate file names and make sure they are legal, here is a...
Finding Illegal Characters in Paths (File System)
Previously we illustrated how you can use a simple RegEx-based approach to find illegal characters in strings. We encourage you to expand this...
Finding Multiple Illegal Characters
Previously, we illustrated how to use the -match operator to find illegal characters in a text. The -match operator finds only the first match,...
Checking Email Addresses (and Other Text) for Illegal Chars
Here is a quick approach to do sanity checks and validate data. Let’s assume you’d like to find out whether an email address contains...
PowerShell Remoting and HTTP 403 Error
If you use PowerShell remoting and get “HTTP 403” errors, one of the more obscure reasons for this is a proxy that interferes with your...
Enabling CredSSP Trust from One Side
As previously shown, CredSSP can be used to remote code without double hop issues. To use CredSSP authentication, though, you need to make...
Solving Double Hop Remoting with CredSSP
In a previous tip we illustrated the double hop problem that can occur in remoting when your remote code tries to authenticate against a third...
Understanding the Double-Hop Problem in Remoting
Whenever you execute PowerShell code remotely with Invoke-Command, your credentials are locked to the machine you initially contacted. PowerShell...
Finding Hidden Autostart Programs
Ever wondered why some programs launch whenever you log into Windows? Here’s a one liner listing autostarts that affect your login: #requires...
Getting List of Current Group Memberships
While you can contact the Active Directory to retrieve a list of group memberships for a user, a much easier way gets that information directly from...
Translating SID to Username
Ever wanted to translate a security identifier (SID) to the real name? Here is a function helping you: #requires -Version 3.0 function...
Get GeoLocation of Computer
Here is yet another free source of geolocation information, exposing your current public IP and location information: #requires -Version 3.0...
Finding Operating System Architecture Information
Here is a one-liner that retrieves information about your operating system: Get-WmiObject -Class Win32_OperatingSystem | Select-Object -Property...