Announcement

Collapse
No announcement yet.

push reg files to workstations

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • push reg files to workstations

    Hi,
    I need to push two reg files to all workstations in 2003 domain.
    What is the best way? If possible detailed instructions.

    Thx.
    Michael.
    "When you hit a wrong note it's the next note that makes it good or bad". Miles Davis

  • #2
    Re: push reg files to workstations

    Put the reg files in the NETLOGON share, and put a command in the logon script to merge them into the registry. If logon scripts are a "No Go", then create a "startup script" and apply a policy to all machines which sets the "startup script" to the name of your script.


    Tom
    For my own and your protection, I do not provide support by private message under any circumstances. All such messages will be deleted and ignored.

    Anything you say will be misquoted and used against you

    Comment


    • #3
      Re: push reg files to workstations

      Thanks for the answer.

      1. Users are not local admins. I guess the file will never run.

      2. Ideally I want to make reg file import completely transparent to user.
      "When you hit a wrong note it's the next note that makes it good or bad". Miles Davis

      Comment


      • #4
        Re: push reg files to workstations

        As said before. Run them as a machine start up script in Group Policy. I use this in a VBS script.

        Code:
        ' Disable Windows XP Tour
        ' -----------------------------------------------------------------'
        SysVarReg.RegWrite "HKLM\Software\Microsoft\Windows\CurrentVersion\Applets\Tour\RunCount", 0,"REG_DWORD"
        Please remember to leave positive reputation points (The Ying Yang Icon) if someone helps you.

        Comment


        • #5
          Re: push reg files to workstations

          need your help.

          It's run fine when in reg file:

          [HKEY_CURRENT_USER\Software\InfoTel]
          "ServeurCorrections"="\\\\john\\infotel$\\Correcti ons"

          but gives an error
          line 5: caract: 1
          when in vbs (just didn't touch it )

          'descr
          'other'
          SysVarReg.RegWrite
          [HKEY_CURRENT_USER\Software\InfoTel]
          "ServeurCorrections"="\\\\john\\infotel$\\Correcti ons"
          "When you hit a wrong note it's the next note that makes it good or bad". Miles Davis

          Comment


          • #6
            Re: push reg files to workstations

            That looks like a wierd key to me. Anyway try...

            SysVarReg.RegWrite "HKCU\Software\InfoTel\"ServeurCorrections","\\\\j ohn\\infotel$\\Correcti ons","REG_DWORD"
            You will need to change "REG_DWORD" with the correct value.

            Can you export the key and paste it here for us to look at?
            Please remember to leave positive reputation points (The Ying Yang Icon) if someone helps you.

            Comment


            • #7
              Re: push reg files to workstations

              Here's the easy way I like to do it.

              Create the required registry keys.
              Export it
              Then call regedit /s "exportedfilename.reg" from a login script.

              Comment


              • #8
                Re: push reg files to workstations

                Sorry,
                I just paste lines from my post in notepad and named it .reg
                It not works. Weird, because I edited .reg file that worked and paste the content to my post.

                I will be on site day after tomorrow, will import the registry file that I received from the "creator" and will export it. Than will post it.
                Thanks for your time.
                "When you hit a wrong note it's the next note that makes it good or bad". Miles Davis

                Comment


                • #9
                  Re: push reg files to workstations

                  When you cut'n'paste from a rich text environment such as a web page into an executable text file such as a CMD file or a REG file, paste it into a pure text editor such as notepad first; otherwise some rich text characters such as smart quotes etc are not recognised by the handler which parses the file.


                  Tom
                  For my own and your protection, I do not provide support by private message under any circumstances. All such messages will be deleted and ignored.

                  Anything you say will be misquoted and used against you

                  Comment


                  • #10
                    Re: push reg files to workstations

                    You could alternatively try to push it through a GPO.
                    Create a new GPO, Computer configuration, Security Settings, Registry and edit the required registry keys from there.

                    Ta
                    Caesar's cipher - 3

                    ZKHQ BRX HYHQWXDOOB GHFLSKHU WKLV BRX ZLOO UHDOLVH LW ZDV D ZDVWH RI WLPH!

                    SFX JNRS FC U6 MNGR

                    Comment


                    • #11
                      Re: push reg files to workstations

                      In zip you'll find two reg files that working fine.
                      The goal is to enter path for some apps.

                      Like ]SK[ says it looks like a weird key when you edit it.
                      But it works fine.

                      ]SK[, yes I want to use your method:
                      to create a vbs and push it through GPO.

                      See why I cannot create vbs...

                      Thanks, all.
                      Attached Files
                      "When you hit a wrong note it's the next note that makes it good or bad". Miles Davis

                      Comment


                      • #12
                        Re: push reg files to workstations

                        They still look like they arn't correct. Could you maybe take a screenshot of that key?
                        Please remember to leave positive reputation points (The Ying Yang Icon) if someone helps you.

                        Comment


                        • #13
                          Re: push reg files to workstations

                          Look at this beauti
                          May be it will not work in real life. Guy who created it saying it's fine.
                          Attached Files
                          "When you hit a wrong note it's the next note that makes it good or bad". Miles Davis

                          Comment


                          • #14
                            Re: push reg files to workstations

                            Put these into a scriptname.vbs file and run it. See if it creates the entries you are after...

                            Code:
                            SysVarReg.RegWrite "HKCU\Software\InfoTel\"ServeurCorrections","\\john\infotel$\ServeurCorrections","REG_SZ" 
                            SysVarReg.RegWrite "HKLM\Software\InfoTel\"ServeurCorrections","\\john\infotel$\ServeurMAJ","REG_SZ"
                            Please remember to leave positive reputation points (The Ying Yang Icon) if someone helps you.

                            Comment


                            • #15
                              Re: push reg files to workstations

                              Guys guys, You cannot use a computer startup script (or computer policy) to edit or add entries to the HKEY_Current_User (HKCU) part in the registry.
                              HKCU only exist after the user is logged on, it contains copies of keys from different hives, mainly from HKey_Users\{usersid} which is loaded from the users.dat file.

                              And also, you cannot use a user logonscript to add or edit entries to the HKEY_Local_Machine (HKLM) hive, since normal uses don't have that permission. (however, if the registrykey exists already, you could use a GPO for the computers that changes the permission on the actual key for all authenticated users, to allow making edits)

                              Use a logonscript to edit the user's profile keys that are in HKey_Current_User.
                              Use a Computer startupscript to edit computer global keys that are in HKey_Local_Machine. Or use the registry editor in Real Mode to edit User.dat of a specific user.
                              If you want to make edits in both parts, you have to use both kind of scripts!

                              The vbs sample that was showed in this thread, is not complete, the object "SysVarReg" was not defined.
                              The correct script snippet should look like this:

                              Computer startupscript (*.vbs):
                              Code:
                              Set WshShell = WScript.CreateObject("WScript.Shell")
                              WshShell.RegWrite "HKLM\Software\InfoTel\CheminServeurMAJ", "\\john\infotel$\ServeurMAJ", "REG_SZ"
                              User logonscript (*.vbs):
                              Code:
                              Set WshShell = WScript.CreateObject("WScript.Shell")
                              WshShell.RegWrite "HKCU\Software\InfoTel\ServeurCorrections", "\\john\infotel$\ServeurCorrections", "REG_SZ"
                              If you would prefere to run just one script after the user is logged on, you can run a script remotely as a member of the local administrators group. Then the script must determine the SID of the currently loggedon user and edit the user's keys in HKey_Users\{usersid}, because the HKCU part is not available when you use alternate credentials.


                              \Rems
                              Last edited by Rems; 3rd October 2008, 09:36. Reason: added the collors

                              This posting is provided "AS IS" with no warranties, and confers no rights.

                              __________________

                              ** Remember to give credit where credit's due **
                              and leave Reputation Points for meaningful posts

                              Comment

                              Working...
                              X