Search Results

Search: Posts Made By: drbiloukos
1,607
Posted By RudiC
Howsoever, tryawk ' {sub...
Howsoever, tryawk '
{sub (/icmp_seq=/, "", $5)
}
NR==1 {last=$5
}
$5-last > 1 {print "ping failed"
}
...
1,607
Posted By RudiC
As Don Cragun always says: "If you are using a...
As Don Cragun always says:
"If you are using a Solaris/SunOS system, use /usr/xpg4/bin/awk or nawk instead of awk ."
2,390
Posted By RudiC
awk 'gsub(/[^|]*B0300\|/,"0|")' file
awk 'gsub(/[^|]*B0300\|/,"0|")' file
2,390
Posted By Yoda
sed 's#\([^|]*B0300\)\([|]\)#0\2#g' filename
sed 's#\([^|]*B0300\)\([|]\)#0\2#g' filename
2,390
Posted By RavinderSingh13
Hello drbiloukos, Please use code tags as...
Hello drbiloukos,

Please use code tags as per forum rules for inputs/codes which you are using for your posts. Could you please use following and let me know if this helps you.

echo...
1,996
Posted By clx
Have you searched? I have got this...
Have you searched? I have got this (https://www.unix.com/shell-programming-and-scripting/118534-sendmail-attachments-2.html) at first attempt.
1,692
Posted By vgersh99
awk '{for(i=s+1;i<=NF-e;i++) printf("%s%c",...
awk '{for(i=s+1;i<=NF-e;i++) printf("%s%c", $i,(i==NF-e)?ORS:OFS)}' s=8 e=16 FS=, OFS=, myFile
7,488
Posted By pamu
with awk..:) awk 'NR%2{$0="some text...
with awk..:)


awk 'NR%2{$0="some text "$0}1' file
7,488
Posted By elixir_sinari
Something simpler and what you require: cat...
Something simpler and what you require:
cat testfile
ABCD
EFGH
IJKL
MNOP
PQRS

sed 's/.*/NEW TEXT &/;n' testfile
NEW TEXT ABCD
EFGH
NEW TEXT IJKL
MNOP
NEW TEXT PQRS
Forum: HP-UX 07-13-2012
3,330
Posted By vbe
By files you mean you want only regular files? ...
By files you mean you want only regular files?

ant:/home $ df -i .
/home (/dev/vg00/lvol5 ) : 34112 total i-nodes
...
Forum: HP-UX 07-13-2012
3,330
Posted By vbe
So my find command is what you need... look at my...
So my find command is what you need... look at my comparison above...
1,568
Posted By knight_eon
Try: #!/bin/ksh FS[1]="\/$" awk...
Try:


#!/bin/ksh
FS[1]="\/$"
awk '/'"${FS[1]}"'/ {print $(NF-1)+0}' df.tmp
2,004
Posted By vbe
It gets a * when it becomes executable not...
It gets a * when it becomes executable not because of chmod, try chmod 644 and compare the result...
2,004
Posted By Skrynesaver
your ll is an alias to ls -lF the -F option...
your ll is an alias to ls -lF the -F option causes ls to display a trailing identifier as to the nature of the file the alias is probably in your .profile, .bash_profile or .bashrc file
4,226
Posted By itkamaraj
$ awk '/RBA/ {print $NF}' input.txt 15911688
$ awk '/RBA/ {print $NF}' input.txt
15911688
4,823
Posted By haaru
Variable scope in bash
Hello! Before you "bash" me with
- Not another post of this kind
Please read on and you will understand my problem...

I am using the below to extract a sum of the diskIO on a Solaris server.
...
1,371
Posted By methyl
Space character missing after "if" .
Space character missing after "if" .
Forum: Solaris 01-02-2012
2,175
Posted By jim mcnamara
Short answer: The remote system does not...
Short answer:
The remote system does not support the character set, and whatever script is on the remote side (I am assuming you copied something like .profile over there): what that script asks for...
4,082
Posted By Scott
-gt should be just fine. Echo the value of...
-gt should be just fine.

Echo the value of $SESSION_NO before the test. Perhaps it contains "other stuff" (i.e. does your SQL have "feedback off" set, etc).
7,703
Posted By jayan_jay
$ awk '{print "before_"$0"_after"}' infile $ ...
$ awk '{print "before_"$0"_after"}' infile
$
$ perl -pe 's/(.*)/before_$1_after/' infile
1,160
Posted By Shell_Life
See if this works for you: grep -q STOPPED...
See if this works for you:
grep -q STOPPED /tmp/msg1$$
if [[ $? -eq 0 ]]; then
if [[ ! -f Found_Stopped ]]; then
mailx -s "GOLDEN GATE PROCESS ABENDED ON $SERVER_NAME" $RECEIPIENT <...
1,880
Posted By CarloM
Try nawk instead of awk. EDIT: (or GNU awk,...
Try nawk instead of awk.

EDIT: (or GNU awk, which apparently is what I'm using)
1,880
Posted By unxscorob
that would be an if statement comparing NR with...
that would be an if statement comparing NR with the line number to ignore. something basically like this.
awk '{if (NR != 1) print int($(NF-1))}'
1,880
Posted By unxscorob
try this, and here's a reference to some good awk...
try this, and here's a reference to some good awk one-liners, http://www.pement.org/awk/awk1line.txt

df -h /app/oracle | awk '!/Filesystem/{ sub(/%/, ""); print $(NF-1); }'
16,575
Posted By agn
[~]> echo...
[~]> echo "73423555","73423556","73423557","73423558","73423559" | awk 'BEGIN { RS="," }1'
73423555
73423556
73423557
73423558
73423559
Showing results 1 to 25 of 75

 
All times are GMT -4. The time now is 05:31 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy