PS Script to install .msi package on workstations remotely

Hi Experts,

I am trying to install MicrosoftFixit50905.msi to workstations remotely but returning with the following error, could you please advise.

Script for single PC:

psexec \\192.168.100.100 -u domain\administrator -p password -accepteula -e msiexec /i "\\servername\c$\ MicrosoftFixit50905.msi" /qn /norestart

it successfully connects with the workstation but returns with the following error:

msiexec existed on 192.168.100.100 with error code 1603

Actually I need to install that MSI package for 100 workstations for that it would be great If I can install for list of computers remotely. Please advise.
ipsec600Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Greg BessoIT Solutions EngineerCommented:
What I usually do is the following. First, the PSEXEC connection...

psexec –s \\YourComputerNameHere cmd

Then in the CMD prompt that results, enter in your command-line installation line as you normally

Also what I've been using lately is this Easy Deploy which is PSEXEC with a GUI, makes it really easy to pull up one or many AD computers and then push to them. It's available at: http://andyamaya.com/
0
RGEIS2000Commented:
Why can't you use GPO?
0
Mohammed KhawajaManager - Infrastructure:  Information TechnologyCommented:
I suggest you create a GPO and push the packages via GPO.  This should work fine as the package will be launched locally running under system profile.  

If you are having issues with syntax in the MSI installation GPO then put the command in a batch file and run the batch file should run as part of computer logon. Your batch should the following:

- Check for existence of check file and if present then exit
-  If checkpoint doesn't exit then install the app an log the results to a file on the local system

You could add other logic to see if installation was successful, etc. if you need a sample file, let me know and I will send you one later on
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Problems using Powershell and Active Directory?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

FOXActive Directory/Exchange EngineerCommented:
when you are running psexec against a machine you want to use the -c  switch.
 You are better off putting the whole misexec command in a .bat file and then run your command as such
psexec @pathtoyourlistofmachines.txt -u domain\administrator -p password -c pathtoyour.bat file

http://ss64.com/nt/psexec.html
0
FOXActive Directory/Exchange EngineerCommented:
If you have access and rights, Mohammed's solution is the most straightforward. Create a gpo on the OU where your workstations sit and drop the msi package in there.
msigpo.JPG
0
SquigglyMonkeyCommented:
I am not sure how much of your answer is actually part of the script, but there is a space in front of your package name.  "\\servername\c$\ MicrosoftFixit50905.msi"
0
ipsec600Author Commented:
Thank you I have deployed via GPO.
0
FOXActive Directory/Exchange EngineerCommented:
Good work
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Powershell

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.