Search Results

Search: Posts Made By: rk4k
3,116
Posted By rk4k
Let me try to help with my limited knowledge :D ...
Let me try to help with my limited knowledge :D

grep -B1 No log_file | grep -A2 CLIENT | tail -n1
Try that. Hope it helps.
Regards
3,408
Posted By rk4k
:eek: Wow. Yes , exactly solve the problem. I...
:eek: Wow. Yes , exactly solve the problem.
I know awk , but this is new to me .

Thank you .
3,408
Posted By rk4k
Overwrite specific column in xml file with the specific column from adjacent line
I have an xml file dumped from rrd file, that I want to "patch" so the xml file doesn't contain any blank hole in the resulting graph of the rrd file.

Here is the file.

...
3,632
Posted By rk4k
Hello all, I've found Don's code much more...
Hello all,

I've found Don's code much more responsive to sort the csv files.
Sorry for the heading and last lines in my first request. It's not mandatory, all I need is the csv results.

Thanks...
3,632
Posted By rk4k
Merge CSV files
I have lot of csv file collected from script like below :

Name of files (some examples) there are thousands of it:

192.168.0.123_251_18796_1433144473.csv
192.168.0.123_251_18796_1433144772.csv...
3,118
Posted By rk4k
I suggest you to save the file in .csv format...
I suggest you to save the file in .csv format first. And all the rest I think you can figure it out :)
11,627
Posted By rk4k
With this code : awk...
With this code :

awk '{printf("%s,%12.4f,%12.4f\n",strftime("%c",$1),$2,$3) } 'I̶ ̶h̶a̶v̶e̶ ̶s̶p̶a̶c̶e̶ ̶i̶n̶ ̶a̶t̶ ̶t̶h̶e̶ ̶t̶h̶i̶r̶d̶ ̶f̶i̶e̶l̶d̶,̶ ̶n̶o̶t̶ ̶a̶ ̶b̶i̶g̶ ̶p̶r̶o̶b̶l̶e̶m̶. Ummm I...
11,627
Posted By rk4k
Combining awk printf and print strftime command
I have a lines like below, captured from rrdtool fetch command,

1395295200 2.0629986254e+06 7.4634784967e+05
1395297000 2.0198121616e+06 6.8658888903e+05
1395298800 1.8787141122e+06...
17,175
Posted By rk4k
Wrong solution sorry :o
Wrong solution sorry :o
2,888
Posted By rk4k
Thank you pludi / Franklin52. Respect :b:
Thank you pludi / Franklin52.

Respect :b:
2,888
Posted By rk4k
Wiki conversion with Awk or Sed
I have the words in twiki format that I want to convert to mediawiki format like below :


%BLUE%some words1%ENDCOLOR%

bla bla blab labdad sdadasd adsasdads oerdkfj kdfjs %PINK%some wordks2...
8,900
Posted By rk4k
just parsed it to another file with > or you...
just parsed it to another file with >

or you can use -i parameter in sed

sed -i 's/ABC/TMP/g;s/XYZ/ABC/g;' input_file | sed -i 's/TMP/XYZ/g' input_file:D
4,467
Posted By rk4k
why not ? cut -f1 -d' ' | cut -f2-40 -d'/' ...
why not ?

cut -f1 -d' ' | cut -f2-40 -d'/'

just increase 40 if the dirname have so many char. :D:D
2,178
Posted By rk4k
Wow .. great :eek: :D yeah sed and perl is...
Wow .. great :eek: :D
yeah sed and perl is great too. :b:

Thks Ahmad.Diab / Radoulov
2,178
Posted By rk4k
Another AWK question
Helo Experts

I have bunch of lines like below :

I'd like to convert every "non zero-like digit" so it multiplied by 8. The results should be like :


I know awk can solve this , but I'm just...
5,069
Posted By rk4k
hi folks sorry for late respons I...
hi folks


sorry for late respons

I try ghostdog74 and colemar solutions .. both working great
The only problems that the two subtitles file is different at the end .. until that position...
5,069
Posted By rk4k
Replacing lines between two files with awk
Hello Masters,

I have two subtitles file with different language like below

First file :

1
00:00:41,136 --> 00:00:43,900
[<i># Underdog theme</i>]

2
00:00:55,383 --> 00:00:58,477...
14,244
Posted By rk4k
great , I knew it should be easy. :b: ...
great ,

I knew it should be easy. :b:
Keep learning
14,244
Posted By rk4k
cat sortfile 12345 0001 090112 14385 0001...
cat sortfile

12345 0001 090112
14385 0001 090112
13255 0001 090112
11345 0001 090112

sort sortfile

11345 0001 090112
12345 0001 090112
13255 0001 090112
14385 0001 090112Is that what...
1,736
Posted By rk4k
If the id_list and master_list have the field = 1...
If the id_list and master_list have the field = 1 at the beggining of the line (always first field of each line).
the script should be :


cat id_list | while read line ; do grep ^$line...
1,736
Posted By rk4k
How about this ? cat id_list | while read...
How about this ?


cat id_list | while read line ; do grep $line master_list ; done
CMIIW, YMMV

HTH :D
16,906
Posted By rk4k
Thanks for both answer. The gawk solution is...
Thanks for both answer.

The gawk solution is cool
16,906
Posted By rk4k
Convert Epoch time format to normal date time format in the same file
I have a file named "suspected" with series of line like these :


{'protocol': 17, 'service': 'BitTorrent KRPC', 'server': '219.78.120.166', 'client_port': 52044, 'client': '10.64.68.44',...
4,904
Posted By rk4k
In linux you can do print file in reverse called...
In linux you can do print file in reverse called tac ( cat in reverse mode ) :)).
No need to sed .. :D
Don't know about the other unices .
Showing results 1 to 24 of 24

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