Execution Of EXE

  • Hi every one , any one help me on below requirement

    I had two servers

    server 1 -------SSIS Package is present

    server 2----- EXe location

    I had SSIS Package in server 1 , at one step am calling the exe present in server 2 and passing arguments and working directory to server 2

    when i execute the package the package should execute in Server 1, but when it trigger to exe the exe should execute in server 2 not in server 1

    can any one help me on these i can use dotnet also

    thanks in advance

  • You need to call a service running on Server2 to execute the process, else the exe gets transferred to server1 and ran there. So, you'll need something already existing on Server2 to get server2 to initiate the exe call.


    - Craig Farrell

    Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.

    For better assistance in answering your questions[/url] | Forum Netiquette
    For index/tuning help, follow these directions.[/url] |Tally Tables[/url]

    Twitter: @AnyWayDBA

  • Can you please add some steps how to proceed

    thanks for you reply

  • I'm sorry, but I'm afraid some details from this point forward will be a bit lacking from me, simply because I'm not an application coder.

    To the basics: An executable called from a particular machine will run in the memory/cpu space of whatever machine called it. This is normal.

    You want to run an executable from a machine that's not originating the call. That'd be Server 2. The only way to do that is to have a service (rt-click My computer, Manage, services) that will accept foreign input and then will activate a local .exe. Whatever is the login for SQL Server on Server1 will need rights to be able to send a message to the service on Server2, and that service will then fire the .exe call.

    I would recommend speaking with your app developers on this. It shouldn't be overly difficult for them to create an active service for foreign requests, but it may break internal security policy. Either way, they'll be able to better answer what's the acceptable solution in your company far better than we will.


    - Craig Farrell

    Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.

    For better assistance in answering your questions[/url] | Forum Netiquette
    For index/tuning help, follow these directions.[/url] |Tally Tables[/url]

    Twitter: @AnyWayDBA

  • Do you need to do this from SQL Server only? If your server2 has a SQL Server, create a job on it to execute the exe and invoke that job from SSIS package running on server1.

    But note that if exe is invoking any UI it will not work, but an exe without UI should work fine.

  • The exe is invoking the UI and i need to send the working directory and arguments to the exe i mean server 2

    am able to pass through process task using ssis but the exe is executing in server 1 , want the exe to trigger in server 2

  • When you run exe from a process in server 1, it will always get executed on server1's memory irrespective of where it is located.

    If you have to run it on server 2, some service on server 2 should invoke it.

  • v.sandeep06 (10/9/2012)


    Hi every one , any one help me on below requirement

    I had two servers

    server 1 -------SSIS Package is present

    server 2----- EXe location

    I had SSIS Package in server 1 , at one step am calling the exe present in server 2 and passing arguments and working directory to server 2

    when i execute the package the package should execute in Server 1, but when it trigger to exe the exe should execute in server 2 not in server 1

    can any one help me on these i can use dotnet also

    thanks in advance

    Executing a command on a remote server is a trivial thing to do using PowerShell. PowerShell: Running Remote Commands

    PsExec is also an option.

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply