The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,984 other followers

Archive for the ‘Windows 10’ Category

“This app can’t run on your PC – To find a version for your PC, check with the software publisher.”

Posted by jpluimers on 2020/06/19

I had a problem running wmic. It was no a Dutch Windows 10, but the same will happen with any locale, so in English the error looks like this:

This app can't run on your PC

To find a version for your PC, check with the software publisher.

After which you get this on the command-line:

Access is denied.

In the Dutch version, the error is called this:

Deze app kan niet worden uitgevoerd op uw pc

Vraag bij de software-uitgever na of er een versie bestaat voor uw pc.

After which you get this on the command-line:

Toegang geweigerd.

Apparently, an executable is now an app, and PC is uppercase in English, but not in Dutch. I digress.

The un-cool thing is that [WayBack] Process Monitor – Windows Sysinternals | Microsoft Docs showed no Access Denied message at all.

What happened however, was that there was an empty %SystemRoot%\System32\wmic.exe, which gets executed because %SystemRoot%\System32 is earlier on the path than C:\Windows\System32\wbem\WMIC.exe.

Note that %SystemRoot% seems to be the new %windir%.

You can reproduce this by doing this on a command prompt window:

cd %temp%

rem > wmic.exe

wmic

The rem will create an empty wmic.exe. Because on Windows, the current directory is always on the path, it tries to execute the empty wmic.exe, which causes the error.

Do not run an administrative in the default %SystemRoot%\System32 directory

The actual cause was a combination of this:

  1. When running cmd as Administrator, it starts in %SystemRoot%\System32
  2. %SystemRoot%\System32 is early on the path
  3. Copy/Paste through a remote desktop connection is unreliable
  4. I copied a big bunch of output from the RDP session to my host to write some documentation
  5. I copied a new command from the host to run in the Administrative cmd
  6. What got pasted instead was the output, which created these empty files (which has some typos, I know) because output is of the form C:\path>filename:

    C
    conrol
    control
    defrag
    del
    Disable-ComputerRestore
    exit
    Get-ComputerRestorePoint
    net
    powercfg
    powershell
    powrcfg
    SystemProperties.exe
    vssadmin
    wmic
    wmic.exe

  7. I did not notice these files were created in  %SystemRoot%\System32

–jeroen

Posted in Power User, Windows, Windows 10 | Leave a Comment »

“windows 10” cannot manually set time – Google Search

Posted by jpluimers on 2020/06/12

On my research list: a Windows 10 machine with automatic time settings being 2 hours off.

I tried setting time and time zone, but the new Windows 10 UI did not let me.

List to start

–jeroen

Posted in Power User, Windows, Windows 10 | Leave a Comment »

hardlink – How can I find hard links on Windows? – Super User

Posted by jpluimers on 2020/06/08

Cool:

use command:

fsutil hardlink list MyFileName.txt

It lists all hardlinks to file with name MyFileName.txt.

Source: [WayBackhardlink – How can I find hard links on Windows? – Super User

More information at [WayBack] Fsutil hardlink | Microsoft Docs on

fsutil hardlink create <NewFileName> <ExistingFileName>
fsutil hardlink list <Filename>

–jeroen

Posted in Power User, Windows, Windows 10, Windows 7, Windows 8, Windows 8.1 | Leave a Comment »

Chocolatey and TLS since early 2020

Posted by jpluimers on 2020/03/19

I was upgrading a few older systems that had been off-line for quite a while.

When installing Chocolatey, I bumped into this error:

C:\bin>"%SystemRoot%\System32\WindowsPowerShell\v1.0\powershell.exe" -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin"
Exception calling "DownloadString" with "1" argument(s): "The request was aborted: Could not create SSL/TLS secure channel."
At line:1 char:1
+ iex ((New-Object System.Net.WebClient).DownloadString('https://chocol ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : WebException

So I tried [WayBack] chocolatey “The request was aborted: Could not create SSL/TLS secure channel.” – Google Search

Results indicated TLS 1.1 support was removed early February 2020 from Chocolatey because of security reasons, which impacts the installation on older systems:

Note [WayBack] Chocolatey install Error: The request was aborted: Could not create SSL/TLS secure channel – Stack Overflow with a temporary workaround for Microsoft Windows Server 2016:

Looks like the security protocol changed:

Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))

–jeroen

Posted in Chocolatey, Power User, Windows, Windows 10, Windows 7, Windows 8, Windows 8.1, Windows Server 2016 | Leave a Comment »

Fixing “one or more critical volumes is not having enough free space” also known as 0x81000033 during Windows backup

Posted by jpluimers on 2020/02/03

If you get this error:

Backup and Restore failed and you receive the following error message: The backup did not complete successfully. Check your backup: Windows Backup skipped backing up system image because one or more critical volumes is not having enough free space.

then you are dealing with error 0x81000033 which usually means your SYSTEM RESERVED partition is full, but might happen on other volumes you are backing up as well.

Windows tries to trick your mind, as the error actually indicates the disk you make your backup to, but in fact it is about one or more of the disks you are backing up.

Most often, this is the hidden partition SYSTEM RESERVED (sometimes called System Reserved):

The SYSTEM RESERVED partition (~100 megabyte on systems originally installed with Windows < 8 and ~350 megabyte afterwards) contains files relating to boot, recovery and BitLocker drive encryption. You find more information about it here:

The minimum free size for volumes when using Windows backup are these:

  • volumes less than 500 megabytes: 50 megabytes free space
  • between 500 megabytes and 1 gigabytes: 320 megabytes of free space
  • more than 1 gigabytes: at least 1 gigabyte of free space

That was indeed the case on my disk:

Freeing space on the System Reserved volume

A quick search for 0x81000033 reveals space issues usually are about the USN Journal which you can configuring using fsutil.

Even though the documentation doesn’t tell, fsutil accepts not just a drive letter as VolumePath, but also a VolumeName. [WayBack] 1_multipart_xF8FF_3_WolfC07.pdf (Chapter 7 of “Troubleshooting Microsoft Technologies: The Ultimate Administrator’s Repair Manual“) gets that right:

volumepath … specify the path to a logical volume (drive letter, mount path, volume name).

So you do not need a drive letter to disable the USN journal, the volumename suffices.

This volume name is the unique NTFS identification for a volume: [WayBack] NTFS Curiosities (part 2): Volumes, volume names and mount points – Antimail

You can find the volume name inside PowerShell by using Get-Volume | Format-List, then on an administrative command prompt running this:

fsutil usn deletejournal /D \\?\Volume{b41b0670-0000-0000-00e8-0e8004000000}\

In my case this wasn’t enough, so I had to assign a drive letter to see that there was a snapshots directory in the root:

Deleting that directory solved the problem.

Related articles:

–jeroen

Read the rest of this entry »

Posted in Power User, Windows, Windows 10, Windows 7, Windows 8, Windows 8.1 | Leave a Comment »

 
%d bloggers like this: