Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Redirecting output to multiple log files? Post 13300 by darthur on Tuesday 15th of January 2002 11:54:26 AM
Old 01-15-2002
Thanks for the feedback!

tee & the tips on using sed should do the trick ... Thanks!
 

10 More Discussions You Might Find Interesting

1. Programming

execl() + redirecting output to text files

Im currently using execl() to run the ls command and redirect the output to a text file. Unfortunately, when I check the text file, no information has been written to it. I am calling execl() with the ls command like this execl( "/bin/ls" , "-al" , '>' , "dirlist.txt" ,(char *) 0 ); ... (5 Replies)
Discussion started by: JamesGoh
5 Replies

2. Shell Programming and Scripting

Redirecting echo output to 2 flat files

Hello all, I have the following 2 questions.. 1) I would like to capture the output of an echo command to 2 different files at the same time. This does not seem to work. Any ideas? echo ==== started on `date` ==== >> res1.log res2.log 2) Would it be possible to just get the 5th... (2 Replies)
Discussion started by: luft
2 Replies

3. Shell Programming and Scripting

Redirecting columns from multiple files

Hi all, I have two years worth of daily files (e.g. 090107.dat) and I'd like to write a BASH script to extract the same 2 columns from each of these files and copy them all to one separate file. Could anyone please point me in the right direction as I'm new to shell scripting? It would... (3 Replies)
Discussion started by: larrymuli
3 Replies

4. UNIX for Dummies Questions & Answers

help in redirecting output to multiple logfiles without displaying it on the screen

Hi, 1.some_command > logfile1 2>&1 will redirect everything to the file logfile1 without displaying the output of the command on the screen. 2.some_command | tee logfile1 | tee logfile2will redirect the output to logfile1 and logfile2, as well as display the output of the command on the... (1 Reply)
Discussion started by: akhila
1 Replies

5. Shell Programming and Scripting

Redirecting to different output files with awk.

Well, it didn't take me long to get stumped again. I assure you that I'm not mentally deficient, just new to scripting. So, here's the gist. I want to redirect output from awk based off of which branch of an if-else statement under which it falls. #!/bin/bash #some variables... (2 Replies)
Discussion started by: mikesimone
2 Replies

6. UNIX for Dummies Questions & Answers

Redirecting the multiple commands output to single file

Hi, I am new to shell scripting and have a question. I would like to redirect the output of multple commands to single file, From what I read from the bash manpage and from some searching it seems it cannot be done within the shell except setting up a loop. Is it? I am running all clearcase... (1 Reply)
Discussion started by: saku
1 Replies

7. Post Here to Contact Site Administrators and Moderators

Redirecting grep output to multiple files

Hi All, I am trying to redirect the grep output to multiple files, can you please help with that. Below is the command im using to match my pattern grep \<proxyType\>$PxyType $DIR/EndureFiles.json > File_Name*.json Note : $DIR and $PxyType is already defined in my script Im able... (0 Replies)
Discussion started by: Deena1984
0 Replies

8. Shell Programming and Scripting

Awk: Print Error While Redirecting output in multiple Files

Hi, I have a following code in which I am unable to redirect to multiple files. Can anybody please help with some corrections awk -F, '{ if ( substr($1,26,2)=="02" && substr($1,184,14)=="MTSCC_VALFIRST") { array1++ array2++ array3++ } else if (substr($1,26,2)=="03" &&... (4 Replies)
Discussion started by: siramitsharma
4 Replies

9. Shell Programming and Scripting

When redirecting tail -F output fail after log rotation?

Redirecting the tail output fails when log rotation happens even though i have used -F. But when i tail and see the output on terminal this does not happen. Note i have also used & to execute this statement in background. Suppose if i want to tail a file /opt/SAMPLE.txt and redirect its output... (1 Reply)
Discussion started by: CN1
1 Replies

10. Shell Programming and Scripting

Redirecting the results to different output files

Hi All, I am trying a shell script and need your help on taking the results to different output files. I have tried the below code: nawk ' {CNF = (length()-10)/7 printf "%9s", substr ($0, 1, 9) for (i=0; i<=CNF; i++) T = substr ($0, 10+i*7, 7) TMP = 100 - (T + T + T + T + T + T + T + T... (24 Replies)
Discussion started by: am24
24 Replies
grablogs.conf(4)						   File Formats 						  grablogs.conf(4)

NAME
grablogs.conf - grablogs configuration for libgrablogs.so of the plugins of gnome-system-log file SYNOPSIS
/usr/lib/gnome-system-log/plugins/grablogs.conf DESCRIPTION
The libgrablogs.so is a plugin for gnome-system-log(1), it colloct the log files from the system as many as possible. grablogs.conf is a configuration file that contains a set of lines mixed with sh(1) syntax codes and individual log files. libgrablogs.so will read the file try to get a log files list for gnome-system-log(1). Users can copy the file into $HOME/.gnome2/gnome-system-log/plugins/`uname -p` to overwrite the system default one. The grablogs.conf file contains the following configuration categories: [configs] Each line under this category is interpreted as a config file of System. The plugin will open the config file and try to find all system paths of the logs. [commands] Each line under this category is interpreted as a shell command and will be execute through a pipe. And each line of the out- put of the command will be interpreted as a log path. [logs] Each line under this category is interpreted as a log path. FILES
/usr/lib/gnome-system-log/plugins/grablogs.conf The system default configuration file for the plugin libgrablogs.so $HOME/.gnome2/gnome-system-log/plugins/`uname -p`/grablogs.conf The user specific configuration file for the plugin libgrablogs.so EMAMPLE
[configs] /etc/syslog.conf [commands] for i in `svcs -aH -o FMRI | grep -v lrc `; do svcprop -p restarter/logfile $i 2>/dev/null || svcprop -q -p restarter/alt_logfile $i 2>/dev/null ; done [logs] /var/log/messages /var/log/secure /var/log/maillog /var/log/cron /var/log/Xorg.0.log /var/log/XFree86.0.log /var/log/auth.log /var/log/cups/error_log SEE ALSO
gnome-system-log(1), pipelog.conf(1) gnome-utils 2.16.0 13 Oct 2006 grablogs.conf(4)
All times are GMT -4. The time now is 06:46 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy