Hello Folks ,
myfile contains 1000000 records as follows:
after run above script I got
I need it to be
I think the problem with first "sed" of mine , need to know how to remove the space between two words in double quote "String1 space String2"
I have a script that shows me the disk SPace used by different dir under my home dir:
#!/bin/ksh
cd /ednpdtu3/u01/pipe
p1=`df -g | tail -1 | tr -s " " | cut -d " " -f2`
echo "Total Disk Space of Home Dir is $p1 GB"
p2=`df -g | tail -1 | tr -s " " | cut -d " " -f3`
echo "Total Disk Space... (2 Replies)
Hi...
i need a script to remove the space before and after the operator like( / ).
Ex :
Input file
apple / manago
mango / fresh apple / fresh
Desired output:
apple/manago
mango/fresh apple/fresh
Note: betwee the desired operator space should be removed, between words do not remove... (3 Replies)
Hello
I have a file with data something like this in it :
texttexttext "text .lst" TEXT=" text "
texttexttext "moretext .lst" TEXT=" text "
Question is how do I get rid of space so that the files looks like this :
texttexttext "text.lst" TEXT="text"
texttexttext... (8 Replies)
Hi guys,
I am new to shell scripting and I have a small problem...If someone can solve this..that would be great
I am trying to form a XML by reading a flat file using shell scripting
This is my shell script
LINE_FILE1=`cat FLEX_FILE1.TXT | head -1 | tail -1`
echo... (1 Reply)
I created a awk state to calculate the number of success however when the query runs it has a leading zero. Any ideas on how to remove the leading zero from the calculation?
Here is my query:
cat myfile.log | grep | awk '{print $2,$3,$7,$11,$15,$19,$23,$27,$31,$35($19/$15*100)}'
02:00:00... (1 Reply)
Hi,
I have file which contains following lines
A| 965.|Mr.|35.45| 66.
B| 33.| a456.| 77.
The output should be
A|965|Mr.|35.45|66
B|33| a456.|77
Basically if a Number has space in prefix and . in suffix remove both.
So pattern could be if there is a | which has next two characters as... (1 Reply)
Hello,
I need help. I have xml file and there are one extra space on number <EpiReference>1 42345</EpiReference>. And of cource, the value change on every new file. I need remove space from that value what is in between <EpiReference> and </EpiReference>. How I can do that?
This are example... (9 Replies)
Discussion started by: Jopsulainen
9 Replies
LEARN ABOUT NETBSD
ipmon
IPMON(5) File Formats Manual IPMON(5)NAME
ipmon, ipmon.conf - ipmon configuration file format
DESCRIPTION
The format for files accepted by ipmon is described by the following grammar:
"match" "{" matchlist "}" "do" "{" doing "}" ";"
matchlist ::= matching [ "," matching ] .
matching ::= direction | dstip | dstport | every | group | interface |
logtag | nattag | protocol | result | rule | srcip | srcport .
dolist ::= doing [ "," doing ] .
doing ::= execute | save | syslog .
direction ::= "in" | "out" .
dstip ::= "dstip" "=" ipv4 "/" number .
dstport ::= "dstport" "=" number .
every ::= "every" every-options .
execute ::= "execute" "=" string .
group ::= "group" "=" string | "group" "=" number .
interface ::= "interface" "=" string .
logtag ::= "logtag" "=" string | "logtag" "=" number .
nattag ::= "nattag" "=" string .
protocol ::= "protocol" "=" string | "protocol" "=" number .
result ::= "result" "=" result-option .
rule ::= "rule" "=" number .
srcip ::= "srcip" "=" ipv4 "/" number .
srcport ::= "srcport" "=" number .
type ::= "type" "=" ipftype .
ipv4 ::= number "." number "." number "." number .
every-options ::= "second" | number "seconds" | "packet" | number "packets" .
result-option ::= "pass" | "block" | "short" | "nomatch" | "log" .
ipftype ::= "ipf" | "nat" | "state" .
In addition, lines that start with a # are considered to be comments.
OVERVIEW
The ipmon configuration file is used for defining rules to be executed when logging records are read from /dev/ipl.
At present, only IPv4 matching is available for source/destination address matching.
MATCHING
Each rule for ipmon consists of two primary segments: the first describes how the log record is to be matched, the second defines what
action to take if there is a positive match. All entries of the rules present in the file are compared for matches - there is no first or
last rule match.
FILES
/dev/ipl
/dev/ipf
/dev/ipnat
/dev/ipstate
/etc/ipmon.conf
SEE ALSO ipmon(8), ipl(4)IPMON(5)