+ Post New Thread
Results 1 to 10 of 10
Windows 7 Thread, Running WPKG (and scripts in general) on WIn7 in Technical; I'm trying to adapt my WPKG packages/scripts/bat files to work on Win7 machines but my automated methods are being halted ...
  1. #1

    SimpleSi's Avatar
    Join Date
    Jun 2005
    Location
    Lancashire
    Posts
    5,808
    Thank Post
    1,476
    Thanked 592 Times in 444 Posts
    Rep Power
    168

    Running WPKG (and scripts in general) on WIn7

    I'm trying to adapt my WPKG packages/scripts/bat files to work on Win7 machines but my automated methods are being halted by WIn7 asking for permissions.

    Has anyone battled their way through this one - if so hints and tips welcome

    for instance
    Code:
    <package
            id="office2003"
            name="Microsoft Office 2003"
            revision="1"
            reboot="false"
            notify="false"
            priority="100">
            <check type="uninstall" condition="exists" path="Microsoft Office Professional Edition 2003" />
            <install cmd='msiexec /i "%PACKAGES%\office2003\PRO11.MSI" TRANSFORMS=%PACKAGES%\office2003\office.MST /qb-' />
            <remove  cmd='MsiExec.exe /q /x{90110407-6000-11D3-8CFE-0150048383C9}' />
    </package>
    Is asking for permission to run pro11.msi
    can I wrap something around it to prevent this?

    regards
    Simon

  2. #2
    morganw's Avatar
    Join Date
    Apr 2009
    Location
    Cambridge
    Posts
    816
    Thank Post
    46
    Thanked 132 Times in 126 Posts
    Rep Power
    39
    Are you calling the WPKG script through a scheduled task or something like that? If you are using the WPKG client or WPKG-GP then everything should install with the system account so permissions should be an issue. I've just set up all our software through WPKG-GP and haven't had any permission issues.

  3. #3
    ChrisH's Avatar
    Join Date
    Jun 2005
    Location
    East Lancs
    Posts
    4,999
    Thank Post
    120
    Thanked 280 Times in 258 Posts
    Rep Power
    106
    Is it UAC that is asking for permission or is it a general file permission error? Also just in case you didn't know you can use a remote shell to execute commands on Windows 7 machines as well although by the look of it you will need to add your controlling computer to something called a trusted host list if you are working in a workgroup. Otherwise you just need to run winrm /quickconfig on all the machines once to set it up.
    Last edited by ChrisH; 22nd June 2011 at 07:39 PM.

  4. #4

    SimpleSi's Avatar
    Join Date
    Jun 2005
    Location
    Lancashire
    Posts
    5,808
    Thank Post
    1,476
    Thanked 592 Times in 444 Posts
    Rep Power
    168
    I'm running WPKG through a simple bat file in the all users startup folder.

    @Chris - its a UAC thing. I' ll look this winrm /quickconfig you speak of

    Si

  5. #5
    morganw's Avatar
    Join Date
    Apr 2009
    Location
    Cambridge
    Posts
    816
    Thank Post
    46
    Thanked 132 Times in 126 Posts
    Rep Power
    39
    If the script is running in the context of the user logging in it won't work properly. You'll need to elevate permissions on it and probably trigger it some other way.

  6. #6

    SYNACK's Avatar
    Join Date
    Oct 2007
    Posts
    11,059
    Thank Post
    853
    Thanked 2,670 Times in 2,267 Posts
    Blog Entries
    9
    Rep Power
    768
    You should run these as machine scripts rather than user logon scripts as they are admin level tasks and will work fine as a machine script.

  7. #7

    SimpleSi's Avatar
    Join Date
    Jun 2005
    Location
    Lancashire
    Posts
    5,808
    Thank Post
    1,476
    Thanked 592 Times in 444 Posts
    Rep Power
    168
    You should run these as machine scripts rather than user logon scripts as they are admin level tasks and will work fine as a machine script.
    Well, a couple of issues spring to mind, although installing office can be made to run silently, a lot of my others don't (quite a few use auto-it) and I use WPKG as a global program to run all other startup/logon actions such as presenting a dialog to choose your class and map a networked drive appropriately and setting/resetting wallpaper/screensaver etc.

    What the sort of info I think I need is like the fact that in Win7, I need to create shortcuts to my bat files and set the "run as admin" box checked in advanced tab rather than just run the bat files directly.

    Or does no-one use scripts nowadays

    Si

  8. #8
    Boredguy's Avatar
    Join Date
    Jun 2011
    Location
    Swindon
    Posts
    568
    Thank Post
    3
    Thanked 128 Times in 119 Posts
    Rep Power
    50
    We use scripts, but use WPKG purely for application deployment.

    Any scripts we want applied to users, such as running bginfo to set the wallpaper, are defined within the "Logon Scripts" section of the GPO's that is applied to users.

  9. #9
    morganw's Avatar
    Join Date
    Apr 2009
    Location
    Cambridge
    Posts
    816
    Thank Post
    46
    Thanked 132 Times in 126 Posts
    Rep Power
    39
    You could set up two WPKG systems, one for running on workstation boot or as a background task for software installs, the other just for triggering user level stuff.

  10. #10

    SimpleSi's Avatar
    Join Date
    Jun 2005
    Location
    Lancashire
    Posts
    5,808
    Thank Post
    1,476
    Thanked 592 Times in 444 Posts
    Rep Power
    168
    You could set up two WPKG systems, one for running on workstation boot or as a background task for software installs, the other just for triggering user level stuff.
    But I'd still be hitting UAC I imagine (unless its just running msiexec that is/will fail on me )

    Any scripts we want applied to users, such as running bginfo to set the wallpaper, are defined within the "Logon Scripts" section of the GPO's that is applied to users.
    I don't run my network as a domain - I just use a W2k3 machines as a file/print/dhcp/dns server with a single client logon so WPKG has been my network Swiss Army Knife (I've used it on Win98 clients and I've still got one Win98 file server in operation (Its virtualised BTW )) )


    Si

    Si

SHARE:
+ Post New Thread

Similar Threads

  1. why is windows 7 not running scripts at startup?
    By OPA-ABU in forum Windows 7
    Replies: 8
    Last Post: 22nd October 2010, 02:55 PM
  2. Win7 clients not applying Group Policies or running logon scripts
    By TheElusiveOrangeButton in forum Windows 7
    Replies: 11
    Last Post: 7th July 2010, 04:13 PM
  3. Not running scripts
    By C3sium in forum Windows 7
    Replies: 19
    Last Post: 4th March 2010, 04:11 AM
  4. Help running scripts within scripts
    By SimpleSi in forum *nix
    Replies: 7
    Last Post: 7th March 2008, 09:23 AM
  5. Replies: 4
    Last Post: 6th February 2006, 03:48 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •