Solved

Batch file within msi package

Posted on 2010-11-24
7
1,564 Views
Last Modified: 2013-12-09
want to run few commands on client end using startup script or logon script. but running batch files has been denied by antivirus software. how can I package batch file and deploy it to client using AD.

If I can find a solution to packge with msi using Microsoft tool I can complete other things.

Thank You.
Janaka.
0
Comment
Question by:Support_Brandix
7 Comments
 
LVL 4

Expert Comment

by:tmwest
ID: 34207210
Can you run other types of files; .vbs, .cmd, .exe?  Can you just add an exception to your virus scan application to allow this bat file to run?
0
 

Author Comment

by:Support_Brandix
ID: 34210273
no can't modify policy right now. so only option is making a msi and deploy. let me know how can I make a msi including a bat file.
0
 
LVL 4

Expert Comment

by:fr0nk
ID: 34211557
Use MakeMSI from http://www.softpedia.com/get/Authoring-tools/Setup-creators/MAKEMSI.shtml

After that I'm pretty sure your AntiVir will still abort the execution of the bat, since it uses a file system driver (which you can view by invoking fltmc in a cmd window).
So don't put the .bat inside the MSI but a compiled .exe of the bat.
You can compile the .bat with http://www.abyssmedia.com/quickbfc/

Hope that helps.
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 

Author Comment

by:Support_Brandix
ID: 34213724
I am thinking not to go with bat file and instead use existing setup.exe file and do a msi package.

I installed makemsi software but I have no Idea how I can package setup.exe in to a msi file using this tool. also I want to pass a parameter to same exe.
0
 
LVL 4

Accepted Solution

by:
Sajen_Jose earned 500 total points
ID: 34217001
You can execute tasks using the Custom Actions in MSI or MST.

You can find more details about Custom Actions here -> http://msdn.microsoft.com/en-us/library/aa368066%28v=VS.85%29.aspx
0
 

Author Comment

by:Support_Brandix
ID: 34225548
@Sajen Jose
I've gone through the msdn that you have provided but it was very difficult task for me to find exat sytax to set custom action for my msi file.
my MSI file contains 3 files (x,y,z) and it will be exracted to program files\company\product folder at the execution. What I want to do is execute one of extracted file with parameter. below is sample how it works when run from command prompt.
 file x /parameter1=file y

please let me how I can modify msi table to acheive above task.

Thank you,
Janaka
0
 
LVL 4

Expert Comment

by:Sajen_Jose
ID: 34229489
Hi ,

The following two videos should give you some pointers on how to create a Custom Action using Wise or Installsheild.

Using Wise:
http://www.appdeploy.com/video/ca-wps.asp

Using Installsheild
http://www.appdeploy.com/video/ca-ias.asp

Custom Actions can also be created using Orca which is freely available. A tutorial on the same is given here - http://bonemanblog.blogspot.com/2005/10/custom-action-tutorial-part-i-custom.html
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

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

This article explains how to install and use the NTBackup utility that comes with Windows Server.
How to resolve IMCEAEX NDRs in Exchange or Exchange Online related to invalid X500 addresses.
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

828 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