Sponsored Content
Top Forums Shell Programming and Scripting Help required with Stderr and tee command Post 302980728 by vikas_trl on Thursday 1st of September 2016 02:09:04 PM
Old 09-01-2016
Thank you so much Stomp. This is what I am looking for.SmilieSmilieSmilieSmilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

'tee' STDERR output (ksh)

Hi everyone, KSH question: I know you can 'tee' STDOUT to have the output go to multiple targets; can you do the same with STDERR? For example: ls |tee /tmp/file.txt Will redirect STDOUT to both the screen and the '/tmp/file.txt' file. Is there a way of doing the same thing for... (5 Replies)
Discussion started by: gsatch
5 Replies

2. Shell Programming and Scripting

How to use tee with stdout and stderr?

I have been doing this: make xyz &> xyz.log &; tail -f xyz.log The problem with this is that you never can ge sure when "make xyz" is done. How can I pipe both stderr and stdout into tee so both stderr and stdout are copied both to the display and to the log file? Thanks, Siegfried (3 Replies)
Discussion started by: siegfried
3 Replies

3. Shell Programming and Scripting

STDERR to file & terminal using tee

Hi All, Solarix/Bash v3x Im trying to output any standard errors created by the script to a file using the below command: . runDTE.sh 2> "$DTE_ERROR_FILE" however the errors do get written to the dir/file stored in $DTE_ERROR_FILE but the error does not appear on the terminal screen in... (4 Replies)
Discussion started by: satnamx
4 Replies

4. UNIX and Linux Applications

Tee with pipe command.

cat work.txt M|324324|32424|3431 M|324324|32424|3431 N|324324|32426|3432 N|324324|32424|3434 M|324324|32424|3435 cat work.txt | tee $( grep '^M' > m.txt ) | $( grep '^N' > n.txt ) cehpny00:/home01/sr38632 $ cat m.txt M|324324|32424|3431 M|324324|32424|3431 M|324324|32424|3435 ... (2 Replies)
Discussion started by: rsampathy
2 Replies

5. Shell Programming and Scripting

Is there a way to tee stderr from a command that's redirecting error to a file?

I'm not a complete novice at unix but I'm not all that advanced either. I'm hoping that someone with a little more knowledge than myself has the answer I'm looking for. I'm writing a wrapper script that will be passed user commands from the cron... Ex: ./mywrapper.sh "/usr/bin/ps -ef |... (1 Reply)
Discussion started by: sumgi
1 Replies

6. UNIX for Dummies Questions & Answers

tee command within variable

Hello If anybody knows something about the following please help me. I am using HP unix. In a script called test.txt i have the following command echo ok | tee test1.txt It works fine.It prints ok on the screen and creates the file test1.txt and puts in the file the "ok". In the same... (2 Replies)
Discussion started by: kostasch
2 Replies

7. Shell Programming and Scripting

tee + more command

script1: #!/bin/ksh more test.txt script2: calling the script1 #!/bin/ksh /tmp/script1.sh 2>&1 | tee tee.log where test.txt contains ~1200 lines. When I execute the script2 the more command does not print pagewise it goes to the end of the line, when I remove the tee command it... (4 Replies)
Discussion started by: prasad111
4 Replies

8. Shell Programming and Scripting

How to "tee" stderr

In other words, print on both the screen and to a file (minus stdout)? Thanks again in advance (2 Replies)
Discussion started by: stevensw
2 Replies

9. UNIX for Advanced & Expert Users

Equivalents of tee command to find exit status of command

Hi, Want to log the output of command & check the exit status to find whether it succeeded or failed. > ls abc ls: abc: No such file or directory > echo $? 1 > ls abc 2>&1 | tee log ls: abc: No such file or directory > echo $? 0 Tee commands changes my exit status to be always... (7 Replies)
Discussion started by: vibhor_agarwali
7 Replies

10. Shell Programming and Scripting

Help with tee command

In the current directory , I have seven files . But when I use the following command , it lists eight files ( 7 files + file_list.xtx) ls -1 | tee file_list.xtx | while read line; do echo $line ; done Does the tee command create the file_list.xtx file first and then executes the ls -1... (1 Reply)
Discussion started by: kumarjt
1 Replies
STOMPSERVER(1)							   User Commands						    STOMPSERVER(1)

NAME
stompserver - Stomp protocol messaging server SYNOPSIS
stompserver [options] DESCRIPTION
Stomp messaging server with file/dbm/memory/activerecord based FIFO queues, queue monitoring, and basic authentication. OPTIONS
-C, --config=CONFIGFILE Configuration File (default: stompserver.conf) -p, --port=PORT Change the port (default: 61613) -b, --host=ADDR Change the host (default: localhost) -q, --queuetype=QUEUETYPE Queue type (memory|dbm|activerecord|file) (default: memory) -w, --working_dir=DIR Change the working directory (default: current directory) -s, --storage=DIR Change the storage directory (default: .stompserver, relative to working_dir) -d, --debug Turn on debug messages -a, --auth Require client authorization -c, --checkpoint=SECONDS Time between checkpointing the queues in seconds (default: 0) -h, --help Show this message QUEUES
Stompserver handles basic message queue processing using memory, file, or dbm based queues. Messages are sent and consumed in FIFO order (unless a client error happens, this should be corrected in the future). Topics are memory-only storage. You can select activerecord, file or dbm storage and the queues will use that, but topics will only be stored in memory. memory queues are of course the fastest ones but shouldn't be used if you want to ensure all messages are delivered. dbm queues will use berkeleydb if available, otherwise dbm or gdbm depending on the platform. sdbm does not work well with marshalled data. Note that these queues have not been tested in this release. For the file based storage, each frame is stored in a single file. The first 8 bytes contains the header length, the next 8 bytes contains the body length, then the headers are stored as a marshalled object followed by the body stored as a string. This storage is currently inefficient because queues are stored separately from messages, which forces a double write for data safety reasons on each message stored. The activerecord based storage expects to find a database.yml file in the configuration directory. It should be the most robust backend, but the slowest one. The database must have an ar_messages table which can be created with the following code (you are responsible to do so): ActiveRecord::Schema.define do create_table 'ar_messages' do |t| t.column 'stomp_id', :string, :null => false t.column 'frame', :text, :null => false end end You can read the frames with this model: class ArMessage < ActiveRecord::Base serialize :frame end The ar_message implementation will certainly change in the future. This is meant to be easily readable by a Rails application (which could handle the ar_messages table creation with a migration). ACCESS CONTROL
Basic client authorization is also supported. If the -a flag is passed to stompserver on startup, and a .passwd file exists in the run directory, then clients will be required to provide a valid login and passcode. See passwd.example for the password file format. MONITORING
Queues can be monitored via the monitor queue (this will probably not be supported this way in the future to avoid polluting the queue namespace). If you subscribe to /queue/monitor, you will receive a status message every 5 seconds that displays each queue, it's size, frames enqueued, and frames dequeued. Stats are sent in the same format of stomp headers, so they are easy to parse. Following is an exam- ple of a status message containing stats for 2 queues: Queue: /queue/client2 size: 0 dequeued: 400 enqueued: 400 Queue: /queue/test size: 50 dequeued: 250 enqueued: 300 AUTHOR
stompserver was written by Patrick Hurley <phurley@gmail.com> and Lionel Bouton. This manual page was compiled from the included documentation by Bryan McLellan <btm@loftninjas.org> for the Debian project (and may be used by others). The existing documentation is distributed under the MIT license. stompserver July 2009 STOMPSERVER(1)
All times are GMT -4. The time now is 08:28 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy