Sponsored Content
Top Forums Shell Programming and Scripting Sending an event from another bash shell Post 302340861 by hresquivelo on Tuesday 4th of August 2009 01:23:29 PM
Old 08-04-2009
Sending an event from another bash shell

I have two BASH shells and would like to send data from one to the other. To achieve this, I have thought the following:
1) Shell #1 runs a script in order to create the file "output.out" with the data.
2) Meanwhile Shell #2 is waiting for "output.out" is created for starting with a second script later.

My question is: when "output.out" is created, how can I send an event to Shell #2 so it can start with the second script?

I tried this:
While Shell #1 is running, Shell #2 is executing this script:
Code:
while [ ! -e output.out ]; do sleep 0.1; done
# Second script starts here...

But since I'm doing a heavy simulation, I cannot use this solution! What I need is to send an event to Shell #2...

Any help will be really appreciated!
 

8 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

keypress event in shell script

Hi All, How can I trap a character press in the shell script. For eg:- I have a script runinng a infinite loops , I will need to dispay menu asking for run process of to stop process and process stauts like we do in glance I have seen the traping the signal in glance command, (8 Replies)
Discussion started by: arvindng
8 Replies

2. UNIX for Dummies Questions & Answers

Can we trigger an shell script on an event

Hi, My program A updates a log called logA. I have a shell script S that is responsible to send emails reading from the log. I want to trigger execution of the script whenever there is an update to the log. Thanks in advance. (8 Replies)
Discussion started by: cv_pan
8 Replies

3. Shell Programming and Scripting

sending mail via Bash

Hello , I want to send mail via bash script but i want to add from parameter for example i want to send to test@gmail.com and the sender will be test2@gmail.com Thanks for all (1 Reply)
Discussion started by: LinuxCommandos
1 Replies

4. Shell Programming and Scripting

bash unix cron + sending sms

Hi all, i'm trying to send an sms (notification sms) via a bash script executing throw crontab. The script works fine, but the sms itsn't sent to me. can you help me to resolve this issue, plz. Thanks. Yes - we probably COULD help you if you WOULD provide us with your script, the... (0 Replies)
Discussion started by: arezki76
0 Replies

5. Shell Programming and Scripting

/bin/bash: Event not found.

Hi I'm new to scripting - please help me... I'm trying to run a script written by a friend: #!/bin/bash for aStat in .... do .... done when coping the script to the terminal I get: /bin/bash: Event not found. for: Command not found. (7 Replies)
Discussion started by: atira
7 Replies

6. Shell Programming and Scripting

Shell script to execute condition until an event occurs

I need a script to keep polling "receive_dir" directory till "stopfile" get written in the directory. This has to run despite empty directory. So far i have this but fails if receive_dir is empty with no files with "unary operator expected". Help !! #!/usr/bin/ksh until do for i... (1 Reply)
Discussion started by: iaav
1 Replies

7. Shell Programming and Scripting

Sending awk variables into curl in a bash script

Hello experts! I have a file1 with the following format (yr,day, month, hour,minute): 201201132435 201202141210 201304132030 201410100110 ... What i want to do is to assign variables and then use them in the curl command to download the text of each event from a web page. What I have... (6 Replies)
Discussion started by: phaethon
6 Replies

8. Shell Programming and Scripting

Sending email to group in bash

In shell scripting, TestEmail is an existing group email. I am using the below command to send emails who are existed under TestEmail . Unable to receive the email. I have tried group ="id1 id2 " .Its working and i tried creating alias as well. Can we do it without creating alias or group ="id1... (1 Reply)
Discussion started by: thomas9192
1 Replies
CPANPLUS::Shell::Default::Plugins::Remote(3pm)		 Perl Programmers Reference Guide	    CPANPLUS::Shell::Default::Plugins::Remote(3pm)

NAME
CPANPLUS::Shell::Default::Plugins::Remote - connect to a remote CPANPLUS SYNOPSIS
CPAN Terminal> /connect localhost 1337 --user=foo --pass=bar ... CPAN Terminal@localhost> /disconnect DESCRIPTION
This is a "CPANPLUS::Shell::Default" plugin that allows you to connect to a machine running an instance of "CPANPLUS::Daemon", allowing remote usage of the "CPANPLUS Shell". A sample session, updating all modules on a remote machine, might look like this: CPAN Terminal> /connect --user=my_user --pass=secret localhost 1337 Connection accepted Successfully connected to 'localhost' on port '11337' Note that no output will appear until a command has completed -- this may take a while CPAN Terminal@localhost> o; i * [....] CPAN Terminal@localhost> /disconnect CPAN Terminal> BUG REPORTS
Please report bugs or other issues to <bug-cpanplus@rt.cpan.org<gt>. AUTHOR
This module by Jos Boumans <kane@cpan.org>. COPYRIGHT
The CPAN++ interface (of which this module is a part of) is copyright (c) 2001 - 2007, Jos Boumans <kane@cpan.org>. All rights reserved. This library is free software; you may redistribute and/or modify it under the same terms as Perl itself. SEE ALSO
CPANPLUS::Shell::Default, CPANPLUS::Shell, cpanp perl v5.18.2 2014-01-06 CPANPLUS::Shell::Default::Plugins::Remote(3pm)
All times are GMT -4. The time now is 05:07 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy