One of the senior administrators gave me a shell script to modify and it begins as follows:
if ] && ]
{more code follows}
Why the double square brackets? (10 Replies)
Hi,
I just came across an interesting shell script syntax like the one below:
] && (trap 'rm -rf ${WORK_DIR}/*.$$; echo "\n\nInterrupted !!\n\n"; exit 4' 1 2 3 15)
Can someone please explain the code snippet above?
The trap command bit is fine but ] && is the hazy part.
Generally we use an... (2 Replies)
Hello,
Can someone please explain to me the following line,
] && break
I do not understand why two test square brackets are used.
Thanks,
Shantanu
---------- Post updated at 03:38 PM ---------- Previous update was at 03:35 PM ----------
And, also why there's a $ before (echo $c |... (5 Replies)
hi guys,
i'm writing a script that looks for a unquie id in a file and replaces a string between two square brackets on the same line as the unquie id:
.......
.......
0001 zz 43242 replace this text] name
0002 sd 65466 UK] country
.......
.......
how can i find line with id 0001... (6 Replies)
Hi All,
I have a text file which looks like this:
computer programming
systems engineering
I want to get rid of these square brackets and also the text that is inside these brackets. So that my final text file looks like this:
computer programming
systems engineering
I am using... (3 Replies)
Hi All,
After searching about this, I could find some solutions but I am not sure why it is not working in my case.
I have a text file with contents between two square brackets. The text file looks like this:
Use tags when you post any code so others can easily read your code. You can... (2 Replies)
I wanted to compare the value inside the Squre bracket after Colon ( : ) based on any value(seperated by or operator | ) inside the variable Thread and if match found then wnated to store in output file
Input file :
20140320 00:08:43.918 INO 35] - Corporate hub is
20140320 00:08:43.918... (2 Replies)
I wanted to store the number inside the square bracket between colon( : ) and closing suqre bracket(]) in some variable.
Suppose I have lines like :
Input file :
20140320 00:08:23.846 INFO 84] - anything in line
20140320 00:08:23.846 Test 589] - Virtual and lab lab anything... (18 Replies)
Hi All,
Hope you all are doing good. Yesterday in my project i came across a scenario which i can not guess why it was working in one region and why it was not in another region. Please find my issue below.
I am using AIX version 6.0 of UNIX in my project, in shell scripting i have the... (1 Reply)
Discussion started by: mad man
1 Replies
LEARN ABOUT SUSE
razor-agents
RAZOR-AGENTS(1) User Contributed Perl Documentation RAZOR-AGENTS(1)NAME
Razor-Agents - Collection of files for checking, reporting, and revoking spam
DESCRIPTION
Vipul's Razor is a distributed, collaborative, spam detection, reporting, and filtering network. The primary focus of the system is to
identify and remove all email spam from the internet. Visit the website at http://razor.sourceforge.net/.
USAGE
First a razorhome directory should be created where log, conf, and cached server information will live. This is done via "-create" option
to razor-admin(1). See man page for details.
You can immediately check spam using razor-check(1). See man page for details.
To report spam, an identity must be registered. This is done via "-register" option to razor-admin(1). After that, razor-report(1) and
razor-revoke(1) will work flawlessly.
CONFIGURATION
All Razor-Agents share a configuration file. The contents of the configuration file are detailed in the razor-agent.conf(5) manpage.
Config file is computed before razorhome, in the following order:
-conf=/path/file.conf used if readable, else
<home>/.razor/razor-agent.conf used if readable, else
/etc/razor/razor-agent.conf used if readable, else
all defaults are used.
To see configuration defaults, do
razor-admin -create -conf=/tmp/razor2-defaults.conf
RAZORHOME
All Razor-Agents also share a razorhome directory, where identity, logging, and cached information about servers is stored. Razorhome is
computed after configuration file, in the following order.
-home=/tmp/razor/ used if readable, else
'razorhome' from configuration file used if readable, else
<home>/.razor/ used if readable, else
<home>/.razor/ is created. if that fails,
no razorhome.
NOTE: If there is no razorhome, razor-report and razor-revoke will
not work unless you specify -ident=/path/identity
razor-check will still work.
FILES
Besides those listed at the end with their own manpages, Razor Agents also has the following files.
razorhome/identity
Usually a symlink to identity file containing user+pass. Used by razor-report(1) and razor-revoke(1).
razorhome/razor-agent.log
Default log file. To change, edit razor-agent.conf(5).
razorhome/servers.*.lst
Cached list of Razor Servers. If more than one, they are ordered by closest ping time.
razorhome/server.<name>.lst
Cached info for <name> server. The "srl" key in this file is compared against the server greeting, and if server's is greater, new
cache info is retrieved from the server.
EXAMPLES
razor-check -d -debuglevel=9 mbox
Checks spam in mbox. prints numbers for those found to be spam. -d logs to stdout, -debuglevel=9 is verbose logging
razor-admin -create -home=/home/chad/.razor -d -s
Creates razorhome in /home/chad/.razor, log to stdout, does not connect to server (-s simulate).
razor-report spam -debuglevel=0
sends spam to server, with no log msgs.
AUTHORS
Vipul Ved Prakash, <mail@vipul.net> and Chad Norwood <chad@samo.org>
SEE ALSO razor-agent.conf(5), razor-check(1), razor-admin(1), razor-report(1), razor-revoke(1), razor-whitelist(5)perl v5.12.1 2004-12-03 RAZOR-AGENTS(1)