<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Tools and Scripts on justinverstijnen.nl</title><link>https://justinverstijnen.nl/tags/tools-and-scripts/</link><description>Recent content in Tools and Scripts on justinverstijnen.nl</description><generator>Hugo</generator><language>en</language><lastBuildDate>Sat, 18 Apr 2026 14:32:09 +0200</lastBuildDate><atom:link href="https://justinverstijnen.nl/tags/tools-and-scripts/index.xml" rel="self" type="application/rss+xml"/><item><title>Remove Microsoft Print to PDF and OneNote printers script</title><link>https://justinverstijnen.nl/remove-microsoft-print-to-pdf-and-onenote-printers-script/</link><pubDate>Mon, 29 Dec 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/remove-microsoft-print-to-pdf-and-onenote-printers-script/</guid><description>&lt;p&gt;By default in Windows 11 with Microsoft 365 apps installed, we have two software printers installed. These are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;OneNote (Desktop)&lt;/li&gt;
&lt;li&gt;Microsoft Print to PDF&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src="https://sajvwebsiteblobstorage.blob.core.windows.net/blog/remove-microsoft-print-to-pdf-and-onenote-printers-script-4319/jv-media-4319-5e8079ca2ffa.png" alt=""&gt;&lt;/p&gt;
&lt;p&gt;However, some users don&amp;rsquo;t use them and they will annoyingly be as default printer sometimes, which we want to avoid. Most software have built-in options to save to PDF, so this is a bit redundant. Our real printers will be further down which causes their own problems for end users.&lt;/p&gt;</description></item><item><title>Windows Server Inventory Report Script</title><link>https://justinverstijnen.nl/windows-server-inventory-report-script/</link><pubDate>Thu, 13 Nov 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/windows-server-inventory-report-script/</guid><description>&lt;p&gt;To help us IT identifying certain configurations on a server and possible misconfigurations I have made a PowerShell script which creates a complete overview of the current server configuration and exports it as a single HTML file.&lt;/p&gt;
&lt;p&gt;In this post I will explain how to use it and how the script works.&lt;/p&gt;
&lt;p&gt;&lt;img src="https://sajvwebsiteblobstorage.blob.core.windows.net/blog/windows-server-inventory-report-script-3866/jv-media-3866-047721edba6f.png" alt=""&gt;&lt;/p&gt;
&lt;p&gt;An example of the output of the script.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="where-to-download-this-script"&gt;Where to download this script?&lt;a class="td-heading-self-link" href="#where-to-download-this-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;For the fast pass, my script can be downloaded here:&lt;/p&gt;</description></item><item><title>Solved - ADSync service stopped (Entra Connect Sync)</title><link>https://justinverstijnen.nl/solved-adsync-service-stopped-entra-connect-sync/</link><pubDate>Mon, 06 Oct 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/solved-adsync-service-stopped-entra-connect-sync/</guid><description>&lt;p&gt;Sometimes, the ADSync service stops without further notice. You will see that the service has been stopped in the Services panel:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://sajvwebsiteblobstorage.blob.core.windows.net/blog/solved-adsync-service-stopped-entra-connect-sync-6576/jv-media-6576-3fafbbf3b1d4.png" alt=""&gt;&lt;/p&gt;
&lt;p&gt;In this guide I will explain how I solved this problem using a simple PowerShell script.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="the-check-adsync-script"&gt;The Check ADSync script&lt;a class="td-heading-self-link" href="#the-check-adsync-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The PowerShell script that fixes this problem is on my GitHub page:&lt;/p&gt;
&lt;p&gt;&lt;a class="btn btn-primary" href="https://github.com/JustinVerstijnen/JV-CheckStartADSyncService"&gt;&lt;i class="fa-brands fa-github"&gt;&lt;/i&gt; Download script from GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The script simply checks if the service is running, if this is the case the script will be terminated. If the service is not running, the service will be started.&lt;/p&gt;</description></item><item><title>Clean files on a schedule with Powershell script</title><link>https://justinverstijnen.nl/clean-files-on-schedule-with-powershell-retention-script/</link><pubDate>Thu, 18 Sep 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/clean-files-on-schedule-with-powershell-retention-script/</guid><description>&lt;p&gt;Sometimes in IT, we have software or solutions that need to to save temporary files in your filesystem. Let&amp;rsquo;s say, a feed with logs or CSV files that are saved, logs or back-ups like the Bartender software. The software itself doesn&amp;rsquo;t have a solution to clean up those files and after 2 years, the size can be massive.&lt;/p&gt;
&lt;p&gt;To let this files clean on schedule I have created a Powershell script which cleans those files in specific folders after they are not modified in *specfied* days . You can define the folders and number of days at the parameters section of the script.&lt;/p&gt;</description></item><item><title>Initial Installation script for Windows Azure VMs</title><link>https://justinverstijnen.nl/initial-installation-script-for-windows-azure-vms/</link><pubDate>Sun, 10 Aug 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/initial-installation-script-for-windows-azure-vms/</guid><description>&lt;p&gt;When deploying Windows VMs in Azure, we get the default settings. This means we get a 12-hour clock, standard UTC/Zulu timezone and such. For users like us in the Netherlands we want to change this but not by hand.&lt;/p&gt;
&lt;p&gt;For this purpose I built this script. It sets the timezone for Western Europe and sets the clock to 24-hour system. It also does some bonusses like responding to ping and disabling the IE Enhanced Security as it&amp;rsquo;s mostly server focussed. We don&amp;rsquo;t change the Windows language and this stays English.&lt;/p&gt;</description></item><item><title>Clean up old FSLogix profiles with Logic Apps</title><link>https://justinverstijnen.nl/clean-up-your-fslogix-profiles-with-logic-apps/</link><pubDate>Thu, 07 Aug 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/clean-up-your-fslogix-profiles-with-logic-apps/</guid><description>&lt;p&gt;I will give you a step-by-step guide to build this Logic App yourself.&lt;/p&gt;
&lt;div class="alert alert-info" role="alert"&gt;
&lt;p&gt;Make sure you have backups ofenabled on your storage account so when a file is deleted but you need it for some reason after some time, you can restore it from a monthly or yearly backup.&lt;/p&gt;
&lt;p&gt;Also: Recover Services storage is much cheaper than live Storage Account storage, keep this in mind when implementing this sort of Logic Apps.&lt;/p&gt;</description></item><item><title>Installing Windows Updates through PowerShell (script)</title><link>https://justinverstijnen.nl/installing-windows-updates-through-powershell-script/</link><pubDate>Sun, 27 Jul 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/installing-windows-updates-through-powershell-script/</guid><description>&lt;p&gt;Sometimes we want to install updates by hand because of the need for fast patching. But logging into every server and installing them manually is a hell of a task and takes a lot of time.&lt;/p&gt;
&lt;p&gt;I have made a very simple script to install Windows Updates by hand using PowerShell including logging to exactly know which updates there were installed for monitoring later on.&lt;/p&gt;
&lt;p&gt;The good part about this script/PowerShell module is that it does support both Windows Client and Windows Server installations.&lt;/p&gt;</description></item><item><title>Audit your Entra ID user role assignments</title><link>https://justinverstijnen.nl/audit-your-entra-id-user-role-assignments/</link><pubDate>Tue, 01 Jul 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/audit-your-entra-id-user-role-assignments/</guid><description>&lt;h2 id="requirements"&gt;Requirements&lt;a class="td-heading-self-link" href="#requirements" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Microsoft Graph PowerShell module&lt;/li&gt;
&lt;li&gt;Entra P2 or Governance license for PIM
&lt;ul&gt;
&lt;li&gt;&lt;em&gt;Only required for fetching PIM specific data. Script can run without licenses.&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;hr&gt;
&lt;h2 id="entra-id-user-role-assignments-script"&gt;Entra ID User role assignments script&lt;a class="td-heading-self-link" href="#entra-id-user-role-assignments-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;To start off with the fast pass, my script can be downloaded here from my Github page:&lt;/p&gt;
&lt;p&gt;&lt;a class="btn btn-primary" href="https://github.com/JustinVerstijnen/JV-EntraIDGetAssignedRoles"&gt;&lt;i class="fa-brands fa-github"&gt;&lt;/i&gt; Download script from GitHub&lt;/a&gt;&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="using-the-entra-id-user-role-assignments-script"&gt;Using the Entra ID User role assignments script&lt;a class="td-heading-self-link" href="#using-the-entra-id-user-role-assignments-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;I have already downloaded the script, and have it ready to execute:&lt;/p&gt;</description></item><item><title>Disk cleaning script on Windows Azure VMs</title><link>https://justinverstijnen.nl/disk-cleaning-script-on-windows-azure-vms/</link><pubDate>Sat, 28 Jun 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/disk-cleaning-script-on-windows-azure-vms/</guid><description>&lt;p&gt;On Windows Servers, a critical point is maintaining the disk space. If a disk fills up to the end, several errors can occur and impacting the end-users experience of your applications. Something we definitely not want.&lt;/p&gt;
&lt;p&gt;To help reducing this chance, I have created a PowerShell script that cleans up your server using built in tools of Windows. In this post, I will explain what the script does, how to install it and how to use it.&lt;/p&gt;</description></item><item><title>Audit your privileged Entra ID applications</title><link>https://justinverstijnen.nl/audit-your-privileged-entra-id-applications/</link><pubDate>Wed, 25 Jun 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/audit-your-privileged-entra-id-applications/</guid><description>&lt;h2 id="entra-id-privileged-applications-report-script"&gt;Entra ID Privileged Applications report script&lt;a class="td-heading-self-link" href="#entra-id-privileged-applications-report-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;To start off with the fast pass, my script can be downloaded here from my Github page:&lt;/p&gt;
&lt;p&gt;&lt;a class="btn btn-primary" href="https://github.com/JustinVerstijnen/JV-EntraIDGetPrivilegedEntApps"&gt;&lt;i class="fa-brands fa-github"&gt;&lt;/i&gt; Download script from GitHub&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This script can be used to get a report of all high privileged applications across the tenant. &lt;a href="https://justinverstijnen.nl/audit-your-privileged-entra-id-applications/#using-my-script-to-audit-all-high-privileged-applications"&gt;Go to this section&lt;/a&gt; for instructions of how to use the script and the output.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="what-are-enterprise-applications"&gt;What are Enterprise Applications?&lt;a class="td-heading-self-link" href="#what-are-enterprise-applications" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Enterprise Applications in Entra ID are the applications which will be registered when users need them. Somethimes, it can be for a add-on of Outlook or Teams, but other times this can be to enable Single Sign On to 3rd party applications.&lt;/p&gt;</description></item><item><title>Test Azure Virtual Desktop connectivity and RTT</title><link>https://justinverstijnen.nl/azure-virtual-desktop-connectivity-script/</link><pubDate>Thu, 22 May 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/azure-virtual-desktop-connectivity-script/</guid><description>&lt;p&gt;I created a script to test the connectivity, if it is allowed through Firewall and also test the RTT to the Azure Virtual Desktop service. The script then gives the following output:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://sajvwebsiteblobstorage.blob.core.windows.net/blog/azure-virtual-desktop-connectivity-script-1649/jv-media-1649-9617996da753.png" alt=""&gt;&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="the-script-to-test-azure-virtual-desktop-connectivity"&gt;The script to test Azure Virtual Desktop connectivity&lt;a class="td-heading-self-link" href="#the-script-to-test-azure-virtual-desktop-connectivity" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;I have the script on my Github page which can be downloaded here:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/JustinVerstijnen/TestRTTAVDConnectivity"&gt;Download TestRTTAVDConnectivity script&lt;/a&gt;&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="what-is-round-trip-time-rtt"&gt;What is Round Trip Time (RTT)?&lt;a class="td-heading-self-link" href="#what-is-round-trip-time-rtt" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;The Round Trip Time is the time in milliseconds of an TCP packet from its source to it&amp;rsquo;s destination and from destination back to the source. It is like ping, but added with the time back like described in the image below:&lt;/p&gt;</description></item><item><title>Windows Search optimization on Azure Virtual Desktop</title><link>https://justinverstijnen.nl/windows-search-optimization-azure-virtual-desktop/</link><pubDate>Thu, 15 May 2025 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/windows-search-optimization-azure-virtual-desktop/</guid><description>&lt;p&gt;&lt;a href="https://sajvwebsiteblobstorage.blob.core.windows.net/blog/windows-search-optimization-azure-virtual-desktop-3737/jv-media-3737-445bd67fa9ae.mp4"&gt;The video&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;In this video you will see that it takes around 5 seconds till I can begin searching for applications and Windows didnt respond to the first click. This is on a empty session host, so in practice this is much slower.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="how-to-solve-this-minor-issue"&gt;How to solve this minor issue?&lt;a class="td-heading-self-link" href="#how-to-solve-this-minor-issue" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;We can solve this issue by running a simple script on startup that opens the start menu, types in some dummy text and then closes. In my experience, the end user actually likes this because waiting on Windows Search the first time on crowded session hosts can take up to 3 times longer than my &amp;ldquo;empty host&amp;rdquo; example. I call it &amp;ldquo;a stupid fix for a stupid problem&amp;rdquo;.&lt;/p&gt;</description></item><item><title>Create AD users with on demand script</title><link>https://justinverstijnen.nl/create-ad-users-with-on-demand-script/</link><pubDate>Fri, 27 Dec 2024 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/create-ad-users-with-on-demand-script/</guid><description>&lt;p&gt;Today I have a PowerShell script that creates users by asking the user what to fill in. This works by having a fully prepared &amp;ldquo;New-ADUser&amp;rdquo; command with all the properties filled in to have all users using the same attributes.&lt;/p&gt;
&lt;p&gt;I will explain how this script works on this page.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="the-create-ad-users-on-demand-script"&gt;The create AD users on demand script&lt;a class="td-heading-self-link" href="#the-create-ad-users-on-demand-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;For the fast pass, the script can be downloaded from my GitHub page:&lt;/p&gt;</description></item><item><title>How to Export Active Directory (AD) users fast and easy</title><link>https://justinverstijnen.nl/how-to-export-active-directory-ad-users-fast-and-easy/</link><pubDate>Thu, 14 Nov 2024 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/how-to-export-active-directory-ad-users-fast-and-easy/</guid><description>&lt;p&gt;Sometimes we need to export all of our AD users. The one time for applying changes, sometimes for monitoring the inventory but often for licensing purposes.&lt;/p&gt;
&lt;p&gt;At this page I will show you how to export all your AD users fast and easy.&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="the-export-ad-users-script"&gt;The Export AD users script:&lt;a class="td-heading-self-link" href="#the-export-ad-users-script" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;For the fast pass, I uploaded the script to my Github page:&lt;/p&gt;
&lt;p&gt;&lt;a class="btn btn-primary" href="https://github.com/JustinVerstijnen/JV-ExportADUsers"&gt;&lt;i class="fa-brands fa-github"&gt;&lt;/i&gt; Download script from GitHub&lt;/a&gt;&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id="how-to-export-the-ad-users-by-hand"&gt;How to export the AD users by hand&lt;a class="td-heading-self-link" href="#how-to-export-the-ad-users-by-hand" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;To export the users without using a script, navigate to your Active Directory management server and open up Powershell. We will do all the action the script above does, but then by hand and type in every command separately.&lt;/p&gt;</description></item><item><title>Set correct language and timezone on Azure VM</title><link>https://justinverstijnen.nl/set-correct-language-and-timezone-on-azure-vm/</link><pubDate>Thu, 10 Oct 2024 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/set-correct-language-and-timezone-on-azure-vm/</guid><description>&lt;p&gt;By default, all Azure VMs are set to English language and UTC/Zulu timezone. This will work for a great portion of the Azure VM users but there are users in other parts of the world too. Like in the Netherlands, where I live we are 1 or 2 hours ahead of that timezone depending on the season.&lt;/p&gt;
&lt;p&gt;Also, in the case of Azure Virtual Desktop, we want to present our users their native language as system language. For this case, I have made a script to correct those settings.&lt;/p&gt;</description></item><item><title>Get Windows Product Key with PowerShell</title><link>https://justinverstijnen.nl/get-windows-product-key-with-powershell/</link><pubDate>Sun, 28 Jul 2024 00:00:00 +0000</pubDate><guid>https://justinverstijnen.nl/get-windows-product-key-with-powershell/</guid><description>&lt;p&gt;We simply can do this with one command in PowerShell:&lt;/p&gt;
&lt;p&gt;
 &lt;div class="td-card card border me-4"&gt;
