Sponsored Content
Full Discussion: [Solved] Adding a column.
Operating Systems HP-UX [Solved] Adding a column. Post 302697745 by methyl on Friday 7th of September 2012 09:59:44 AM
Old 09-07-2012
I don't think that HP-UX top is suitable for further processing because the output is formatted with VDU control sequences and only the first page of process list is output.

What figure are you trying to calculate? The sum of the running sizes of processes really has no meaning on a paged Operating System.


Footnote: The output from the Berkeley format ps command is easier to deal with in scripts:
For example: Size of each process in 1024 byte units:
Code:
# The space character after UNIX95= is mandatory
UNIX95= ps -e -o vsz | grep -v "VSZ"

These 2 Users Gave Thanks to methyl For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Rename a header column by adding another column entry to the header column name URGENT!!

Hi All, I have a file example.csv which looks like this GrpID,TargetID,Signal,Avg_Num CSCH74_1_1,2007,61,256 CSCH74_1_1,212007,647,679 CSCH74_1_1,12007,3,32 CSCH74_1_1,207,299,777 I want the output as GrpID,TragetID,Signal-CSCH74_1_1,Avg_Num CSCH74_1_1,2007,61,256... (4 Replies)
Discussion started by: Vavad
4 Replies

2. UNIX for Dummies Questions & Answers

Rename a header column by adding another column entry to the header column name

Hi All, I have a file example.csv which looks like this GrpID,TargetID,Signal,Avg_Num CSCH74_1_1,2007,61,256 CSCH74_1_1,212007,647,679 CSCH74_1_1,12007,3,32 CSCH74_1_1,207,299,777 I want the output as GrpID,TragetID,Signal-CSCH74_1_1,Avg_Num CSCH74_1_1,2007,61,256... (1 Reply)
Discussion started by: Vavad
1 Replies

3. UNIX for Dummies Questions & Answers

[Solved] Adding time stamp to file name

I have the awk awk -F\* '$1=="ST",$1=="SE"{if($1=="ST"){close(f);f="sample" ++i} ; $1=$1; print>f}' OFS=\| <filename> How to add the time stamp to the file name mentioned as "sample" Please view this code tag video for how to use code tags when posting code and data. (6 Replies)
Discussion started by: atlantis_yy
6 Replies

4. Shell Programming and Scripting

[Solved] adding email option to KSH

Hi, I wanted to add a email option to this script. and was wondering if anyone could help me out. #!/bin/ksh echo "Finding hdisk" <DIR>/find-disk i=1 b=0 p=0 while ... (2 Replies)
Discussion started by: vpundit
2 Replies

5. UNIX for Dummies Questions & Answers

[Solved] Deleting all rows where the first column equals the second column

Hi, I have a tab delimited text file where the first two columns equal numbers. I want to delete all rows where the value in the first column equals the second column. How do I go about doing that? Thanks! Input: 1 1 ABC DEF 2 2 IJK LMN 1 2 ZYX OPW Output: 1 2 ZYX OPW (2 Replies)
Discussion started by: evelibertine
2 Replies

6. Shell Programming and Scripting

[Solved] Sorting a column based on another column

hello, I have a file as follows: F0100010 A C F0100040 A G BTA-28763-no-rs 77.2692 F0100020 A G F0100030 A T BTA-29334-no-rs 11.4989 F0100030 A T F0100020 A G BTA-29515-no-rs 127.006 F0100040 A G F0100010 A C BTA-29644-no-rs 7.29827 F0100050 A... (9 Replies)
Discussion started by: Homa
9 Replies

7. Shell Programming and Scripting

[Solved] Password query even after adding public key

Dears I am running a shell script to backup (transfer) files to a networked External HDD. Even though the public key has been added it still asks for the password before starting the transfer. Any suggestions? Thanks in advance. (8 Replies)
Discussion started by: BrownBob
8 Replies

8. Hardware

[solved] Sun Netra X1 - Adding a Second Hard Drive

As the title suggests, I'm trying to install a second drive (really want an OS mirror) on a Sun Netra X1. I've taken the spacer out, and had a go at with the drill-press so now I have a nice HDD tray. Have installed an IDE drive in the tray, plugged in the power and data cables that were... (0 Replies)
Discussion started by: Smiling Dragon
0 Replies

9. Linux

[SOLVED] Trouble adding Tun module

So I have Ubuntu running on a sheevaplug develop kit, but the damn kernel thing doesn't come with /dev/tun enabled. It was suggested that I look into using module assistant to compile & get this set up but I'm having issues. Linux ubuntu 2.6.39.4 #2 PREEMPT Fri Aug 5 19:05:11 MDT 2011 armv5tel... (4 Replies)
Discussion started by: dpreviti
4 Replies

10. Shell Programming and Scripting

Adding values of a column based on another column

