Visit The New, Modern Unix Linux Community

Search Results

Search: Posts Made By: ryandegreat25
1,302
Posted By ryandegreat25
[SOLVED] Using expect
Please help me guys with this, its my first time using expect.

heres what i wanted to do. inputs are in red
sitescope@server:/opt/HP/SiteScope/bin> ./config_tool.sh -i console
This wizard...
976
Posted By ryandegreat25
how do i do that?
how do i do that?
1,602
Posted By ryandegreat25
oops didnt see that one. looking good now! :)
oops didnt see that one. looking good now! :)
1,602
Posted By ryandegreat25
sure. here is the input file [oracle@server...
sure. here is the input file

[oracle@server logs]$ head -1 /opt/application.log | awk 1 RS='\t'
2013/08/07 04:48:36:685
NORMAL
Oracle
Oracle:server.testpoc.com:Health:Connection Statistics...
1,602
Posted By ryandegreat25
nah, i cant do that the error messages will have...
nah, i cant do that the error messages will have variable spacing in them, especially for long or short error messages. so the only way is to delimit using tabs.

---------- Post updated at 07:03...
1,602
Posted By ryandegreat25
actually there are many spaces in the input file...
actually there are many spaces in the input file so i will need to work on using tabs. see 1 line sample below.

2013/08/07 05:07:38:642 CRITICAL Oracle ...
1,602
Posted By ryandegreat25
it doesnt work in my case. is this linux distro...
it doesnt work in my case. is this linux distro dependent? i am running redhat. i need to get the column tab delimited.

[oracle@server logs]$ awk '{print $1}' /opt/application.log
2013/08/07...
1,602
Posted By ryandegreat25
looks like while loop is much efficient in this...
looks like while loop is much efficient in this case. im actually learning awk so im figuring out how to do this via awk but i guess i should stick to while loop in this case then. thanks ;)
...
976
Posted By ryandegreat25
ill try your suggestion. thanks!
ill try your suggestion. thanks!
1,602
Posted By ryandegreat25
thanks for the suggestion, yeah thought so, is...
thanks for the suggestion, yeah thought so, is there an alternative using all using awk? i forgot to mention that the column exceeds $9 it reaches around 19 columns

i can get the column using...
1,602
Posted By ryandegreat25
Another method for this snippet
Hi All, i believe this is not very efficient. another method would be appreciated for these. basically i read a file with tab delimited column and pass the column to another perl script.

while...
976
Posted By ryandegreat25
thanks. modification time is a good indication of...
thanks. modification time is a good indication of something was updated. but i need to fetch the new entries and process it which stat cannot do.
976
Posted By ryandegreat25
Detecting new entries in log files
Hello All,

I have a script that checks a log file. This will be checked periodically lets say every 5 minutes. I need to get new entries and process these new entries

What do you think is the...
1,387
Posted By ryandegreat25
thanks for another suggestions :)
thanks for another suggestions :)
1,387
Posted By ryandegreat25
yes exactly, i need to convert the log to another...
yes exactly, i need to convert the log to another format. the reason i did not paste the output here is because i dont know yet.
but what you have provided is working so i guess i can expand from...
1,387
Posted By ryandegreat25
thanks. yes your right i might not need to assign...
thanks. yes your right i might not need to assign it to any variables.
the date=$(echo $line | awk -F"\t" '{print $1}') is really inefficient and what i am trying to avoid. you see if i have 50K...
1,387
Posted By ryandegreat25
thanks for this. would you mind sharing the awk...
thanks for this. would you mind sharing the awk structure as well.
i would like to have something like this written in awk.

while read line
do
date=`echo $line | awk -F"\t" '{print $1}'`...
1,387
Posted By ryandegreat25
awk Scripting
Hey guys,

I want to get all the columns in this input file tab-delimited, i need to get the column send them to a variable. From there i could print them in shuffle and pick and select columns i...
922
Posted By ryandegreat25
if i understand your requirement correctly, you...
if i understand your requirement correctly, you want to search for a line with matching pattern and append something. you can try this

im just appending string 'matched' to the end of the line.
...
1,105
Posted By ryandegreat25
i dont get it what you are trying to achieve....
i dont get it what you are trying to achieve. what is the expected output?

[oracle@server ~]$ cat infile3
"","","","","","","","",""
"","","","","","","","",""
"","","","","","","","",""...
664
Posted By ryandegreat25
cut will treat every space delimiter as separate...
cut will treat every space delimiter as separate column. so eliminating the spaces and aligning the output will be good with cut. awk will be able to handle task like this easily.
1,696
Posted By ryandegreat25
please post the output of what you are trying to...
please post the output of what you are trying to accomplish
1,696
Posted By ryandegreat25
one thing i like is use of cat and echo ...
one thing i like is use of cat and echo
-bash-3.2$ cat test
a
b
c
-bash-3.2$ echo `cat test`
a b c
-bash-3.2$ echo $(cat test)
a b c
-bash-3.2$
1,812
Posted By ryandegreat25
you seem to have a bit of knowledge on what you...
you seem to have a bit of knowledge on what you are trying to accomplish and how to do it, how about passwordless ssh login?
7,882
Posted By ryandegreat25
Not sure if this is the best way to do this :)...
Not sure if this is the best way to do this :) you might want to create a script inside a script.

if successful, pkill wont be able to kill any which will result to exit code 1 else it will be 0
...
Showing results 1 to 25 of 284

 

Featured Tech Videos

All times are GMT -4. The time now is 02:55 PM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy