I'm fairly new to this and learning along the way, so bare with me...
I'm trying to format the output from a script to be more read-friendly.
The output contains more servers and more processes but for as example it will do:
I'm trying to build a AWK script that loops for each server and checks if every process state is running. If the processes are all running the script should print "OK", if one process got a different state is should print a error for that server.
AWK output should be something like this:
So far I have very little, I cant even get the loop to work....
Hi All,
I am trying to check if if column 5 is greater than 90. If greater it will print the term in column 6, else if all are within limit, then it will output "Size is within limit". I can't seem to do that with the below code. The output should only be 1 statement of "Size is within the... (4 Replies)
hi all,
i have a problem with my nawk command output below is the description :
nawk $12 == "00008001" { cnt++;cs_cd } END {for(cd in cs_cd) print cd, cs_cd } 2007020814.TDR
output :
133
123
desire output:
133,123,....
please advices
thank you so much (6 Replies)
Guys,
I have a script which hits the database and pulls the information that I need into files. Now I want to format these files to make them easy to read.
The sample format of the file will be like....
<Start_of_File>
Header1 .....xsdfsfa...adfa......
Header2 ....afefas .aefaefsdf...... (8 Replies)
Hi Experts,
I am adding a column of numbers with awk , however not getting correct output:
# awk '{sum+=$1} END {print sum}' datafile
2.15291e+06
How can I getthe output like : 2152910
Thank you..
# awk '{sum+=$1} END {print sum}' datafile
2.15079e+06 (3 Replies)
awk experts,
I have in put file with time stamp followed by "," separated data. same patern continues. The output need time stamp in first columns and data total in 2nd columns.
Input file
T 9:15
d0,1,3,3
d1,2,1,1
d2,3,1,5
e1,1,1,1
T 9:30
d0,1,1,1
d1,2,3,2
d3,1,2,1... (10 Replies)
hi
i have a awk command with several querys....
awk 'FS="|""; print $4, $5, $6...etc....
$4 gives me the date 20120304
$5 is timestamp 101023
I want to format these in
2012.03.04 or 2012/03/04
10:10:23
but have no idea, if this is possible with format-parameters in the awk... (2 Replies)
Hello all , need help with this ...
Input File
DEV % POOL
0CB4 FBA 2211300 81792 4 IE RAID-5(3+1) R5_EFD100_1
- - 1805376 82 IF RAID-1 M2_FC300_1
- ... (4 Replies)
I've been diving into awk but still learning how to use it for text formatting. Below you can see my results are separated by a comma. Can somebody show me how to separate by TAB as well? An explanation would be appreciated as I did not comprehend the answer in the man pages and would like to gain... (1 Reply)
Hi ,
i am generating some data by firing sql query with connecting to the database by my solaris box.
The below one should be the header line of my excel ,here its coming in separate row.
TO_CHAR(C. CURR_EMP_NO
---------- ---------------
LST_NM... (6 Replies)
Discussion started by: dani1234
6 Replies
LEARN ABOUT MINIX
ps
PS(1) General Commands Manual PS(1)NAME
ps - process status
SYNOPSIS
ps [-alxU] [kernel mm fs]
OPTIONS -a Print all processes with controlling terminals
-l Give long listing
-x Include processes without a terminal
EXAMPLES
ps -axl # Print all processes and tasks in long format
DESCRIPTION
Ps prints the status of active processes. Normally only the caller's own processes are listed in short format (the PID, TTY, TIME and CMD
fields as explained below). The long listing contains:
F Kernel flags: 001: free slot 002: no memory map 004: sending; 010: receiving 020:
inform on pending signals 040: pending signals 100: being traced.
S State: R: runnable W: waiting (on a message) S: sleeping (i.e.,suspended on MM or FS) Z:
zombie T: stopped
UID, PID, PPID, PGRP The user, process, parent process and process group ID's.
SZ Size of the process in kilobytes.
RECV Process/task on which a receiving process is waiting or sleeping.
TTY Controlling tty for the process.
TIME Process' cumulative (user + system) execution time.
CMD Command line arguments of the process.
The files /dev/{mem,kmem} are used to read the system tables and command line arguments from. Terminal names in /dev are used to generate
the mnemonic names in the TTY column, so ps is independent of terminal naming conventions.
PS(1)