Currently browsing category


Enhanced profile – Display my custom functions

Somehow, I can be compared to a goldfish : my memory is really, really poor… And I do eat fish! But no, I can’t help…
Sometimes I wrote a usefull function that I embed in my profile and some weeks after (ok, even the very next day) I forget about it… So, here’s my solution: list these functions in a MOTD way. Each time I open a PowerShell console, the list is displayed and my memory gets refreshed.


Here’s a very simple but usefull function to have a view on which Virtual Machine is currently running (or not, there a State column!) on which node of a MSCS failover cluster.


The Invoke-Sqlcmd cmdlet is a SQL Server cmdlet that runs scripts that contain statements from the languages (Transact-SQL and XQuery) and commands that are supported by the sqlcmd utility.
Great! Let’s use it.

The term ‘invoke-sqlcmd’ is not recognized as the name of a cmdlet, function, script file, or operable program.


Here’s a simple function to get a “readable” value of the uptime for the local computer (by default, but there’s a ‘Server’ parameter), and the last boot date/time.

Get-UptimeDays | Get-Uptime


A promise is a promise, here’s my second (planned) application around MD5 hash: a function to copy files and check that the MD5 hash of the copied file is equal to the MD5 hash of the source file.

SafeCopy | Check-MD5 | BruteForceMD5


Here’s a great function to generate the MD5 hash of a specified string.

Scroll to Top