&lt;div class="card-header code"&gt;
 &lt;strong&gt;POWERSHELL&lt;/strong&gt;
 &lt;/div&gt;
&lt;div class="card-body code p-0 m-0"&gt;
 &lt;div class="highlight"&gt;&lt;pre tabindex="0" class="chroma"&gt;&lt;code class="language-powershell" data-lang="powershell"&gt;&lt;span class="line"&gt;&lt;span class="cl"&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nb"&gt;Get-ItemProperty&lt;/span&gt; &lt;span class="n"&gt;-Path&lt;/span&gt; &lt;span class="s2"&gt;&amp;#34;HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform&amp;#34;&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="n"&gt;BackupProductKeyDefault&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
 &lt;/div&gt;

&lt;img src="https://sajvwebsiteblobstorage.blob.core.windows.net/blog/get-windows-product-key-with-powershell-3681/jv-media-3681-3a0bbc0e5409.png" alt=""&gt;&lt;/p&gt;
&lt;p&gt;Please note that I am not encouraging software abuse or pirating, just sharing a tip to make our IT life a bit easier. It happens that a server or computer gets installed and we forget to document the product key or just to match it with our known information.&lt;/p&gt;
&lt;script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-4082816808518335"
 crossorigin="anonymous"&gt;&lt;/script&gt;
&lt;ins class="adsbygoogle"
 style="display:block; text-align:center;"
 data-ad-layout="in-article"
 data-ad-format="fluid"
 data-ad-client="ca-pub-4082816808518335"
 data-ad-slot="9865066433"&gt;&lt;/ins&gt;
&lt;script&gt;
 (adsbygoogle = window.adsbygoogle || []).push({});
&lt;/script&gt;
&lt;p&gt; &lt;/p&gt;</description></item></channel></rss>