I have very big log file around 2-3 GB in that it contians 24 hours log data. My work is extract only 5-5 data and count the patterns from them. I worte a script in linux and we're using that.
Now we need to change that to Solaris 9. Some of the functions we cant use in solaris i opted the below one
Could please tune my script, I have more than 15 patterns. Is it right way to do that..? Since my grep -f is not working in Solaris i'm opted for egrep.
Your title said tune my script, which usually means: make faster. So without thinking I created this awk script:
Which should process the log in one go, but I guess that is not what you were after. But perhaps it is useful anyway. On Solaris use nawk or /usr/xpg4/bin/awk
If i use the awk i got an error
any way that /usr/xpg4/bin/grep has the -f flag so i served me the purpose.
One more little help from unix experts..this grep wont have the -A flag. So i am opting for
but how serach for more than one PATTERN.
Last edited by Yogesh Sawant; 12-31-2009 at 12:40 PM..
Reason: added code tags
Hi !
My script read out data out of 144 files per day - every ten minutes a file with data.
data-file
WR030B 306.71 0
WR050B 315.13 0
WR120B 308.34 0
WV030B 3.52 0
WV050B 5.06 0
WV120B 6.65 0
TLUFT02B 8.60... (3 Replies)
Running 2 VM Guests on an HPUX Integrity Server. One Guest runs great, the other is always at a high NICE value and 0% idle as shown in TOP:
What do you think should be tuned to bring down the NICE and increase IDLE %? Thanks in advance
-hpuxadmin
slow VM GUEST
Load averages: 2.56,... (5 Replies)
Hi,
I have this routine that reads a microsoft dhcp.netsh dump. Where it finds optionvalue 3 STRING "0.0.0.0"
Replace it with the router IP based on the network
!/usr/bin/perl
while ( <> )
{
if ( /\# NET / ) { $net = $'; $net =~ s///g; }
else
{
s/set optionvalue 3... (1 Reply)
Can some body tune the below command, its occupyinh more than 90% of CPU some times.
tail -n 1000 /logs/trace.log | awk 'BEGIN{OOM = 0; ScE = 0; NaE = 0; Jms = 0}
/OutOfMemoryException/{OOM = 1}
/StaleConnectionException/{ScE = 1}
/NamingException/{NaE = 1}
/JmsTimeOutException/{Jms = 1}... (17 Replies)
I have a requirement to separate only some numbers from the input file and produce it in a format.
The input is ( i have took a sample, the actual file contains more than 50000 rows around 840 MB in size)
$cat temp.txt
001 08 002 08 003 06 004 11 005 11 006 08
007 08 008 92* 009 92 010... (1 Reply)
Hi,
As a a security audit, how can I proceed further with Fine tuning and Hardening the linux kernel... I am not sure with the steps how to proceed further... If i do some thing wrong, then its comes with the Kernel panic error. So, I am afraid, how to do the tuning with the kernel.. (1 Reply)
I have big log file, which contains the netstat output from my application server to a particular DB server. I aim is to plot a daily graph for this. Please find the sample log file below.
@ - ...........................................................
@ - Total number of connection to the ... (3 Replies)
Hi,
I want to tune my SUN servers for best performance. My servers are heavily loaded and used. They have Solaris 10. How to tune Kernel Parameters of solaris ? And How can I measue performance before changing parameters and after changing parameters ?
Please help
Thanks
NeeleshG (2 Replies)