logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
silversword  
#1 Posted : Thursday, July 14, 2016 4:28:09 PM(UTC)
silversword


Rank: Member

Medals: Level 1: Random Act of Kindness! Received One Thanks!

Joined: 6/17/2013(UTC)
Posts: 25

Thanks: 10 times
Was thanked: 2 time(s) in 2 post(s)
Running this in the native windows Powershell ISE works:

powershell Get-ItemProperty -Path 'hklm:software\microsoft\windows\currentversion\DeliveryOptimization\Config' -Name "DODownloadMode"

DODownloadMode : 3
PSPath : Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\software\microsoft\windows\currentversion\DeliveryOptimization\Conf
ig
PSParentPath : Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\software\microsoft\windows\currentversion\DeliveryOptimization
PSChildName : Config
PSDrive : HKLM
PSProvider : Microsoft.PowerShell.Core\Registry



When trying to run in the screenconnect commands toolbox:

powershell Get-ItemProperty -Path 'hklm:software\microsoft\windows\currentversion\DeliveryOptimization\Config' -Name "DODownloadMode"

I get the error:
C:\Windows\system32>powershell Get-ItemProperty -Path 'hklm:software\microsoft\windows\currentversion\DeliveryOptimization\Config' -Name "DODownloadMode"
Get-ItemProperty : Cannot find path
'HKLM:\software\microsoft\windows\currentversion\DeliveryOptimization\Config'
because it does not exist.
At line:1 char:1
+ Get-ItemProperty -Path 'hklm:software\microsoft\windows\currentversio ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (HKLM:\software\...mization\Conf
ig:String) [Get-ItemProperty], ItemNotFoundException
+ FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.GetIt
emPropertyCommand

I'm thinking it's not formatting the text strings with \'s properly?

Thx,
David
Scott  
#2 Posted : Tuesday, July 19, 2016 1:01:44 PM(UTC)
Scott


Rank: Administration

Medals: Level 4: Wise Old Owl! Received 100 Thanks!

Joined: 3/28/2014(UTC)
Posts: 2,490
United States

Thanks: 3 times
Was thanked: 305 time(s) in 262 post(s)
Hmm, while I don't have that exact key, I can't find one that will cause that problem.

What version of ScreenConnect are you using?

Does this command fail against any Guest machine or just a specific few?
ScreenConnect Team
silversword  
#3 Posted : Tuesday, July 19, 2016 3:10:08 PM(UTC)
silversword


Rank: Member

Medals: Level 1: Random Act of Kindness! Received One Thanks!

Joined: 6/17/2013(UTC)
Posts: 25

Thanks: 10 times
Was thanked: 2 time(s) in 2 post(s)
This is the registry key in all Windows 10 that changes Start Menu | Settings | Update and Security | Windows Update | Advanced Options | Choose how updates are delivered. 0 is off. 1 is "PCs on my local network" and 3 is "PCs on my local network, and PCs on the Internet"

I just tried it on 5 different win10 machines, all the same error. Note that the powershell command runs fine on the one machine when you run it from the console inside the native windows powershell ISE environment. On that same machine using the screenconnect "Command" function it fails, so something in screenconnect is changing the command?

Screenconnect 5.6.10870.6001

Thx David
Scott  
#4 Posted : Tuesday, July 19, 2016 3:29:25 PM(UTC)
Scott


Rank: Administration

Medals: Level 4: Wise Old Owl! Received 100 Thanks!

Joined: 3/28/2014(UTC)
Posts: 2,490
United States

Thanks: 3 times
Was thanked: 305 time(s) in 262 post(s)
It could be the parsing, but I would expect other, similar commands with the same structure to fail.

Regardless, I can replicate the failure against Win10 machines with that specific command, so I'm registering it as a defect and I'll continue to investigate. Thanks for the report!
ScreenConnect Team
cbrasga  
#5 Posted : Monday, April 10, 2017 3:34:03 AM(UTC)
cbrasga


Rank: Advanced Member

Medals: Level 1: Random Act of Kindness! Received One Thanks!

Joined: 2/28/2014(UTC)
Posts: 39
United States

Thanks: 4 times
Was thanked: 8 time(s) in 5 post(s)
It's probably because ScreenConnect runs the 32 bit version of powershell which reads/write values under the WOW6432Node part of the Windows registry.

If you want to run the 64 bit version of powershell use the following:
c:\windows\sysnative\windowspowershell\v1.0\powershell.exe

Example:
c:\windows\sysnative\windowspowershell\v1.0\powershell.exe -command "Get-ItemProperty -Path 'hklm:software\microsoft\windows\currentversion\DeliveryOptimization\Config' -Name 'DODownloadMode'"

(Note: Be sure to use single quotes inside of the powershell command.

Edited by user Monday, April 10, 2017 3:35:03 AM(UTC)  | Reason: Not specified

Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.