Solved

Psexec to install an MSI file

Posted on 2013-01-22
16
1,220 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
  • 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
Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

 

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 500 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

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

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

Suggested Solutions

OfficeMate Freezes on login or does not load after login credentials are input.
For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
This Micro Tutorial will give you basic overview of the control panel section on Windows 7. It will depth in Network and Internet, Hardware and Sound, etc. This will be demonstrated using Windows 7 operating system.
The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…

679 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