How to use more than one MPE command STREAM with Unix command in a single shell?


 
Thread Tools Search this Thread
Operating Systems HP-UX How to use more than one MPE command STREAM with Unix command in a single shell?
Prev   Next
# 1  
Old 09-19-2006
Question How to use more than one MPE command STREAM with Unix command in a single shell?

Hello,
I have problem in writing the shell script involving MPE command STREAM related to HP-UX and Unix command. Script is

sh "nlshCMD 'STREAM <job name1>' | 'SHOWJOB' | grep $HPJOBNUM"
sh "nlshCMD 'STREAM <job name2>' | 'SHOWJOB' | grep $HPJOBNUM"
sh "nlshCMD 'STREAM <job name3>' | 'SHOWJOB' | grep $HPJOBNUM"

My question is I have to put these three STREAM commands together involving three diffrent jobs together in a single shell script and to monitor the corresponding job, once I submit it. For your reference Text in upper case represents MPE command of HP9000.
Can we do it? If so How? Please let me know your view and any reference in solving this.
Thanking in advance
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Merge multi-lines into one single line using shell script or Linux command

Hi, Can anyone help me for merge the following multi-line log which beginning with a " and line ending with ": into one line. *****Original Log***** 087;2008-12-06;084403;"mc;;SYHLR6AP1D\LNZW;AD-703;1;12475;SYHLR6AP1B;1.1.1.1;0000000062;HGPDI:MSISDN=12345678,APNID=1,EQOSID=365;... (3 Replies)
Discussion started by: rajeshlinux2010
3 Replies

2. Shell Programming and Scripting

Stream manipulation in UNIX shell scripting

i have a file something like this : start: 01:00:00 01:30:00 02:30:00 05:30:00 end: 01:13:00 02:00:00 02:40:00 05:45:00 and i want (end - start) total run time in below format: run: 00:13:00 00:30:00 00:10:00 00:15:00 (4 Replies)
Discussion started by: Acme
4 Replies

3. UNIX for Dummies Questions & Answers

Single UNIX command to display users and to count them

Hello everyone, I am new to Unix and I am stuck with a problem. I need only a single command to display the output of who and then add the total number of users and display at the bottom of that output. Example-: (Expected output) sreyan@debian:~$ <command> sreyan tty7 ... (7 Replies)
Discussion started by: sreyan32
7 Replies

4. Shell Programming and Scripting

Single command - unzip files from a tar command

I have a tar file that contains multiple .Z files. Hence I need to issue a tar command followed by a gzip command to fully extract the files. How do I do it in a single command? What I'm doing now is tar xvf a.tar (this will output 1.Z and 2.Z) gzip -d *.Z (to extract 1.Z and 2.Z) (9 Replies)
Discussion started by: ericlim
9 Replies

5. UNIX for Dummies Questions & Answers

Re: How To Use UNIQ UNIX Command On single Column

Hi , Can You Please let Know How use unix uniq command on a single column for deleting records from file with Below Structure.Pipe Delimter File . Source Name | Account_Id A | 101 B... (2 Replies)
Discussion started by: anudeepkumar123
2 Replies

6. UNIX for Advanced & Expert Users

unix command for terminal - view sequences as a single line?

Hello, I'm looking for some code that will list sequences of files as a single line. ie, sequences of files like this: filename.1.ext filename.2.ext filename.3.ext filename.4.ext filename.5.ext filename.6.ext filename.7.ext filename.8.ext filename.9.ext filename.10.ext would... (6 Replies)
Discussion started by: kentm
6 Replies

7. Shell Programming and Scripting

