Hi guys I'm very new to unix and I have to create an awk script that detects webpage addresses from a file/webpage and outputs how many times each webpage was detected.e.g. if my file was:
(Note: The symbol " was added to stop them being created into links)
Hi All,
I want to detect each new file coming / getting created in unix directory.
When every new file came to directory, i have to get its details like its size , date and time stamp and store it into another file.
Could any one please tell me , how i can achieve that?
Thanks. (13 Replies)
I have a script which must not be run more than once at any given time. THis script will be scheduled to run every 20 mins as a cron job.
In my script can i have logic to say if this script is already running from the previous cron, then exit.
How do i go about doing that. If you describe the... (11 Replies)
Hi guys I'm very new to unix and I have to create an awk script that detects webpage addresses from a file/webpage and outputs how many times each webpage was detected.e.g. if my file was:
www.google.com
www.facebook.com
www.google.com
the output should be:
www.google.com x2... (2 Replies)
There is a same named log file that I have on my 2 different android phones. When I plug it into my computer, it appears in the media folder, For example the first android phone:
/media/F6BA-0AF5/folder/A.log
I want to put that into a variable to be manipulated.... (3 Replies)
Hi All,
I am newbie here and request your assistance.
I have a service running on public ip, but since I have a dynamic IP it keeps on changing and every time I need to manually get the new ip and add to the config file and restart the service. This has become bit time consuming.
Hence, I... (4 Replies)
Hi ! programmers
I have a need of detecting empty field in file
my file looks like this
40.900|-71.600|1.6|20|1|1961|21.00|3.700||1|US|28035|10029370|31
40.900|-71.600|5.7|20|1|1961|21.00|3.700||1|US|28035|10029370|31
40.900|-71.600|7.8|20|1|1961|21.00|3.700||1|US|28035|10029370|31... (7 Replies)
Hi all,
I am needing some help with a script that will search for a video file by known extensions and then do a pattern search (I'm guessing via regex) and then based on a match of one type of another move the file to an assigned directory.
I would like to do this with either a shell script... (7 Replies)
I have 10 scripts which use awk/nawk extensively.
I have to always change awk to nawk and nawk to awk when i deploy all my scripts to different types of servers as some support nawk while other support awk.
Can you propose a solution that without having to tweak my 10 scripts at several... (8 Replies)
Hello, can someone guide me on this?
I don't know what is the best approach, (awk script, shell script)
I am using RedHat Linux version 6.5. There is a third party application deployed on that server. This app by default generates 5 log files and each file is 20MB. These log rollover... (5 Replies)
Hello,
I have a small script and it runs from web application in below format:
pipe:///path_to_myscript.sh url1 url2 url3
myscript.sh:
#!/bin/bash
count=0
while
do
count=$((count+1))
exec 3>&1
((ffmpeg -i $1 ...... -f mpegts pipe:1 2>/dev/null 1>&3 ) 2>&1 | \
while read LINE; do echo... (9 Replies)
Discussion started by: baris35
9 Replies
LEARN ABOUT REDHAT
mrtg-rrd
MRTG-RRD(1) mrtg MRTG-RRD(1)NAME
mrtg-rrd - How to use RRDtool with MRTG
SYNOPSIS
After using MRTG for some time you may find some limitations. Mostly in the areas of performance and graphing flexibility. These are
exactly the areas addressed by rrdtool. To learn more about RRDtool check out its website on
http://people.ee.ethz.ch/~oetiker/webtools/rrdtool
RRDTOOL INTEGRATION
When using mrtg with RRDtool you are replacing rateup with the RRDtool perl module RRDs.pm. To enable RRDtool support in mrtg you have to
add the line
LogFormat: rrdtool
MRTG needs access to both the RRDtool perl module RRDs.pm and to the rrdtool executable.
If these two items are not installed in locations where perl can find them on its own, then you can use the following two parameters to
supply the appropriate directories.
For the location of the rrdtool executable you put
PathAdd: /usr/local/rrdtool/bin/
or
PathAdd: c:
rdtoolin
For the location of the perl module it would be:
LibAdd: /usr/local/rrdtool/lib/perl/
or
LibAdd: c:
rdtoolinlibperl
When you have made this modification to the configuration file, several things will happen when you run mrtg again with the new config
file:
1. mrtg will take all your old ".log" files and convert them to ".rrd" format. (The ".log" files don't get touched in the process, so if
things don't work out they are still there.)
2. mrtg will use rrdtool to update its databases. These will have a new format called rrd which is totally different than the native log
format of the classic mrtg.
3. mrtg will not create any webpages of graphs anymore. It will only query the routers for traffic information and update its rrd data-
bases.
The advantage of whole thing is that the mrtg will become much faster. Expect the runtime to drop to 20% of the previous value. (I would
like to get some feedback on this from folks with large installations)
Mind you though, while the logging process of RRDtool is very fast, you are also gaining some time by neither creating graphs nor updating
webpages. The idea behind this is that it is more efficient to create graphs and webpages on demmand. Using a cgi script.
At the moment there is no official script to do this, but two contributers have created such scripts:
14all.cgi
Was the first program to take over the webpage creation and graphing task. It has been developed by Rainer Bawidamann <Rainer.Baw-
idamann@informatik.uni-ulm.de>. You can find a copy on Rainers website:
http://www.uni-ulm.de/~rbawidam/mrtg-rrd/
The program comes with its own documentation
routers.cgi, servers.cgi and generic.cgi
are other cgi frontends to mrtg running with rrdtool. Thier main difference to 14all is, that the web pages it creates are much more
stylish than the ones from mrtg. These tools have been written by Steve Shipway <steve.shipway@adsweu.com>. You can find a copy in
http://www.cheshire.demon.co.uk/pub/
The scripts comes with their own installation instructions.
FUTURE
Just as a side note: MRTG-3 will be based entirely on rrdtool technology. But don't wait for it ... get going now!
AUTHOR
Tobias Oetiker <oetiker@ee.ethz.ch>
3rd Berkeley Distribution 2.9.17 MRTG-RRD(1)