[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Modify Registry Key - Via SMS

Posted on 2009-12-30
10
Medium Priority
?
651 Views
Last Modified: 2013-11-21
I would like to modify and existing registry key to select users in my company. Cannot use GPO or Logon scripts (adm templates). Below is the key. Could someone please give me syntax i would use? I must use SMS to deploy the key. I do not have SMS installer to create the .EXE file

[HKEY_LOCAL_MACHINE\SOFTWARE\ESRI\License\LICENSE_SERVER

Current value is @XXXXXX and I need to change it to @YYYYY
0
Comment
Question by:mati02
  • 6
  • 4
10 Comments
 

Author Comment

by:mati02
ID: 26146350
SMS 2003
0
 
LVL 2

Expert Comment

by:CitySec
ID: 26146465
This might help...

How to add, modify, or delete registry subkeys and values by using a registration entries (.reg) file:
http://support.microsoft.com/kb/310516

I think you might have to create a batch file and within the batch file run regedit.

Batch File Help:
http://www.computerhope.com/batch.htm
0
 
LVL 2

Expert Comment

by:CitySec
ID: 26146540
Or you could execute a VBScript (which is what I do in my environment) to make the changes by calling "cscript.exe".

The VBScript will be responsible for making the registry change.

Registry Scripting Center
http://www.activexperts.com/activmonitor/windowsmanagement/adminscripts/registry/#CreateStringDword.htm

Create String and DWORD Values
http://gallery.technet.microsoft.com/ScriptCenter/en-us/8253ebcd-6024-4d0d-944d-0f8c209c933a
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:mati02
ID: 26146847
I need to do this through SMS Silently.
0
 
LVL 2

Expert Comment

by:CitySec
ID: 26146898
I know.  Create a Package, then a Program and in the Command Line field just enter the appropriate command-line arguments.  See image.
SCCM-Program-CommandLine.png
0
 

Author Comment

by:mati02
ID: 26147409
unfortunately i'm not a scripting master. I will try creating a batch file and run exported key with modifications (which i have) from a file share.
0
 

Author Comment

by:mati02
ID: 26148680
batch files will not run through SMS. I ran batch file with

XXX.bat /s and did not work.
0
 

Author Comment

by:mati02
ID: 26148682
batch file called the registry key.
0
 
LVL 2

Accepted Solution

by:
CitySec earned 2000 total points
ID: 26148717
1.  Dump the following code in a .vbs file.  I am assuming that the ValueName is LICENSE_SERVER though so you might need to change it.

2.  In the command-line box for the Program enter:  cscript.exe [Name-of-script-file].vbs

Hope that this is more helpful.
const HKEY_LOCAL_MACHINE = &H80000002
strComputer = "."
Set StdOut = WScript.StdOut
 
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" &_ 
strComputer & "\root\default:StdRegProv")
 
strKeyPath = "SOFTWARE\ESRI\License"
strValueName = "LICENSE_SERVER"
strValue = "@YYYYY"
oReg.SetStringValue HKEY_LOCAL_MACHINE,strKeyPath,strValueName,strValue

Open in new window

0
 

Author Closing Comment

by:mati02
ID: 31671244
Excellent. just what i was looking for.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Description: Actually I found the below issue with some customers after migration from SMS 2003 to SCCM 2007 and epically if they change site code, some clients may appear in the console with old site code, plus old sites still appearing …
This is my 3rd article on SCCM in recent weeks, the 1st (http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Server/Windows_Server_2008/A_4466-A-beginners-guide-to-installing-SCCM2007-on-Windows-2008-R2-Server.html) dealing with installat…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Is your OST file inaccessible, Need to transfer OST file from one computer to another? Want to convert OST file to PST? If the answer to any of the above question is yes, then look no further. With the help of Stellar OST to PST Converter, you can e…

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question