General :: Specific Range Of Records?

Feb 24, 2010

I am having a log file where there is some discontinuous of dates are there but if i go for range of date to find the records, if is some date is missing the result is displaying full file list( Start date to end of file ) How could i restrict the result upto the mentioned date range.

Code:
$cat sample.log
Jan 03 -error yyyy-1234

[code]...

View 6 Replies


ADVERTISEMENT

General :: Expressing A Specific Range With Regex And Perl Extractors?

Feb 27, 2010

I am tryng to get values BBA 204- BBA 324 from a log file.

this is my script:

zmore log.gz | perl -nle 'print for m/BBAs[2|3][0-9][0-4]/g' | sort -u | perl -ne 'print if /^BBAs204$/../^BBAs324$/'

the first perl one liner gives me everything from BBA 200 to BBA 394, and the second perl one liner cuts it down to BBA 204 to BBA 324

Is there a elegant regex that will allow me to skip the second perl one liner and just take out the BBA 204 - BBA 324

View 2 Replies View Related

Programming :: Delete A Specific Range Of Files?

Aug 13, 2010

I have 50 files in the following format.

fileone.0001.txt
filetwo.0002.txt
filethree.0003.txt

[code]...

View 4 Replies View Related

General :: Combining Records With Same Key?

Apr 4, 2010

Input file (already sorted on the key field):

204 Daniel Barton
206 Mary Halston
206 David Coleman
206 Carson Coleman
207 Roland Highsmith
207 Annie Highsmith
209 Connie Ward

Desired output file:

204 Daniel Barton
206 Mary Halston David Coleman Carson Coleman
207 Roland Highsmith Annie Highsmith
209 Connie Ward

View 1 Replies View Related

Networking :: What Are Short Range Link And Long Range Links In Routing

Jun 23, 2009

