Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Psexec to install an MSI file

Posted on 2013-01-22
16
Medium Priority
?
1,245 Views
Last Modified: 2013-02-04
I have a file called Microsoftfixit50154.msi where you have to accept the agreement in order for it to run... I'm trying to install this with PSexec I've tried various things..  

@echo off
set /p var= Enter Computer Name:
set /p var2=Enter the File Name:

Psexec \\%var% -s cmd /c copy "\\share\folder\%var2%" c:\

psexec \\%var% -s msiexec.exe /i %Var2% /q

psexec  \\%var% -s cmd /c del "c:\%var2%"

And just a simple:
psexec.exe \\remotecomputer -s msiexec.exe /i  c:\xxx.msi /qn after copying the file to the c drive.

Nothing is working
0
Comment
Question by:WellingtonIS
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 10
  • 5
16 Comments
 
LVL 14

Expert Comment

by:Justin Yeung
ID: 38806026
does the system account has access to the shared folder?
0
 

Author Comment

by:WellingtonIS
ID: 38806035
yes it does.  I tried with -s cmd too
0
 
LVL 14

Expert Comment

by:Justin Yeung
ID: 38806085
i can see that you used -s and what i am saying is since it is a shared folder, the local machine system account might not have access to the shared folder. unless it is opened to everyone groups.

did you see the file copied to the specified machine?
0
The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

 

Author Comment

by:WellingtonIS
ID: 38806109
Yes sorry.  The file is on the remote machine.  I copied it there.  If I run the command on the machine.exe /i c:\microsoftfixit50154.msi  it will at least get me to the screen where I have to accept the agreement.  I can't get it to work remotely
0
 

Author Comment

by:WellingtonIS
ID: 38806512
OK I think part of this issue is when you click on the actual fix it asks you to run it...  Then it has an agreement however, I think I might have found a way around it with AGREETOLICENSE="yes"
0
 
LVL 14

Expert Comment

by:Justin Yeung
ID: 38806790
i believe you are missing cmd /c in front of msiexec

for some reason it require msiexec to run under cmd by using psexec
0
 

Author Comment

by:WellingtonIS
ID: 38806834
Tried that too.  It doesn't work.
0
 
LVL 14

Expert Comment

by:Justin Yeung
ID: 38807010
psexec \\%var% -s cmd /c "msiexec.exe /i c:\%Var2% /q"

try this

added cmd /c "" in between the string and the full path fo the msi file.
0
 

Author Comment

by:WellingtonIS
ID: 38807062
I will try.
0
 

Author Comment

by:WellingtonIS
ID: 38807075
It finishes too fast to be running..  It looks like it runs but it does nothing.
0
 
LVL 14

Expert Comment

by:Justin Yeung
ID: 38807206
try to test your install with /passive instead of /qn

so you can see if any process is actually ran.

and check the log under event viewer and see if it ran or any error
0
 

Author Comment

by:WellingtonIS
ID: 38807263
OK thanks much!
0
 

Author Comment

by:WellingtonIS
ID: 38809805
I'm getting Microsoft Installation success or error status:1603 and a Client Process Id: 3660
0
 
LVL 10

Accepted Solution

by:
Tony Barkdull earned 2000 total points
ID: 38849177
What I do is put the install command in a batch file like install.bat, copy it and the msi to the remote computer c:\ drive, then run this

psexec \\remotecomputer c:\install.bat

The install will run in a command window and install normally.

Note: I have found that using UNC shares in the install.bat on remote PCs to be problematic, so copy the msi local, run the install, and then delete it
0
 

Author Comment

by:WellingtonIS
ID: 38850932
OK will try thanks!
0
 

Author Closing Comment

by:WellingtonIS
ID: 38851786
That worked
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

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

First some basics on Windows 7 Backup.  It has 2 components one is a file based backup which is stored in .zip files each zip is split at around 200 Megabytes and there is the Image Backup which is as the name implies a total image of the partition …
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
This Micro Tutorial will teach you the basics of configuring your computer to improve its speed. It will also teach you how to disable programs that are running in the background simultaneously. This will be demonstrated using Windows 7 operating…
Suggested Courses

715 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