Sponsored Content
Full Discussion: tail -f for multiple files
Top Forums Shell Programming and Scripting tail -f for multiple files Post 302508152 by ni2 on Saturday 26th of March 2011 07:37:46 AM
Old 03-26-2011
Quote:
Originally Posted by theboogymaster
I'm using REHEL 5 and the multiple file tailing does not work in the same time .. how can you tail 2 files and show them both in the same time on juste one terminal ?
I am currently on Ubuntu.
I installed multitail using
Code:
sudo apt-get install multitail

Then tried it out
Code:
shell>multitail file1 file2

It displayed both files on the same terminal. There are screen shots here

Code:
http://www.vanheusden.com/multitail/

This User Gave Thanks to ni2 For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Tail-alike display of new files in directory

The system I work on, produces several kinds of status-files in a single directory. I would like to be able to see the files as they are added to this directory. I was wondering if it would be possible to get a "tail -f" alike view of the ls-command, in such a way that a newly added file is... (4 Replies)
Discussion started by: rschelkers
4 Replies

2. UNIX for Dummies Questions & Answers

Constantly updating log files (tail -f? grep? awk?)

I have a log file which is continuously added to, called log.file. I'd like to monitor this file, and when certain lines are found, update some totals in another file. I've played around with tail -f, grep, and awk, but can't seem to hit the right note, so to speak. The lines I'm... (0 Replies)
Discussion started by: nortonloaf
0 Replies

3. Shell Programming and Scripting

Drop common lines at head/tail of a large set of files

Hi! I have a large set of pairs of text files (each pair in their own subdirectory) and each pair shares head/tail (a couple of first and last lines) but differs in the middle part. I need to delete the heads/tails and keep only the middle portions in which they differ. The lengths of heads/tails... (1 Reply)
Discussion started by: dobryden
1 Replies

4. Solaris

Tail for multiple files

Hi there, I'm trying to run a simple command in Solaris 10: tail -10 *.log But this gives me in the output just last 10 rows of a SINGLE log file :eek: (and there are many in active directory). Please, do you have any idea what's the problem? :confused: Is it a Solaris issue? Thank you in... (2 Replies)
Discussion started by: MartinF
2 Replies

5. UNIX for Dummies Questions & Answers

Using AWK: Extract data from multiple files and output to multiple new files

Hi, I'd like to process multiple files. For example: file1.txt file2.txt file3.txt Each file contains several lines of data. I want to extract a piece of data and output it to a new file. file1.txt ----> newfile1.txt file2.txt ----> newfile2.txt file3.txt ----> newfile3.txt Here is... (3 Replies)
Discussion started by: Liverpaul09
3 Replies

6. Shell Programming and Scripting

head / tail combination returns multiple rows

Hi, As part of our project, we need to load historical data for a year before our system is live. We have the data feed files that we need to load. However, I need to make sure that the file structure (number of fields separated by a comma) on the field is same for all the files of the same... (1 Reply)
Discussion started by: raj.jha
1 Replies

7. Shell Programming and Scripting

Multiple tail -f commands

I need to execute a program which will generate some alarms. I wish to capture those alarms in a single output file. I executed with following command on linux: tail -f test1.alarms -f test2.alarms|awk 'NR>20' >> output But however when I tried to execute same on solaris platforms it fails.... (2 Replies)
Discussion started by: bhallarandeep
2 Replies

8. Shell Programming and Scripting

how to run tail -f for 3 log files from a script

hi i need to run from a bash script tail -f /var/log/access_log >> access1 tail -f /var/log/prod/prod1 >> access1 tail -f /var/log/prod/prod2 >> access1 this script purpose is to start at server boot time and should always run. what is the best way to put it on a script Thanks Dan (1 Reply)
Discussion started by: dan12341234
1 Replies

9. Shell Programming and Scripting

prevent multiple tail in back ground

Dears i have a scrip run in unix that need to use the tail -f command, as below: DATE=`date '+%m%d%y'` tail -f /var/messages | grep "start" >> /export/logs/start_${DATE}.out but the problem that the tail -f will be stop and working in the background in then end of the day (23:59:59)... (0 Replies)
Discussion started by: thehero
0 Replies

10. Shell Programming and Scripting

Joining multiple files tail on tail

I have 250 files that have 16 columns each - all numbered as follows stat.1000, stat.1001, stat.1002, stat.1003....stat.1250. I would like to join all 250 of them together tail by tail as follows. For example stat.1000 a b c d e f stat.1001 g h i j k l So that my output... (2 Replies)
Discussion started by: kayak
2 Replies
SINCE(1)							   User Manuals 							  SINCE(1)

NAME
since - display content of a file since the last time SYNOPSIS
since [-aefhlmnqvxz] [-d seconds] [-s file] files DESCRIPTION
since is a utility designed to monitor log files. since is similar to tail(2) as it also displays information appended to a file. However since only displays the data which has been added since the last time since was run. If since is run on a particular file for the first time, then the entire file is displayed. EXAMPLE
since /var/log/apache/{access,error}_log > /dev/null lynx --dump http://localhost/ > /dev/null since /var/log/apache/{access,error}_log OPTIONS
-a Make updates to the since state files atomic. This option configures since to use a temporary file and a rename(2) instead of updat- ing the state file in situ. -d seconds Specify the number of integer seconds to wait between polling files for changes. This option is only relevant in conjunction with the -f option and if the inotify mechanism is not being used. -e Print the header lines to standard error instead of standard output. -f Follow the specified files. This option is analogous to tail -f as the files are also polled for changes until the process is inter- rupted. -h Print a terse help message. -l Relaxed mode. If some data files are inaccessible since will not fail completely. -m Disable mmap(2), use read(2) instead to access state and data files. Note that for certain smaller io operations read(2) may be used even if this option has not been given. -n Do not update the .since file which keeps track of file growth. -q Make the utility operate more quietly. -s filename Specify the state file explicitly. Using this option will also disable the use of fallback state files. -v Increase the verbosity. This option can be given multiple times. -x Ignore file arguments which have compressed extensions. -z Discard output. Similar to redirecting the output to /dev/null, but faster. If used in conjunction with the -f option, only the ini- tial output will be discarded. FILES
.since State file recording the length of the previously displayed files. The location of the file can be set on the command line using the -s option. If this option is not given, since will check the SINCE environment variable for the location of the state file. If the SINCE environment variable has not been set since will use the HOME environment variable and store the information in the file $HOME/.since. If the HOME variable is not set, since will use a getpwuid(3) lookup. If all these fail will use the file /tmp/since. BUGS
since uses the inode of a file as its key, if that inode is recycled since will get confused. since is not particularly efficient when storing or looking up the stat(2) information. Functionality equivalent to since can probably be achieved with a number of trivial shell scripts. COPYING
since may only be used, distributed and modified in accordance with the terms of the GPL (GNU General Public License) version 3 or newer as published by the FSF (Free Software Foundation). SEE ALSO
tail(1), stat(2). Linux JULY 1998 SINCE(1)
All times are GMT -4. The time now is 08:04 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy