Professional Web Applications Themes

remote inter-program communication? - Linux / Unix Administration

Let's say there is a host1 (SunOS 5.8) which handles daily dataloading. There is a host2 (FreeBSD 4.3-20010721-STABLE FreeBSD) which uses the data loaded by host1. Host1 usually takes a couple of hours loading data. During the loading time, host2 should be out of service and just publishes a notice to users saying 'service not available until data loading is finished'. There used to be a NFS filesystem shared between host1 and host2. So whenever data loading was in progress, host1 created a signal file on host1 and then host2 could decide whether or not to provide the service by ...

  1. #1

    Default remote inter-program communication?


    Let's say there is a host1 (SunOS 5.8) which handles daily dataloading.
    There is a host2 (FreeBSD 4.3-20010721-STABLE FreeBSD) which uses the
    data loaded by host1.

    Host1 usually takes a couple of hours loading data. During the loading
    time, host2 should be out of service and just publishes a notice to
    users saying 'service not available until data loading is finished'.

    There used to be a NFS filesystem shared between host1 and host2. So
    whenever data loading was in progress, host1 created a signal file on
    host1 and then host2 could decide whether or not to provide the service
    by checking the existence of the signal file. But we've just stopped
    using NFS between the two machines.

    Anybody have any idea how the same function can be accomplished in a
    different way? Perl is used on host1 and host2 for coding. Any
    suggestions and ideas would be appreciated.

    Bing


    Bing Du Test Guest

  2. #2

    Default Re: remote inter-program communication?

    In article <3F341BB2.BFB90E2Apku.edu.cn>,
    Bing Du Test <testpku.edu.cn> wrote:
    >
    >Let's say there is a host1 (SunOS 5.8) which handles daily dataloading.
    >There is a host2 (FreeBSD 4.3-20010721-STABLE FreeBSD) which uses the
    >data loaded by host1.
    >
    >Host1 usually takes a couple of hours loading data. During the loading
    >time, host2 should be out of service and just publishes a notice to
    >users saying 'service not available until data loading is finished'.
    >
    >There used to be a NFS filesystem shared between host1 and host2. So
    >whenever data loading was in progress, host1 created a signal file on
    >host1 and then host2 could decide whether or not to provide the service
    >by checking the existence of the signal file. But we've just stopped
    >using NFS between the two machines.
    >
    >Anybody have any idea how the same function can be accomplished in a
    >different way? Perl is used on host1 and host2 for coding. Any
    >suggestions and ideas would be appreciated.
    Two obvious solutions come to mind:

    1) Host1 runs a server that answers the question "Is data loading taking
    place?". When host2 receives a request, it connects to the server on
    host1 to find out. The server can operate by simply looking for the
    signal file, so the loading application itself doesn't need to change.

    2) Host2 runs a server that listens for changes in the loading status.
    When host1 starts loading, it connects to the server and reports
    "Loading started". When it's done loading it connects again and reports
    "Loading completed". The server can operate by writing and removing the
    signal file, so the application on host2 doesn't need to change.

    --
    Barry Margolin, [email]barry.margolinlevel3.com[/email]
    Level(3), Woburn, MA
    *** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
    Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.
    Barry Margolin Guest

  3. #3

    Default Re: remote inter-program communication?

    On Fri, 08 Aug 2003 16:52:50 -0500, Bing Du Test
    <testpku.edu.cn> wrote:
    >
    > Let's say there is a host1 (SunOS 5.8) which handles daily dataloading.
    > There is a host2 (FreeBSD 4.3-20010721-STABLE FreeBSD) which uses the
    > data loaded by host1.
    >
    > Host1 usually takes a couple of hours loading data. During the loading
    > time, host2 should be out of service and just publishes a notice to
    > users saying 'service not available until data loading is finished'.
    >
    > There used to be a NFS filesystem shared between host1 and host2. So
    > whenever data loading was in progress, host1 created a signal file on
    > host1 and then host2 could decide whether or not to provide the service
    > by checking the existence of the signal file. But we've just stopped
    > using NFS between the two machines.
    >
    > Anybody have any idea how the same function can be accomplished in a
    > different way? Perl is used on host1 and host2 for coding. Any
    > suggestions and ideas would be appreciated.
    >
    FTP or whatever mechanism is now used to transfer data between host1
    and host2?


    --
    Oh my Darl-ing, oh my Darl-ing, oh my Darl-ing SCO,
    For a while the joke was funny, but it's really time to go.
    Bill Marcum Guest

  4. #4

    Default Re: remote inter-program communication?

    in comp.unix.admin i read:
    >Barry Margolin <barry.margolinlevel3.com> writes:
    >> 2) Host2 runs a server that listens for changes in the loading
    >> status. When host1 starts loading, it connects to the server
    >> and reports "Loading started". When it's done loading it
    >> connects again and reports "Loading completed". The server can
    >> operate by writing and removing the signal file, so the
    >> application on host2 doesn't need to change.
    >
    >Another way is to ssh(1) with password-less logins.
    [use ssh to touch and rm the signal file]

    [then use ssh to rm the file]

    is sshd not a server running on host2?

    --
    a signature
    those who know me have no need of my name Guest

  5. #5

    Default Re: remote inter-program communication?

    In article <m1smoabb5v.gnususa.net>,
    those who know me have no need of my name <not-a-real-addressusa.net> wrote:
    >in comp.unix.admin i read:
    >>Barry Margolin <barry.margolinlevel3.com> writes:
    >
    >>> 2) Host2 runs a server that listens for changes in the loading
    >>> status. When host1 starts loading, it connects to the server
    >>> and reports "Loading started". When it's done loading it
    >>> connects again and reports "Loading completed". The server can
    >>> operate by writing and removing the signal file, so the
    >>> application on host2 doesn't need to change.
    >>
    >>Another way is to ssh(1) with password-less logins.
    >
    >[use ssh to touch and rm the signal file]
    >
    >[then use ssh to rm the file]
    >
    >is sshd not a server running on host2?
    True. But the implication of *my* suggestion was that they'd have to write
    a special server just for this application. His variation shows how to
    accomplish it by using a general-purpose server that already exists.

    --
    Barry Margolin, [email]barry.margolinlevel3.com[/email]
    Level(3), Woburn, MA
    *** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
    Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.
    Barry Margolin Guest

Similar Threads

  1. how to submit a program to a remote computer backpround
    By Wang Yong-qiang in forum Linux / Unix Administration
    Replies: 3
    Last Post: December 15th, 02:47 PM
  2. inter-level controlling
    By duderOfHunka webforumsuser@macromedia.com in forum Macromedia Flash Sitedesign
    Replies: 3
    Last Post: August 27th, 03:25 PM
  3. Wanted - push/rexec/pull script for remote program builds
    By John Ramsden in forum PERL Miscellaneous
    Replies: 2
    Last Post: July 14th, 04:31 PM

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
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139