- Split-brain DNS deployment using Windows Server DNS policy - Wed, Nov 30 2022
- Veeam Backup for Microsoft 365—Why you need to back up your M365 data - Tue, Nov 15 2022
- Cloud-based patch management with Action1 - Tue, Nov 8 2022
Are you a Windows system administrator that has been in awe of the Linux ability to easily install, update, and change software from the command line? Let's face it, installing, managing, and updating Windows software is anything but easy. In fact, it can be a time-consuming and very manual process in many cases.
While PowerShell has certainly made things much easier, it still does not equal the ease of the built-in package management functionality provided in most Linux distros. Microsoft released major news at the Build 2020 developer conference about an exciting new feature coming to Windows—native package management. Let's take a look at the new package management built into forthcoming versions of Windows, which are currently available in preview.
Native Windows package management with winget ^
There have been many tools that Windows Server administrators have relied on to come close to the functionality of Linux when it comes to package management. Chocolatey is a popular third-party add-on that offers similar software management functionality in Windows to what developers and admins get with Linux.
However, the rub with Windows admins for decades now is that there is no native solution for package and software management in Windows. At the Build 2020 developer conference, Microsoft announced the introduction of winget.
What is winget? Winget is part of the Windows Package Manager feature that is being introduced in preview form to Windows. It is essentially the client interface to the Windows Package Manager service. From the command line, the winget tool allows you to interact with the Windows Package Manager service to discover, install, upgrade, remove, and configure applications in preview versions of the Windows 10 operating system.
One interesting thing to note about the winget command line utility is that, at least in its current form, it is only being pitched as a Windows client operating system tool that is used to install software that developers and IT admins need. Thus far, there hasn't really been much disclosure from Microsoft or discussion as to the roadmap of the tool on Windows Server operating systems.
However, Microsoft points out that the winget tool and the Windows Package Manager are in preview and states:
The winget tool is currently a preview, so not all planned functionality is available at this time.
There are some very interesting questions that come up about the future of winget when it comes to installing Windows updates on Windows Servers. Will Microsoft make winget the command line tool that will allow installing Windows updates, feature upgrades, core components, and other tasks?
These are still questions to be answered. However, I have a feeling that Microsoft has big plans for the utility and the Windows Package Manager service. It would be surprising if they left this as a simple application installer for Windows client operating systems only. Time will tell. In the meantime, let's take a look at the winget utility, how it is installed, and how you use it.
Installing Windows Package Manager winget ^
First of all, what are the prerequisites for installing the winget application in Windows 10? There are only a couple to mention:
- You need to be running Windows 10 version 0 or higher
- Architecture requirements: x86, ARM, x64
Microsoft has made installing the Windows Package Manager winget utility fairly simple. Open the Microsoft Store in Windows 10 and look for App Installer. Once you find it in the search, click the Get button to begin the install.
Next, we will verify the installation of the winget utility by opening a terminal (either command prompt or PowerShell works), and typing winget to make sure the new Windows Package Manager client is installed. Below is a side-by-side view of winget launched from both the command prompt and PowerShell.
As you can see, there are several options available for the command:
- Install: Installs the given application
- Show: Shows info about an application
- Source: Manage application sources
- Search: Find and show basic info about apps
- Hash: Helper to hash installer files
- Validate: Validates a manifest file
Let's take a look at installing Notepad++ with winget to see how easy the new command line package manager makes the installation.
To install Notepad++ using winget, simply use the winget command:
- Winget install Notepad++
The winget tool automatically downloads the Notepad++ package and begins the installation in a very similar fashion to that of Linux.
After only a few moments, the Notepad++ package is successfully installed in Windows 10.
A quick check of the start menu in Windows 10 reveals that the Notepad++ application is successfully installed in the Windows 10 preview installation.
With only a single command line step, you can install applications, utilities, and other software using the new winget utility.
Wrapping up ^
Microsoft has introduced really great capabilities as of late, especially in the preview builds of Windows. The new Windows Package Manager service, which makes use of the new winget command line tool, is a great new feature that Windows administrators and developers alike will be excited about.
This new "Linux like" tool is already showing great promise in its ability to simply and easily install applications from the command line. The ease of installing applications in Windows Server with it will help to even the playing field between Windows and Linux with native package management.
As mentioned, it is yet to be seen how this new tool and feature set will be implemented in the Windows Server realm. Will it be able to maintain Windows updates? Will it be used to apply future Windows Server patches and other features?
Subscribe to 4sysops newsletter!
While Microsoft is quiet on this subject with the current documentation, I have a feeling we will see this new command line tool make its way over to the Windows Server side of things to help administrators manage Windows Server software updates and other day-to-day operations.