Hello, I have a data such as this: ENSGALG00000000189 329 G A 4 2 0 ENSGALG00000000189 518 T C 5 1 0 ENSGALG00000000189 1104 G A 5 1 0 ENSGALG00000000187 3687 G T 5 1 0 ENSGALG00000000187 4533 A T 4 2 0 ENSGALG00000000233 5811 T C 4 2 0 ENSGALG00000000233 5998 C A 5 1 0 I want to... (3 Replies)
Discussion started by: Homa
3 Replies
OD(1)							    BSD General Commands Manual 						     OD(1)

NAME
od -- octal, decimal, hex, ascii dump SYNOPSIS
od [-aBbcDdeFfHhIiLlOovXx] [-A base] [-j skip] [-N length] [-t type_string] [[+]offset[.][Bb]] file ... DESCRIPTION
The options are as follows: -A base Specify the input address base. base may be one of 'd', 'o', 'x' or 'n', which specify decimal, octal, hexadecimal addresses or no address, respectively. -a One-byte character display. Display the input offset in octal, followed by sixteen space-separated, three column, space-filled, characters of input data per line. Control characters are printed as their names instead of as C-style escapes. -B Same as -o. -b One-byte octal display. Display the input offset in octal, followed by sixteen space-separated, three column, zero-filled, bytes of input data, in octal, per line. This is the default output style if no other is selected. -c One-byte character display. Display the input offset in octal, followed by sixteen space-separated, three column, space-filled, characters of input data per line. Control characters are printed at C-style escapes, or as three octal digits, if no C escape exists for the character. -d Two-byte decimal display. Display the input offset in octal, followed by eight space-separated, five column, zero-filled, two- byte units of input data, in unsigned decimal, per line. -e Eight-byte floating point display. Display the input offset in octal, followed by two space-separated, twenty-one column, space filled, eight byte units of input data, in floating point, per line. -F Same as -e. -f Four-byte floating point display. Display the input offset in octal, followed by four space-separated, 14 column, space filled, four byte units of input data, in floating point, per line. -H Four-byte hex display. Display the input offset in octal, followed by four space-separated, eight column, zero filled, four byte units of input data, in hex, per line. -h Two-byte hex display. Display the input offset in octal, followed by eight space-separated, four column, zero filled, two byte units of input data, in hex, per line. -I Four-byte decimal display. Display the input offset in octal, followed by four space-separated, eleven column, space filled, four byte units of input data, in decimal, per line. -i Two-byte decimal display. Display the input offset in octal, followed by eight space-separated, six column, space filled, two- byte units of input data, in decimal, per line. -j offset Skip offset bytes from the beginning of the input. By default, offset is interpreted as a decimal number. With a leading 0x or 0X, offset is interpreted as a hexadecimal number, otherwise, with a leading 0, offset is interpreted as an octal number. Appending the character b, k, or m to offset causes it to be interpreted as a multiple of 512, 1024, or 1048576, respectively. -L Same as -I. -l Same as -I. -N length Interpret only length bytes of input. -O Four-byte octal display. Display the input offset in octal, followed by four space-separated, eleven column, zero-filled, four- byte units of input data, in octal, per line. -o Two-byte octal display. Display the input offset in octal, followed by eight space-separated, six column, zero-filled, two-byte units of input data, in octal, per line. -t type_string Specify one or more output types. The type_string option-argument must be a string specifying the types to be used when writing the input data. The string must consist of the type specification characters: a selects US-ASCII output, with control characters replaced with their names instead of as C escape sequences. See also the _u conversion provided by hexdump(1). c selects a standard character based conversion. See also the _c conversion provided by hexdump(1). f selects the floating point output format. This type character can be optionally followed by the characters 4 or F to specify four byte floating point output, or 8 or L to specify eight byte floating point output. The default output format is eight byte floats. See also the e conversion provided by hexdump(1). d, o, u, or x select decimal, octal, unsigned decimal, or hex output respectively. These types can optionally be followed by C to specify char-sized output, S to specify short-sized output, I to specify int-sized output, L to specify long-sized output, 1 to specify one-byte output, 2 to specify two-byte output, 4 to specify four-byte output, or 8 to specify eight-byte output. The default output format is in four-byte quantities. See also the d, o, u, and x conversions provided by hexdump(1). -v The -v option causes od to display all input data. Without the -v option, any number of groups of output lines, which would be identical to the immediately preceding group of output lines (except for the input offsets), are replaced with a line comprised of a single asterisk. -X Same as -H. -x Same as -h. For each input file, od sequentially copies the input to standard output, transforming the data according to the options given. If no options are specified, the default display is equivalent to specifying the -o option. od exits 0 on success and >0 if an error occurred. SEE ALSO
hexdump(1), strings(1) HISTORY
A od command appears in Version 1 AT&T UNIX. This man page was written in February 2001 by Andrew Brown, shortly after he augmented the deprecated od syntax to include things he felt had been missing for a long time. BSD
February 9, 2010 BSD
All times are GMT -4. The time now is 03:04 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy