display log at selected locations


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting display log at selected locations
# 1  
Old 12-04-2008
display log at selected locations

Hello all
I have a question on displaying log

When i am redirecting the output to a log, it displays but in a format which i am not happy about. Can i give any explicit commands which says to display the above log at specific row and column
I want to do this for each line of the log
What is want it to display first line of the log starting from row,column(1,1) and second row of log at [3,1] and so forth.
Can i do this in any way
# 2  
Old 12-04-2008
can you post a sample log file?
# 3  
Old 12-04-2008
lets say my log is

date=20-nov-2008
year=2008
month=nov

Now i want to display this as

date=20-nov-2008
year=2008
month=nov
if we carefully see this each row of above log is started at column 1 of each row. But if we see the second log 1st row is started at col1 and second row is
started at col26 and third at 40. Can i achieve this in Unix
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Read in Multiple log files and output selected variables and values to cvs file

I have several problems with my problems: I hope you can help me. 1) the If else statement I am getting an error message. My syntax must be incorrect because the entire statement is throwing an error. For example in filew.log if these items don't exist Memsize, SASFoundation and also if... (0 Replies)
Discussion started by: dellanicholson
0 Replies

2. Shell Programming and Scripting

Writing to two locations at once

I have a backup script that runs on CRON that I developed about 5 years ago. It has always worked perfectly but a recent firmware update on my QNAP TS 259 has seem to break the large file move/copy capability amongst the ESATA drives. I would like to just change my backhup.sh so that writes... (3 Replies)
Discussion started by: mackconsult
3 Replies

3. Shell Programming and Scripting

To display the selected part in text file of unix

0400903071220312 20120322 20:21 1TRANTELSTRAFLEXCAB22032012CMP201323930000812201108875802100A003485363 12122011AUS 182644 000C2 8122011 0000 000 1TRANTELSTRAFLEXCAB22032012CMP201323930000812201108875802100A003485363 12122011AUS ... (6 Replies)
Discussion started by: rammm
6 Replies

4. Shell Programming and Scripting

Need to display the output of ls -l selected columns

Hello Friends, Hope you are doing well. I am writing a shell script to find out the log file which are not updated in last 1 hours. I've almost completed the script but need your help in formatting its outputs. Currently, the output of the script is like this(as a flat row): ... (3 Replies)
Discussion started by: singh.chandan18
3 Replies

5. Programming

Variable storage locations ...

I've got the following two queries: 1) What's the difference in performance if a variable storage is at bss and not at the data section (apart from the initialization to zero in case of data section variables --like static variables). In general, why a developer need to bother about the... (1 Reply)
Discussion started by: Praveen_218
1 Replies

6. Shell Programming and Scripting

trying to print selected fields of selected lines by AWK

I am trying to print 1st, 2nd, 13th and 14th fields of a file of line numbers from 29 to 10029. I dont know how to put this in one code. Currently I am removing the selected lines by awk 'NR==29,NR==10029' File1 > File2 and then doing awk '{print $1, $2, $13, $14}' File2 > File3 Can... (3 Replies)
Discussion started by: ananyob
3 Replies

7. Solaris

file locations...

Hi Guys, There was a post that I saw here a while ago regarding file system layout and what to put where, which I am unable to find now.. A user here posted a man page that list what each partition should have in it and what it is used for and were you should install custom packages. ie:... (1 Reply)
Discussion started by: Tornado
1 Replies

8. Shell Programming and Scripting

Standard Out to Two Locations

Is it possible to redirect standard output to two locations? Unfortunately, I need to redirect it to two different files. Or if there might be any utilities that can do it. I'm suspecting not as it's all pipes and filters, but thought I'd ask. (2 Replies)
Discussion started by: GaryRudolph
2 Replies

9. UNIX for Dummies Questions & Answers

WARNING: ap: no database locations

Hi everone! My computer is ultra80,Operation system 2.6,when I boot get a message "WARNING: ap: no database locations " And then I can login root , but for other user can`t login and had message "no shell". I use csh,after login root when I su -user also had... (11 Replies)
Discussion started by: yyt19701210
11 Replies
Login or Register to Ask a Question