Hi,
I need to count the number of occurences of the character " in a file that contains huge number of records.
What command could I use?
Please specify in detail since I am new :|
Thanks much. (3 Replies)
Hi,
I've been trying to create a perl file to run something very specific. But I'm not getting any success. I'm not very good with hashing.
I have a file with two columns (tab separated) (already sorted)
99890 +
100281 +
104919 -
109672 +
113428 -
114501 +
115357 +
115598 ... (7 Replies)
Hi All,
Is it possible to count number of occurrences of a pattern in a single record using awk??
for example:
a line like this:
abrsjdfhafa
I want to count the number of a character occurrences. but still use the default RS, I don't want to set RS to single character. (1 Reply)
Hi,
I need a shell script which can provide details from error logs like this
Aug 23 21:19:41 red mountd: authenticated mount request from bl0110.bang.m
pc.local:651 for /disk1/jobs (/disk1)
Aug 23 08:49:52 red dhcpd: DHCPDISCOVER from 00:25:90:2b:cd:7c via eth0: unknown client
Aug 24... (2 Replies)
Hey Unix gurus,
I would like to count the number occurrences of all the words (regardless of case) across multiple files, preferably outputting them in descending order of occurrence. This is well beyond my paltry shell scripting ability.
Researching, I can find many scripts/commands that... (4 Replies)
Hi,
I need help to count the number of occurrences in $3 of file1.txt. I only know how to count by checking one by one and the code is like this:
awk '$3 ~ /aku hanya poyo/ {++c} END {print c}' FS="\t" file1.txt
But this is not wise to do as i have hundreds of different occurrences in that... (10 Replies)
Hello,
I have a file like following:
ALB_13554 1 1 1
ALB_13554 1 2 1
ALB_18544 2 0 2
ALB_18544 1 0 1
This is a sample of my file, my real file has 441845 number of fields. What I want to do is to calculate the number of 1 and 2 in each column using AWK, so, the output file looks like... (5 Replies)
Hi,
I have two text files (1.txt and 2.txt).
2.txt contains two columns which are extracted from 1.txt using a simple if(condition) print.
I want to:
- count how many times the values contained in 2.txt appear in 1.txt
-if they appear just one time, I have to delete the entire row in... (5 Replies)
Hi all,
I have a quick question:
I have a 4 column tab-separated file.
I want to count the number of times each unique value in column 2 appears and add that number in a 5th column.
I have the following input file:
waterline-n below-sheath-v 14.8097 A
dock-n below-sheath-v ... (4 Replies)
Discussion started by: owwow14
4 Replies
LEARN ABOUT OSX
iotop
iotop(1m) USER COMMANDS iotop(1m)NAME
iotop - display top disk I/O events by process. Uses DTrace.
SYNOPSIS
iotop [-C] [-D|-o|-P] [-j|-Z] [-d device] [-f filename] [-m mount_point] [-t top] [interval [count]]
DESCRIPTION
iotop tracks disk I/O by process, and prints a summary report that is refreshed every interval.
This is measuring disk events that have made it past system caches.
Since this uses DTrace, only users with root privileges can run this command.
OPTIONS -C don't clear the screen
-D print delta times - elapsed, us
-j print project ID
-o print disk delta times, us
-P print %I/O (disk delta times)
-Z print zone ID
-d device
instance name to snoop (eg, dad0)
-f filename
full pathname of file to snoop
-m mount_point
mountpoint for filesystem to snoop
-t top print top number only
EXAMPLES
Default output, print summary every 5 seconds
# iotop
One second samples,
# iotop 1
print %I/O (time based),
# iotop -P
Snoop events on the root filesystem only,
# iotop -m /
Print top 20 lines only,
# iotop -t 20
Print 12 x 5 second samples, scrolling,
# iotop -C 5 12
FIELDS
UID user ID
PID process ID
PPID parent process ID
PROJ project ID
ZONE zone ID
CMD command name for the process
DEVICE device name
MAJ device major number
MIN device minor number
D direction, Read or Write
BYTES total size of operations, bytes
ELAPSED
total elapsed times from request to completion, us (this is the elapsed time from the disk request (strategy) to the disk completion
(iodone))
DISKTIME
total times for disk to complete request, us (this is the time for the disk to complete that event since it's last event (time
between iodones), or, the time to the strategy if the disk had been idle)
%I/O percent disk I/O, based on time (DISKTIME)
load 1 minute load average
disk_r total disk read Kb for sample
disk_w total disk write Kb for sample
DOCUMENTATION
See the DTraceToolkit for further documentation under the Docs directory. The DTraceToolkit docs may include full worked examples with ver-
bose descriptions explaining the output.
EXIT
iotop will run forever until Ctrl-C is hit, or the specified interval is reached.
AUTHOR
Brendan Gregg [Sydney, Australia]
SEE ALSO iosnoop(1M), dtrace(1M)version 0.75 Oct 25, 2005 iotop(1m)