Multiple file rename (change in filename in unix with single command

Dear All, Please help ! i ham having 300 file with E.G. PMC1_4567.arc in seq. like PMC1_4568.arc,PMC1_4569.arc ...n and so on.. i want all those file to be rename like PMC_4567.arc ,PMC_4568.arc .. mean i want to remove 1 from first file name .. pls help.. (6 Replies)
Discussion started by: moon_22
6 Replies

8. Shell Programming and Scripting

How can i use single quotes for SQL command in shell script

Hi. please help me to write the following query in a shell script. the Query is :select no,salary from emp_info where name='$var_name' the following is my code. #! /bin/sh var_name=$1 sqlplus -s user/pwd@DB << EOF select no,salary from emp_info where name="'$var_name'";... (4 Replies)
Discussion started by: little_wonder
4 Replies

9. UNIX for Dummies Questions & Answers

run command Unix on a single line

Hi everybody.. I need to enter in bash mode and then run a command and this just in a single command line. I tried : "bash ^M| somecommand" but nothing.. How do I do to simulate the return button just right after the bash command ? Thanks.. (8 Replies)
Discussion started by: Riddick61
8 Replies

10. Shell Programming and Scripting

How to use more than one MPE command STREAM with Unix command in a single shell?

Hello, I have problem in writing the shell script involving MPE command STREAM related to HP-UX and Unix command. Script is sh "nlshCMD 'STREAM <job name1>' | 'SHOWJOB' | grep $HPJOBNUM" sh "nlshCMD 'STREAM <job name2>' | 'SHOWJOB' | grep $HPJOBNUM" sh "nlshCMD 'STREAM <job name3>' |... (0 Replies)
Discussion started by: bosskr
0 Replies
Login or Register to Ask a Question
stropts.h(3HEAD)						      Headers							  stropts.h(3HEAD)

NAME
stropts.h, stropts - STREAMS interface (STREAMS) SYNOPSIS
#include <stropts.h> DESCRIPTION
The <stropts.h> header defines the bandinfo structure, which includes the following members: unsigned char bi_pri /* priority band */ int bi_flag /* flushing type */ The <stropts.h> header defines the strpeek structure that includes the following members: struct strbuf ctlbuf /* control portion of the message */ struct strbuf databuf /* data portion of the message */ t_uscalar_t flags /* RS_HIPRI or 0 */ The <stropts.h> header defines the strbuf structure that includes the following members: int maxlen /* maximum buffer length */ int len /* length of data */ char *buf /* pointer to buffer */ The <stropts.h> header defines the strfdinsert structure that includes the following members: struct strbuf ctlbuf /* control portion of the message */ struct strbuf databuf /* data portion of the message */ t_uscalar_t flags /* RS_HIPRI or 0 */ int fildes /* file descriptor of the other STREAM */ int offset /* relative location of the stored value */ The <stropts.h> header defines the strioctl structure that includes the following members: int ic_cmd /* ioctl() command */ int ic_timout /* timeout for response */ int ic_len /* length of data */ char *ic_dp /* pointer to buffer */ The <stropts.h> header defines the strrecvfd structure that includes the following members: int fda /* received file descriptor */ uid_t uid /* UID of sender */ gid_t gid /* GID of sender */ The uid_t and gid_t types are defined through typedef as described in <sys/types.h>. See types.h(3HEAD). The <stropts.h> header defines the t_scalar_t and t_uscalar_t types, respectively, as signed and unsigned opaque types of equal length of at least 32 bits. The <stropts.h> header defines the str_list structure that includes the following members: int sl_nmods /* number of STREAMS module names */ struct str_mlist *sl_modlist /* STREAMS module names */ The <stropts.h> header defines the str_mlist structure that includes the following member: char l_name[FMNAMESZ+1] a STREAMS module name The following macros are defined for use as the request argument to ioctl(): I_PUSH Push a STREAMS module. I_POP Pop a STREAMS module. I_LOOK Get the top module name. I_FLUSH Flush a STREAM. I_FLUSHBAND Flush one band of a STREAM. I_SETSIG Ask for notification signals. I_GETSIG Retrieve current notification signals. I_FIND Look for a STREAMS module. I_PEEK Peek at the top message on a STREAM. I_SRDOPT Set the read mode. I_GRDOPT Get the read mode. I_NREAD Size the top message. I_FDINSERT Send implementation-defined information about another STREAM. I_STR Send a STREAMS ioctl(). I_SWROPT Set the write mode. I_GWROPT Get the write mode. I_SENDFD Pass a file descriptor through a STREAMS pipe. I_RECVFD Get a file descriptor sent via I_SENDFD. I_LIST Get all the module names on a STREAM. I_ATMARK Is the top message ``marked''? I_CKBAND See if any messages exist in a band. I_GETBAND Get the band of the top message on a STREAM. I_CANPUT Is a band writable? I_SETCLTIME Set close time delay. I_GETCLTIME Get close time delay. I_LINK Connect two STREAMs. I_UNLINK Disconnect two STREAMs. I_PLINK Persistently connect two STREAMs. I_PUNLINK Dismantle a persistent STREAMS link. The following macro is defined for use with I_LOOK: FMNAMESZ minimum size in bytes of the buffer referred to by the arg argument The following macros are defined for use with I_FLUSH: FLUSHR flush read queues FLUSHW flush write queues FLUSHRW flush read and write queues The following macros are defined for use with I_SETSIG: S_RDNORM A normal (priority band set to 0) message has arrived at the head of a STREAM head read queue. S_RDBAND A message with a non-zero priority band has arrived at the head of a STREAM head read queue. S_INPUT A message, other than a high-priority message, has arrived at the head of a STREAM head read queue. S_HIPRI A high-priority message is present on a STREAM head read queue. S_OUTPUT The write queue for normal data (priority band 0) just below the STREAM head is no longer full. This notifies the process that there is room on the queue for sending (or writing) normal data downstream. S_WRNORM Equivalent to S_OUTPUT. S_WRBAND The write queue for a non-zero priority band just below the STREAM head is no longer full. S_MSG A STREAMS signal message that contains the SIGPOLL signal reaches the front of the STREAM head read queue. S_ERROR Notification of an error condition reaches the STREAM head. S_HANGUP Notification of a hangup reaches the STREAM head. S_BANDURG When used in conjunction with S_RDBAND, SIGURG is generated instead of SIGPOLL when a priority message reaches the front of the STREAM head read queue. The following macro is defined for use with I_PEEK: RS_HIPRI Only look for high-priority messages. The following macros are defined for use with I_SRDOPT: RNORM Byte-STREAM mode, the default. RMSGD Message-discard mode. RMSGN Message-non-discard mode. RPROTNORM Fail read() with [EBADMSG] if a message containing a control part is at the front of the STREAM head read queue. RPROTDAT Deliver the control part of a message as data when a process issues a read() RPROTDIS Discard the control part of a message, delivering any data part, when a process issues a read() The following macro is defined for use with I_SWOPT: SNDZERO Send a zero-length message downstream when a write() of 0 bytes occurs. The following macros are defined for use with I_ATMARK: ANYMARK Check if the message is marked. LASTMARK Check if the message is the last one marked on the queue. The following macro is defined for use with I_UNLINK: MUXID_ALL Unlink all STREAMs linked to the STREAM associated with fildes. The following macros are defined for getmsg(), getpmsg(), putmsg(), and putpmsg(): MSG_ANY Receive any message. MSG_BAND Receive message from specified band. MSG_HIPRI Send/receive high-priority message. MORECTL More control information is left in message. MOREDATA More data is left in message. The <stropts.h> header can make visible all of the symbols from <unistd.h>. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ SEE ALSO
close(2), fcntl(2), getmsg(2), ioctl(2), open(2), pipe(2), poll(2), putmsg(2), read(2), write(2), signal(3C), types.h(3HEAD), unistd.h(3HEAD), attributes(5), standards(5) SunOS 5.11 10 Sep 2004 stropts.h(3HEAD)