get me understand the short range and the long range links from routing (and routing protocols') point of view.

View 6 Replies View Related

Software :: Gnuplot - Combining A Linear Range And Log-scale Range In The Same X-axis?

Apr 24, 2011

I want to plot a set of data in only one plot.The problem is that some points of the data should be better plotted in a linear scale (lets say 0 to 100,000) but there are other data points that, exceding the value 100,000, would be better plotted in a logarithmic scale, as they goes in the range 100,000 to 500,000,000. Let's say the data is:

Code:

X Y
0 100
10000 80
20000 75

[code]....

Is there a way to plot all these points in the same plot in only one X-axis showing two different ranges in that axis: linear: 0-100,000 logarithmic: 100,000 - 1,000,000,000?The axis would be read, for example, as:

Code:
|-----|-----|-----|-----|-----|-----|-----|-----|-----|
0 20k 40k 60k 80k 100k 1M 10M 100M 1G

(The abbreviations k-M-G are not the important point. Just shown for clarity)

View 2 Replies View Related

General :: Change A Specific Characters To Capital In A Specific Text?

Dec 2, 2010

for example

else {
for fileDOC in $location/*.doc
do

[code]...

View 12 Replies View Related

General :: Query The Sdp Records On Local PC?

Sep 2, 2010

I'm using Net::Bluetooth to create an RFCOMM socket on my Linux box. I need for it to register with SDP with a specific UUID. The perl code can be viewed in this link. I am unable to make the connection from a remote device however. This remote device (my Android phone) is able to connect to other RFCOMM devices using this UUID. I would like to troubleshoot the problem, but I can't find a way to browse the LOCAL SDP records of my PC where the Perl script is running (and waiting for incoming BT connections). how to browse the SDP records on the local PC?

View 1 Replies View Related

General :: Awstat Is Dropping All Records?

Mar 10, 2011

I am using awstat for a website. It's working fine. On the webserver I made a new virtual host for the same website with some addition in URL. I made a separate log file for this URL and tried to process it also in awstat but for it's log file awstat is dropping all records.

On webserver log format is same for both logs files. On awstat the config file is same for both logs except the log path line of course .Why awstat isn't able to process the same log format with the same config file what is working for the previous logs

View 5 Replies View Related

Programming :: Bash Script To Ping A Range Or Own IP-range?

Apr 11, 2011

I want to build a bash script, which can ping a range IP adresses which will be filled in by the admin. If there is no IP-adress filled in, then the script must ping the subnet where the system is logged on. So if my ip is 192.168.1.6, then the script must ping from 192.168.1.1 till 192.168.1.255 Or else, if there is given a beginning and ending ip it must ping that!

The first part of the bash script is to ping a given range (see below). But there is one problem, how can I tell the script to ping from $begin till $end, [..] is of course wrong! But what must be filled in there???

echo "Enter beginning IP-adres:"
read begin
echo "Enter ending IP-adres:"
read end
ping -c 1 $begin [..] $end

The second part is to find my own ip and ping the whole range.. How to do that? I only can find my own IP, but I cant ping the whole range,, how to do that?

#!/bin/bash
ifconfig | grep 'inet addr:' | grep -v '127.0.0.1' |
cut -d: -f2 | awk '{ print $1 }'

View 11 Replies View Related

General :: Delete Old Records From Firefox Sqlite Databases?

May 23, 2010

I have some big sqlite3 databases in ~/.mozilla/firefox/profilename Notably places.sqlite (12 MB) and urlclassifier3.sqlite (33 MB). Is it possible to truncate them and wipe out the oldest records in them? Of course I could just wipe them completely, but that's not my goal - I just want to minimize the size of those files while keeping the newest records.

View 2 Replies View Related

General :: Unable To Find The Values In The Header Records?

May 31, 2011

I have been asked to write a program to extract the width and height values from .gif, .jpg and .png files. For .gif I was able to find the values in the header records, but it is not so straight forward for the other two formats.

Does anyone know if there is a Linux utility that will do this for me?

View 3 Replies View Related

General :: DNS Checking Tool - Check And Compare DNS Records

Dec 14, 2010

there is a tool, which can check and compare DNS records for me. I'd like to tell it to look at our private subnet, and it for to return records which have missing or different DNS records, than were expected. if it just looked up every record and returned it in a "neat" way, that'd work too.

View 5 Replies View Related

General :: Printing Individual Database Records In Form Format?

Oct 9, 2010

I have a database (Mysql) with records of our club members. It is quite small only about 300 records. Unfortunately there are gaps in the information and I would like to be able to print out (two records to an A4 sheet) the records in form format so that I can pass these to the members who will fill in any blanks in the record.

If it is not possible to do what I want from the database I can convert the records to a spreadsheet and do it from there.

View 1 Replies View Related

General :: Unable To Delete Duplicate DNS Records Using Bcupdate Tool

Oct 30, 2010

Unable to delete dupliucate DNS records using bcupdate tool

View 1 Replies View Related

General :: Grep - Manipulating Large Text File Full Of Records

Nov 26, 2010

I'm trying to manipulate a large text file full of records (metadata - one complete record per line). I need to delete every line on which certain words appear - there are five different words, all pretty simple all-caps strings with occasional whitespace. I tried using grep -v, which worked a treat, but only string-by-string. Ideally I'd like to run this as grep -v -f, where the file targeted by the -f contains the strings I need to match in order to delete the lines they're in.

i.e. grep -v -f filecontainingSTRINGS.txt targetfile.txt > outputfile.txt

When I try this, however, I don't get any matches - or more specifically, no changes are made in the output file. It works fine if there's only one string in filecontainingSTRINGS, but it doesn't work if there's more than one (I'm using newline as the delimiter). (Also my machine doesn't recognise /usr/xpg4/bin/grep - no idea what that's all about!)

View 5 Replies View Related

General :: Run A Program For A Specific Amount Of Time Starting At A Specific Time?

May 18, 2010

I want to record an internet radio station starting at 2:00am tomorrow morning. The specific program on the radio station lasts until 6:00am. The command I need to run to record the station is: Code:mplayer http://wjcu.jcu.edu:8001/listen.pls -ao pcm:file=indie_heat_of_the_night.wav -vc dummy -vo nullI'd use cron, but 1. I'm not sure how to and 2. it seems unnecessarily complicated for something that I only want to run once. If cron is the only/easiest solution, I guess I'll just have to resort to that, but I'd rather not.

View 12 Replies View Related

General :: Lost All Boot Entries / Anyway To Recover All Three Boot Records

Mar 30, 2010

I have window 7, Ubuntu and Cent Os installed in my system. I was actually trying to change boots options but unfortunatly i lost all boot entries. Is there anyway i can recover all three boot records.

View 7 Replies View Related

General :: Moniter Out Of Range Error / Fix This?

Jul 30, 2010

I just installed Debian lenny 5.0.5 and when i start it up the monitor just displays a 'out of range' error. im using a Radeon HD 5570 graphics card and a lG W2353V-PF monitor.

what do i have to do to fix this problem?

View 2 Replies View Related

General :: Monitor Resoluti8on - All Out Of Range

Mar 28, 2010

the electric went off and when it come back on my monitor picture was all out of range. I changed the resolution to bring the picture back in and now the words are almost unreadable.

View 1 Replies View Related

General :: Moving Files By Specifying Range

Apr 9, 2010

I'm trying to move files from one directory to another. I only want the files that start with a capital and within a certain range. Say all files that start with a capital between A-K. I've googled this and they all say to use: [A-M]*. But it moves all files A-M regardless if they are uppercase or lowercase.

View 7 Replies View Related

General :: Out Of Range 92.6khz/58hz

Jun 29, 2011

I have just installed UBUNTU 11.04 and found when booting that "out of range " statement came up, after a few moments it completes the boot, but as I have several distros it doesn't open the selection screen.

View 1 Replies View Related

General :: Squid 2.6 : Acl Which Should Apply To Ip Range?

Feb 7, 2011

i have squid 2.6 installed on centos i created acl which should apply to this ip range i.e 192.168.1.10-192.168.1.15 and excluded 192.168.1.13 how can i do

View 14 Replies View Related

General :: Find Any Domain Name That Resolves To IP Within A Given Net Range?

Feb 12, 2010

For example, given the range:172.128.0.0 - 172.191.255.255I need to find some domain that resolves to an IP-adress within the range. Is it possible ? I'm using a Linux system.

View 3 Replies View Related

General :: How To Get Bash Shell History Range

Oct 4, 2010

How can I get/filter history entries in a specific range?I have a large history file and frequently usehistory | grep somecommandNow, my memory is pretty bad and I also want to see what else I did around the time I entered the command.For now I do this:get match, say 4992 somecommand, then I do history | grep 49[0-9][0-9]this is usually good enough, but I would much rather do it more precisely, that is see commands from 4972 to 5012, that is 20 commands before and 20 after. I am wondering if there is an easier way? I suspect, a custom script is in order, but perhaps someone else has done something similar before.

View 2 Replies View Related

General :: Awk Script To Select Range From File?

Nov 25, 2009

I have a file generated in every event occurred. In this file i have a entries like bellow

<without blank line after Summary>

Summary: Adapter at hardware path 0/6/1/0 :Received an interrupt indicating that a
primitive was transmitted

and sometimes like bellow

<with blank line after Summary>

Summary: Adapter at hardware path 0/6/1/0 :Received an interrupt indicating that a primitive was transmitted What I need is to extract the Summary from the file. I have the following awk script. But it only works if there is no blank line after Summary.

cat server.event.txt|awk '/^Sum/,/^$/'

But I need up to second blank lines after Summary.

View 8 Replies View Related

General :: Copy Range Of Files In Directory?

Mar 29, 2010

I want to know how to copy a range of files from one directory to another.

For example say I list the contents of a directory, how would i copy files 5-15 to another directory?

View 3 Replies View Related

General :: Find Files In Date Range?

May 31, 2010

ls -l /tmp/empty_file*
-rw-r--r-- 1 root root 0 2010-05-30 08:00 /tmp/empty_file
-rw-r--r-- 1 root root 0 2010-05-30 12:00 /tmp/empty_file1

This looks good, the files expected to be seen are output: find /usr ( -newer /tmp/empty_file -a ! -newer /tmp/empty_file1 ) -print

But this shows me files that should not be output and likewise when I replace ls with tar it is tarring a whole bunch of stuff I do not want: find /usr ( -newer /tmp/empty_file -a ! -newer /tmp/empty_file1 ) -exec ls -l {} ;

In the end I would like to replace the "ls" with "tar cvvfp some.tar {} ;", but can't figure out what is going wrong here.

View 2 Replies View Related

General :: Search Within A Log File Within A Time Range

Jun 24, 2011

I want to search in my apache log, for events which have occurred say between 11:00 AM to 2:00 PM. I have got few scripts/commands but they are not conclusive, some of then are trying to do an exact match(awk) and for some i am just getting the pattern wrong (eGrep)

I am running RHEL.

Apache log eg:
================================================================
10.92.120.129 - - [24/Jun/2011:01:29:07 -0500] "GET /favicon.ico HTTP/1.1" 302
================================================================

now if i want to find out the logs from 1 PM to 2 PM

some example i had was:

cat <apache.log> | grep -E '07/Apr/20110[1-2]:[0-5][0-9]|02:00)'

small script in which i can pass the start time and end time range, and it should give an output of the rows which fall under that time range.

View 5 Replies View Related

Ubuntu :: Giving A Specific User Permission To Start/stop A Specific Service?

Jun 8, 2010

How do I give permission to a logged in user to stop/start a specific service without entering a root/sudo password? So they can do a simple "service SomeService stop|start" It is for a headless Ubuntu server.

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved