Results 1 to 5 of 5

Thread: Run an application from different machine

  1. #1
    Join Date
    Nov 2009
    Beans
    7

    Run an application from different machine

    so here it is guys, i have machine A and machine B. they are not on the same network so far. (maybe i cna manage a VPN or something not the problem here) what i need to do is open a console shell in machine A and run a software i wrote in machine B BUT i want it to run on machine B and get the results on the console on machine A.
    so how can i manage to do this? it is extremely important that machine B run the command/compiled-code so it can use the libraries at machine B but not A, and A must get the results to treat them. (and no i cannot install the same libraries on machine A)
    both have ubuntu 12.04

  2. #2
    Join Date
    Nov 2008
    Location
    Lleida, Spain
    Beans
    1,157
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Run an application from different machine

    you can use ssh and get the result.
    For example:

    ssh user@machine command

  3. #3
    Join Date
    Nov 2009
    Beans
    7

    Re: Run an application from different machine

    is it possible to replace a command with something like this: /home/cotoman/Project/some_compiled_binary ?

  4. #4
    Join Date
    Feb 2013
    Beans
    Hidden!

    Re: Run an application from different machine

    Yes, provided that the user you're logging in as has the execute permissions on this file.

  5. #5
    Join Date
    Feb 2008
    Beans
    251
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Run an application from different machine

    ...EDIT: Sorry, just noticed the post above. Will drink more coffee.

    Hi,

    ssh allows you to pass a command at the end of the statement; this command will be run on the remote server, and the results returned to the terminal on your local machine.

    Try this on machine A:

    Code:
    ssh user@machine.b "ls"
    ls can be replaced by any valid command from machine B, and you can use pipes ("|") etc.

    for more details have a look at
    Code:
    man ssh
    Last edited by greenpeace; February 22nd, 2013 at 12:16 PM. Reason: imbecility

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •