powershell
2 TopicsWindows Servers Uptime Report using PowerShell
Hi Folks, A customer has mix of Windows servers (2012, 2016, 2019) on-premises environment. Customer needs to generate a report via PowerShell about the availability of servers. During my search I found a script on this link and its modified version is attached. Please note, this script reads windows events and based on that produces result. There is a problem where I need help, this script doesn't run against list of servers via a CSV file or a text file and we suspect it is not producing correct result. Can somebody please review this script and help us with the right syntax or what is missing here? Thanks in advance.1.2KViews0likes1Commentquick assist deployment thru Powershell-GPO
Since that Microsoft is turned with quick assist to the Windows Store we cannot use Quick assist anymore. I cannot install / deploy it thru Powershell whatever i try thru GPO, manual, scheduled task etc, it will not work. The only way that the install succeeds is when go to the Store and download and install it when i am an admin. But i want to deploy Quick Assist thru Powershell... What i tried: #sets switches param ( [Parameter(Mandatory=$false)][Switch]$Install, [Parameter(Mandatory=$false)][Switch]$Uninstall, [Parameter(ValueFromRemainingArguments=$true)] $args ) #Log output results function LogOutput($Message) { $LogFile = "C:\temp\Quick-Assist.log" "$(get-date -Format 'MM/dd/yyyy HH:mm') $($Message)" | Out-file -FilePath $LogFile -Append -Force } #Start of Script If ($Install){ Try { LogOutput "***This script is used to install the new Quick Assist app that is from the Microsoft Store. It will also remove the old version***" $InstallAppX = Get-AppxPackage -allusers MicrosoftCorporationII.QuickAssist If ($InstallAppX.status -eq 'OK'){ LogOutput "[Info] Windows Store version of Quick Assist is already installed" #lets uninstall the old version. LogOutput "[Info] lets uninstall the old version" Remove-WindowsCapability -Online -Name 'App.Support.QuickAssist~~~~0.0.1.0' -ErrorAction 'SilentlyContinue' LogOutput "[Info] Old version of Quick Assist has been uninstalled" } If ($InstallAppX.status -ne 'OK'){ LogOutput "[Info] Installing the Windows Store version of Quick Assist..." Add-AppxPackage -Path "c:\quickassist\MicrosoftCorporationII.QuickAssist.AppxBundle" #Add-AppxProvisionedPackage -online -SkipLicense -PackagePath '.\MicrosoftCorporationII.QuickAssist.AppxBundle' LogOutput "[Info] Attempting to remove the old version of Quick Assist..." Remove-WindowsCapability -Online -Name 'App.Support.QuickAssist~~~~0.0.1.0' -ErrorAction 'SilentlyContinue' } LogOutput "[Success] The Windows store version of Quick assist has successfully installed and the old version has been removed." } catch [exception] { LogOutput "[Error] An error occurred installing Quick Assist: $($_.Exception.Message)" } } We are using windows 10 21h1-2 Problem with this script is also that it says it removes the old version and installed the new version successfully, and when i look with get-package.... it also states that quick assist package is installed, but it is not in the startmenu anymore.... How can i deploy quick assist best for many computers without Intunes or sccm?18KViews0likes5Comments