Re: Script help using "cut"

2005-08-24 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: 
Sent: Wednesday, August 24, 2005 11:52 AM
Subject: Re: Script help using "cut"


> On 2005-08-24 11:41, antenneX <[EMAIL PROTECTED]> wrote:
> >Giorgos Keramidas <[EMAIL PROTECTED]> wrote:
> >> sed -e 's/)[[:space:]]*$//' -e 's/^.*@//'
> >>
> >> or you can use as complex regular expressions as necessary to cut
> >> specific parts of the line:
> >>
> >> sed -e 's/[EMAIL PROTECTED]([^)]*\))[[:space:]]*$/\1/'
> >
> > In fact, my very next script line uses sed(1) to add the TAB and
the
> > RHS to the sendmail access file:
> > sed 's/$/   REJECT/g' tmpfile >> /etc/mail/access
> >
> > I'll bet my line could be incorporated with yours.
>
> Sure.  It's probably also a good idea to use mv(1) with a temporary
file
> residing under /etc/mail too, to make sure the update to the access
map
> is as close to being an ``atomic operation'' as possible:
>
> % accesstmp=`mktemp /etc/mail/access.tmp.XX`
> % if [ -z "${accesstmp}" ]; then
> % exit 1
> % fi
> %
> % ( cat /etc/mail/access ;
> %   awk '{whatever else here}' tmpfile | \
> %   sed -e 's/[EMAIL PROTECTED]([^)]*\))[[:space:]]*$/\1 REJECT/' ) >
"${accesstmp}"
> % if [ $? -ne 0 ]; then
> % exit 1
> % fi
> % mv "${accesstmp}" /etc/mail/access
> % cd /etc/mail && make access.db
>

Giorgos, that's pretty snazzy compared to my crude script. Will now
work on weaving it all together. Eliminates a bit more manual effort.

I like it & appreciate the extra help!

Best regards,
Jack L. Stone

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Script help using "cut"

2005-08-24 Thread antenneX

- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: 
Sent: Wednesday, August 24, 2005 8:04 AM
Subject: Re: Script help using "cut"


> On 2005-08-24 07:58, antenneX <[EMAIL PROTECTED]> wrote:
> >"antenneX" <[EMAIL PROTECTED]> wrote:
> >>"Giorgos Keramidas" <[EMAIL PROTECTED]> wrote:
> >>>> (envelope-from [EMAIL PROTECTED])
> >>>> (envelope-from [EMAIL PROTECTED])
> >>>> (envelope-from [EMAIL PROTECTED])
> >>>>
> >>>> All ideas appreciated
> >>>
> >>> $ awk '{print $2}' tmpfile | sed -e 's/)[[:space:]]*$//' | sort
| uniq
> >
> > Just woke up this morning and realized I needed to chop off
more --
> > everything except the domain.
> >
> > So, instead of [EMAIL PROTECTED] I need the result badguy.com
> >
> > How could the above awk line be expanded to chop off the username@
> > portion as well?
>
> sed(1) can do more than one substitutions in one line:
>
> sed -e 's/)[[:space:]]*$//' -e 's/^.*@//'
>
> or you can use as complex regular expressions as necessary to cut
> specific parts of the line:
>
> sed -e 's/[EMAIL PROTECTED]([^)]*\))[[:space:]]*$/\1/'
>

In fact, my very next script line uses sed(1) to add the TAB and the
RHS to the sendmail access file:
sed 's/$/   REJECT/g' tmpfile >> /etc/mail/access

I'll bet my line could be incorporated with yours.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Script help using "cut"

2005-08-24 Thread antenneX
- Original Message - 
From: "antenneX" <[EMAIL PROTECTED]>
To: "Giorgos Keramidas" <[EMAIL PROTECTED]>
Cc: 
Sent: Tuesday, August 23, 2005 8:35 PM
Subject: Re: Script help using "cut"


> - Original Message - 
> From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
> To: "antenneX" <[EMAIL PROTECTED]>
> Cc: 
> Sent: Tuesday, August 23, 2005 8:16 PM
> Subject: Re: Script help using "cut"
>
>
> > On 2005-08-23 20:02, antenneX <[EMAIL PROTECTED]> wrote:
> > > Been trying to complete a script that I can use to grep spam
> emails
> > > from the maillog, then trim it to just the plain email address.
> Trying
> > > to use "cut" in the script but it's not doing what I want yet.
> > >
> > > Here is what the earlier lines have the lines down to so far:
> > > "(envelope-from [EMAIL PROTECTED])"  -- no quotes
> > > ...and I want this "clean" trimmed result after trim using "cut"
> or
> > > anything else that works to trim/cut:
> > >
> > > [EMAIL PROTECTED]  <--- no underlines of course
> > >
> > > That's a TAB space at beginning of the line.
> > >
> > > The "envelope" lines are in a tmp file in colum format (one line
> below
> > > the other).
> > > (envelope-from [EMAIL PROTECTED])
> > > (envelope-from [EMAIL PROTECTED])
> > > (envelope-from [EMAIL PROTECTED])
> > >
> > > All ideas appreciated
> >
> > Does it have to be cut(1)?
> >
> > $ awk '{print $2}' tmpfile | sed -e 's/)[[:space:]]*$//' | sort |
> uniq
> >
>

Just woke up this morning and realized I needed to chop off more -- 
everything except the domain.

So, instead of [EMAIL PROTECTED] I need the result badguy.com

How could the above awk line be expanded to chop off the username@
portion as well?

Sorry, must have been really tired.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Script help using "cut"

2005-08-23 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: 
Sent: Tuesday, August 23, 2005 8:16 PM
Subject: Re: Script help using "cut"


> On 2005-08-23 20:02, antenneX <[EMAIL PROTECTED]> wrote:
> > Been trying to complete a script that I can use to grep spam
emails
> > from the maillog, then trim it to just the plain email address.
Trying
> > to use "cut" in the script but it's not doing what I want yet.
> >
> > Here is what the earlier lines have the lines down to so far:
> > "(envelope-from [EMAIL PROTECTED])"  -- no quotes
> > ...and I want this "clean" trimmed result after trim using "cut"
or
> > anything else that works to trim/cut:
> >
> > [EMAIL PROTECTED]  <--- no underlines of course
> >
> > That's a TAB space at beginning of the line.
> >
> > The "envelope" lines are in a tmp file in colum format (one line
below
> > the other).
> > (envelope-from [EMAIL PROTECTED])
> > (envelope-from [EMAIL PROTECTED])
> > (envelope-from [EMAIL PROTECTED])
> >
> > All ideas appreciated
>
> Does it have to be cut(1)?
>
> $ awk '{print $2}' tmpfile | sed -e 's/)[[:space:]]*$//' | sort |
uniq
>

Yep! That looks good!

Many thanks again for the tip.

Best regards,
Jack L. Stone

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Script help using "cut"

2005-08-23 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: 
Sent: Tuesday, August 23, 2005 8:16 PM
Subject: Re: Script help using "cut"


> On 2005-08-23 20:02, antenneX <[EMAIL PROTECTED]> wrote:
> > Been trying to complete a script that I can use to grep spam
emails
> > from the maillog, then trim it to just the plain email address.
Trying
> > to use "cut" in the script but it's not doing what I want yet.
> >
> > Here is what the earlier lines have the lines down to so far:
> > "(envelope-from [EMAIL PROTECTED])"  -- no quotes
> > ...and I want this "clean" trimmed result after trim using "cut"
or
> > anything else that works to trim/cut:
> >
> > [EMAIL PROTECTED]  <--- no underlines of course
> >
> > That's a TAB space at beginning of the line.
> >
> > The "envelope" lines are in a tmp file in colum format (one line
below
> > the other).
> > (envelope-from [EMAIL PROTECTED])
> > (envelope-from [EMAIL PROTECTED])
> > (envelope-from [EMAIL PROTECTED])
> >
> > All ideas appreciated
>
> Does it have to be cut(1)?
>
> $ awk '{print $2}' tmpfile | sed -e 's/)[[:space:]]*$//' | sort |
uniq
>

No, it doesn't have to be "cut."
I'll give this a try...
Thanks and,
Best regards,

Jack L. Stone

> ___
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Script help using "cut"

2005-08-23 Thread antenneX
Been trying to complete a script that I can use to grep spam emails
from the maillog, then trim it to just the plain email address. Trying
to use "cut" in the script but it's not doing what I want yet.

Here is what the earlier lines have the lines down to so far:
"(envelope-from [EMAIL PROTECTED])"  -- no quotes
...and I want this "clean" trimmed result after trim using "cut" or
anything else that works to trim/cut:

[EMAIL PROTECTED]  <--- no underlines of course

That's a TAB space at beginning of the line.

The "envelope" lines are in a tmp file in colum format (one line below
the other).
(envelope-from [EMAIL PROTECTED])
(envelope-from [EMAIL PROTECTED])
(envelope-from [EMAIL PROTECTED])

All ideas appreciated

Best regards,

Jack L. Stone

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: question about mksnap_ffs and NFS interaction

2005-05-02 Thread antenneX
- Original Message - 
From: <[EMAIL PROTECTED]>
To: 
Sent: Sunday, May 01, 2005 9:07 AM
Subject: Re: question about mksnap_ffs and NFS interaction


>>> >
>>>
>>> Glad to see a question on this subject and my reply is just more
>>> questions rather than an answer.
>>>
>>> I've just moved to 5.4RC3 & read most of the docs and this snap
issue is
>>> new to me too. Howe are you scheduling? I noticed I never got a
snapshot
>>> until I ran the command to do snaps on each FS. So, I scheduled one
for
>>> "noon" as a cron job. Now I get a regular "snap" plus the "nooner",
but
>>> they show a random time & both done about the same time.
>>>
>>> A mystery to me so far... sure like the new snap feature though.
>>>
>
Hello, boys!
So as you are speaking for those thing called "snashot" i will beg you
to share
some experience about it.
How do you find it works, have you made rebuild of the system from a
snanshot...
and so..
Thanks
---

No rebuild yet, but have mounted to see how easy it is to retrieve
files. Since I run run rebootable clones of my main HD to a 2nd HD every
2-3 days anyway, this daily snapshot just gives me more frequent
backups. Mounting and using the clones is a similar approach. Of course
my clones includes every filesystem as well as those snapshots. The FFS
is really fast too. I like it and restoring is next on my list once I
fully understand the nuances.


-

Не правете това в дома или офиса!

виж
http://www.gsmreview.com/kip.html

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: question about mksnap_ffs and NFS interaction

2005-05-01 Thread antenneX
- Original Message - 
From: "Alan Horn" <[EMAIL PROTECTED]>
To: 
Sent: Sunday, May 01, 2005 5:44 AM
Subject: question about mksnap_ffs and NFS interaction


>
> Folks,
>
> I have some NFS exported filesystems (home directories) that I'm
placing
> under snapshots.
>
> Timing of making a snapshot on a 140GB filesystems running about 90%
full
> takes about 17 seconds.
>
> Given that these filesystems are fairly heavily used homedir
filesystems,
> what is the expected impact of those 17 seconds on NFS clients.
>
> My guess is that its enough to be seen but not enough to cause NFS
> timeouts. So far I've been scheduling snapshots for the middle of the
> night, but I'd like to start doing four per day. Does anyone have any
data
> on the likely impact ?
>
> Please reply direct to me as I'm not subbsed to the list.
>
> Cheers,
>
> Al
>

Glad to see a question on this subject and my reply is just more
questions rather than an answer.

I've just moved to 5.4RC3 & read most of the docs and this snap issue is
new to me too. Howe are you scheduling? I noticed I never got a snapshot
until I ran the command to do snaps on each FS. So, I scheduled one for
"noon" as a cron job. Now I get a regular "snap" plus the "nooner", but
they show a random time & both done about the same time.

A mystery to me so far... sure like the new snap feature though.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Tranferring crontab files from user to user

2005-03-07 Thread antenneX
This should work:
Copy the crontab into a file (like mycron)in your $home.
Issue command: crontab mycron
Check it with command: crontab -l

Best regards,

Jack L. Stone
- Original Message - 
From: "ikenna ononogbu" <[EMAIL PROTECTED]>
To: 
Sent: Monday, March 07, 2005 7:17 AM
Subject: Tranferring crontab files from user to user


>
>I recently resumed work in a firm and the crontab jobs (using UNIX
D2)
>are in the user name of my predecessor. The files have now been
>transferred to a general directory (everyone has access to). How do
I
>now transfer the crontab executable files into my own directory?
>
>I will appreciate someones help.
>
>
>Ike.
>
>
>
>
> ___
> freebsd-questions@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: An AWK question

2005-02-04 Thread antenneX
- Original Message - 
From: "Steven Friedrich" <[EMAIL PROTECTED]>
To: ; "antenneX" <[EMAIL PROTECTED]>
Sent: Friday, February 04, 2005 2:23 PM
Subject: Re: An AWK question


> On Friday 04 February 2005 02:14 pm, antenneX wrote:
> > ---> FBSD-4.10p2
> >
> > I have a script that tells me when a mailbox exceeds 2MB. Using it
for
> > another purpose. how can I modify this script to tell me when a file
is
> > LESS than a certain size?
> >
> > -
> > #!/bin/sh
> >
> > #AWK=/usr/bin/awk
> > #FILE=/file/size/to/check
> > #LS=/bin/ls
> > #SIZE=2048 # (2048 = 2MB)
> >
> > #if [ `${LS} -s ${FILE} | ${AWK} '{ print $1 }'` -gt ${SIZE} ]; then
> > #echo File ${FILE} is ABOVE normal | mail -s "Alert: Check the
file"
> > #fi
> > -
> >
> > Thanks, and
> >
> > Best regards,
> >
> > Jack L. Stone
> >
> > ___
> > freebsd-questions@freebsd.org mailing list
> > http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> > To unsubscribe, send any mail to
> > "[EMAIL PROTECTED]"
> Jonathen's correct. It's not an awk question. It's actually being
evaluated by
> test. see man test )test is also invoked when you see [ some
equation ] (you
> need the space at least on the inside of [ and ], perhaps on the
outsides
> too.
> #if [ `${LS} -s ${FILE} | ${AWK} '{ print $1 }'` -lt ${SIZE} ]; then
> #echo File ${FILE} is BELOW normal | mail -s "Alert: Check the
file"
> #fi
>
> awk is just being used to get the first field from ls -s, which is the
size...
> -- 

No wonder I couldn't make sense out of it looking only in man GAWK(1).

Now, it's very simple -- thanks a lot!

Jack

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


An AWK question

2005-02-04 Thread antenneX
---> FBSD-4.10p2

I have a script that tells me when a mailbox exceeds 2MB. Using it for
another purpose. how can I modify this script to tell me when a file is
LESS than a certain size?

-
#!/bin/sh

#AWK=/usr/bin/awk
#FILE=/file/size/to/check
#LS=/bin/ls
#SIZE=2048 # (2048 = 2MB)

#if [ `${LS} -s ${FILE} | ${AWK} '{ print $1 }'` -gt ${SIZE} ]; then
#echo File ${FILE} is ABOVE normal | mail -s "Alert: Check the file"
#fi
-

Thanks, and

Best regards,

Jack L. Stone

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: having 1.5GB RAM I cannot allocate more than 512MB RAM in 4.10

2005-01-29 Thread antenneX

- Original Message - 
From: "Matthias Buelow" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: 
Sent: Saturday, January 29, 2005 7:01 AM
Subject: Re: having 1.5GB RAM I cannot allocate more than 512MB RAM in
4.10


> [EMAIL PROTECTED] wrote:
>
> > I have an AMD Athlon-XP with 1.5GB RAM.
> > Unfortunately my FreeBSD 4.10 throws a memory allocation
> > error when in a simple C++ program I try to allocate
> > with new 512MB of RAM or more. Until 511MB it goes fine!
>
> what's the output of ulimit -d?

What's the trick to running "ulimit?"

"command not found" yet whereis sez it is a shell builtin command.

Jack

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Help on a little script

2005-01-23 Thread antenneX
- Original Message - 
From: "Mike Jeays" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: 
Sent: Sunday, January 23, 2005 11:49 AM
Subject: Re: Help on a little script


> On Sun, 2005-01-23 at 11:30, antenneX wrote:
> > Am running FBSD-4.10p2
> >
> > I have a serious need for some help on a CGI script I just
installed.
> > I've tried to reach the author but no dice there.
> >
> > It's used to automate "unsubscribes" on a mail list.
> >
> > It works well except for this:
> > It changes my mail list from this format:
> > name1
> > name2
> > name3
> >
> > ...to this:
> > name1name2name3 <---one big long line with no separators.
> >
> > With over 6000 names it makes a huge long line instead with no space
> > between
> > the names either. It make a mess!
> >
> > I know how to convert
> > name1
> > name2
> > name3
> >
> > ...to
> > name1 name2 name3.
> >
> > like this:
> > #cat mybadlist | xargs > mygoodlist
> >
> > ...but, need the reverse.
> >
> > So how can I convert
> > name1name2name3
> > ...back to the original format?
> > name1
> > name2
> > name3
> >
> >
> > Would really appreciate your help as it is really messing up my mail
> > lists
> >
> > Thanks in advance!
> >
> > Best regards,
> >
> > Jack L. Stone
> >
> > ___
> > freebsd-questions@freebsd.org mailing list
> > http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> > To unsubscribe, send any mail to
"[EMAIL PROTECTED]"
>
> It may be impossible, if the names have really been run together with
no
> separator at all. '[EMAIL PROTECTED]@[EMAIL PROTECTED]' cannot
> reliably be parsed into distinct names.  Are you quite sure there is
no
> separator - look at the file with od (octal dump).
>

I was afraid of that. Fortunately I have routine backups every few
hours.

I have discovered that I have not been able to reproduce the corruption
or script failure. In copying back the good formtted list (but with some
unsubscribes back in) and running the web page unsubscribe, it is fine
for now -- but, mystified as to why it happened. Only been using the
script for 3 days but has had numerous adds and deletes before this.

Some sort of bug in the script. I thought it might have been a very log
email on the list, but removing and putting back made no difference.
Only this one list has been affected and is one of the largest.

Thanks for your reply.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Help on a little script

2005-01-23 Thread antenneX
Am running FBSD-4.10p2

I have a serious need for some help on a CGI script I just installed.
I've tried to reach the author but no dice there.

It's used to automate "unsubscribes" on a mail list.

It works well except for this:
It changes my mail list from this format:
name1
name2
name3

...to this:
name1name2name3 <---one big long line with no separators.

With over 6000 names it makes a huge long line instead with no space
between
the names either. It make a mess!

I know how to convert
name1
name2
name3

...to
name1 name2 name3.

like this:
#cat mybadlist | xargs > mygoodlist

...but, need the reverse.

So how can I convert
name1name2name3
...back to the original format?
name1
name2
name3


Would really appreciate your help as it is really messing up my mail
lists

Thanks in advance!

Best regards,

Jack L. Stone

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Check memory stats

2004-12-09 Thread antenneX
Also, check "MUSE" in ports I have it send me a message every hour
to show the memory used/available

Best regards,

Jack L. Stone
- Original Message - 
From: "Lowell Gilbert" <[EMAIL PROTECTED]>
To: "Jonathan Reeder" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, December 09, 2004 12:47 PM
Subject: Re: Check memory stats


> "Jonathan Reeder" <[EMAIL PROTECTED]> writes:
>
> > What is the closest utility FreeBSD has to Linux's "free" to check
memory
> > usage?
>
> top(1)
>
> See
>
http://www.freebsd.org/doc/en_US.ISO8859-1/books/faq/misc.html#TOP-FREEMEM
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Find & Replace string

2004-12-09 Thread antenneX
From: "Nathan Kinkade" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, December 09, 2004 12:13 PM
Subject: Re: Find & Replace string

> In a website of 1.GB+ with several hundred thousand files, I need to
> interrogate all files to replace a single string like "oldone.010"
with
> "newone.011"
>
> What's the best way to do this?
>
> Thanks in advance!
>
> Best regards,
>
> Jack L. Stone

Are you talking about changing the name of the file itself, or a string
within the file?  If it's the former then a shell for loop work.  Maybe
something like:

$ for file in $(find /somedir -name "*.010"); \
 do mv $file $(echo $file | sed -e 's/oldone/newone'); \
 done

If the latter, then using perl, perhaps with the -e -i switches, might
work well.  man perlrun(1) for some tips.

Nathan

-

No, I want to interrogate several hundred thousand files throughout
several thousand directories to find/replace a single string within each
file found. The string may appear more than once in a file.

Thanks for the reply


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Find & Replace string

2004-12-09 Thread antenneX
Help on commands/script needed.

In a website of 1.GB+ with several hundred thousand files, I need to
interrogate all files to replace a single string like "oldone.010" with
"newone.011"

What's the best way to do this?

Thanks in advance!

Best regards,

Jack L. Stone

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Sendmail in the base system

2004-12-02 Thread antenneX
Am running FBSD-4.10p2 with sendmail-8.12.11 in the base system.

If I wanted to recompile sendmail with a later DB like Berkley DB-4.2,
since its in the base system, what would be the best way of doing this?

- Rebuild make/install world without sendmail, then install sendmail
from the ports with my choice of DB?

- or, just install sendmail-8.13.x from ports with the new DB and then
have the system point to the new sendmail???

Best regards,

Jack L. Stone

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Upgrading Sendmail's DB

2004-09-24 Thread antenneX
Running FBSD-4.10p2/Sendmail-8.12.11

I want to upgrade the Sendmail's Berkley DB to 4.2x, but since Sendmail
is part of my base OS, what is best way to recompile Sendmail with the
new DB?

BTW, I use sources if not evident.

Do I need to recompile the whole OS which includes Sendmail or is there
an easier way to just update the Sendmail?

The Sendmail site is not very clear on this. It does say if the new DB
4.2x is installed and the new libraries  are there, it will find it and
use it instead of the old DB2 & that NEWDB takes care of it if it can
find the library named libdba.a or libdb.so.

Advice needed and appreciated.

Best regards,

Jack L. Stone

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: [another "me too"] Re: portindex/portindexdb

2004-09-06 Thread antenneX
- Original Message - 
From: "Joe Altman" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, September 06, 2004 7:35 PM
Subject: Re: [another "me too"] Re: portindex/portindexdb


> On Mon, Sep 06, 2004 at 09:20:14AM +0200, Nico Meijer wrote:
> > Hi Donald,
> >
> > >Nico - I suggest you try it again tomorrow. I thought I had it
fixed
> > >yesterday. Then I re-cvsup'd today and redid my things. Ruby18 is
> > >again seg faulting for me. Not going into a loop and continuously
> > >seg faulting, but bad enough.
> >
> > After cvsupping my ports tree, running portindex (not portindexdb!)
and
> > portsdb -u (which gave core dumps) all is well. No more 'bus
errors'.
> >
> > portindex seems like a wonderful tool, so I'm keeping it around.
>
> Sigh:
>
> on voip in /var/db # portsdb -Uu
> Updating the ports index ... Generating INDEX.tmp - please
> wait.. Done.
> done
> [Updating the portsdb  in /usr/ports ... - 11736
> port entries found
> .1000.2000.3000.4000.
> 5000.6000.7000.8000
> /usr/local/lib/ruby/site_ruby/1.8/portsdb.rb:587:
> [BUG] Bus Error
> ruby 1.8.2 (2004-07-29) [i386-freebsd4]
>
> Abort (core dumped)
>
> I'm thinking, at this point, that I'm seeing something
> hardware-related. Good thing I'm replacing voip w/ new hardware and
> moving to 5.3, I guess.

No, it's not hardware.. I've fixed mine following the earlier
threads.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: portindex/portindexdb

2004-09-05 Thread antenneX
Count me in too on this issue. I've had the "ruby18" problem and core
dumps, and do not have portindex/portmanetc. installed. Happens
after cvsup & running portsdb -Uu.


Best regards,

Jack L. Stone
- Original Message - 
From: "Matthew Seaman" <[EMAIL PROTECTED]>
To: "Donald J. O'Neill" <[EMAIL PROTECTED]>
Cc: "Steve Hodgson" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>; "kstewart" <[EMAIL PROTECTED]>
Sent: Sunday, September 05, 2004 3:17 AM
Subject: Re: portindex/portindexdb


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: php5 & libgd

2004-08-10 Thread antenneX
From: "Marc Cabanatuan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, August 10, 2004 6:31 PM
Subject: php5 & libgd


> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> ive grabbed php5 and attempted to grab phpMyAdmin from ports and in
> doing so (php5 works fine) I receive the error 'Unknown extension gd.'
> I recently discoevered that php was split from the core and its
> extensions, however in enabling 'gd' in php5-extensions, i still
> receive the same error.
> % make install clean
> Unknown extension gd.
> *** Error code 1
> Stop in /usr/ports/lang/php5-extensions.
>
> Is gd located in ports? What is the recommended way of grabbing libgd
> and installing it? pkg_add? Any help with this would be greatly
> appreciated.
>
> Thanks,
> m

I'm having the same trouble with php4 -- the gd fails everytime.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Installing php4

2004-07-24 Thread antenneX
- Original Message - 
From: "Drew Marshall" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Saturday, July 24, 2004 3:16 PM
Subject: Re: Installing php4


> Matthew Seaman wrote:
> 
>
> >Actually, php4-extensions works with any of the 'main' PHP ports --
> >lang/php4, lang/php4-cli, www/php4-cgi or www/mod_php4.  The fact
that
> >there are 4 different variations on a plain 'php4' port in the tree
is
> >the reason why all of the module support was moved out into a
separate
> >extensions port.
> >
> >While this move to specifying all of the PHP modules as loadable
> >extensions makes a great deal of sense from one point of view -- 
ports
> >that use PHP can now explicitly list all of the extensions they
> >require to operate, rather than having to have their own private PHP
> >slave ports -- the implementation has run into a number of problems.
> >
> >For php4 there are some extensions where the same functionality is
not
> >available when used as a loadable module as when compiled in.  The
> >security/php4-openssl extension is a case in point: unless OpenSSL
> >support is compiled-in, the fsockopen() function won't let you open
> >'tls://' or 'ssl://' style URLs.  (As a practical result, that means
> >that eg. Squirrelmail can't communicate with a secure IMAP server on
> >port 993.  The only alternative in that case is to communicate to an
> >unencrypted IMAP server on port 143, which quite probably involves
> >sending passwords over the net in plaintext.)
> >
> >Beyond that, not all of the PHP consuming ports have yet been updated
> >to depend on the appropriate PHP extensions, so installing those
ports
> >de novo doesn't immediately get you a workable system.  A common
> >symptom of this is a run-time error where one of the perl compatible
> >regular expression (pcre_*()) functions doesn't work.  The answer
> >pretty much is just to install the required extension modules by
hand,
> >and tweak the value of the 'extension_dir' directive in
> >/usr/local/etc/php.ini
> >
> >
> >
> I understand the logic but I would have thought a line somewhere in
> Makefile or the README just to give poor stupid people like me a clue
as
> to where to start looking. Ons further question that has come from my
> compilation of the php4-extension is that once you have made your
> selection the first time these options seem to be saved somewhere (The
> build process states found previous configuration or similar) where is
> this? I missed an option in my hurry this morning and now can't get
back
> to the menu options (No matter how many make cleans, pkg_deletes etc I
> do) to re-set or add the options.
>
> Many thanks for being so helpful
>
> Drew
>

Look at /var/db/ports/* and then delete any option files that pertain to
php4. That will allow the menu to come up again on a fresh make.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Using sendmail - One more file

2004-06-27 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Sunday, June 27, 2004 7:50 AM
Subject: Re: Using sendmail


> On 2004-06-25 10:12, antenneX <[EMAIL PROTECTED]> wrote:
> >
> > Giorgos: Thanks for your review of my setup & I did change the IP
for
> > server2 back to 200.200.200.102 -- however, now the emails go
straight
> > though the firewall port on server1 to sendmail on server2 and
> > apparently bypasses sendmail on server1. If it bypasses sendmail on
> > server1, I cannot use greylisting to filter the emails before being
sent
> > over to server2.
> >
> > I'm still missing something here.
>
> I'm afraid I haven't kept notes about your network setup, the name and
> IP address of each server involved, and their Sendmail options.
>

I forgot to include the mailertable from server1:
mail.antentop.comesmtp.mail.antentop.com

No mailertable on server2


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Using sendmail

2004-06-27 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Sunday, June 27, 2004 7:50 AM
Subject: Re: Using sendmail


> On 2004-06-25 10:12, antenneX <[EMAIL PROTECTED]> wrote:
> >
> > Giorgos: Thanks for your review of my setup & I did change the IP
for
> > server2 back to 200.200.200.102 -- however, now the emails go
straight
> > though the firewall port on server1 to sendmail on server2 and
> > apparently bypasses sendmail on server1. If it bypasses sendmail on
> > server1, I cannot use greylisting to filter the emails before being
sent
> > over to server2.
> >
> > I'm still missing something here.
>
> I'm afraid I haven't kept notes about your network setup, the name and
> IP address of each server involved, and their Sendmail options.
>
> Can you, please, show me what these commands print?
>

Giorgos: Thanks for your patience and willingness to help.

As far as sendmail (8.12.11) options, my configs are pretty much "out of
the box" except for the spamassassin & majordomo addins. I believe below
is all the pertinent info, but if I've missed anything needed, just let
me know:

server1 = franklin-belle.com (gateway/firewall/nat/router)
server2 = antentop.com (server is on same LAN with NAT route from
server1)

[EMAIL PROTECTED]:-) host franklin-belle.com
franklin-belle.com has address 65.68.247.73
franklin-belle.com mail is handled (pri=0) by mail.franklin-belle.com

[EMAIL PROTECTED]:-) host antentop.com
antentop.com has address 65.68.247.75
antentop.com mail is handled (pri=0) by mail.antentop.com


[EMAIL PROTECTED]:-) host -t mx franklin-belle.com
franklin-belle.com mail is handled (pri=0) by mail.franklin-belle.com

[EMAIL PROTECTED]:-) host -t mx antentop.com
antentop.com mail is handled (pri=0) by mail.antentop.com

local-host-names (franklin-belle.com)
franklin-belle.com
mail.franklin-belle.com

local-host-names (antentop.com)
antentop.com
mail.antentop.com

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: A SED script

2004-06-27 Thread antenneX
- Original Message - 
From: "Malcolm Kay" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>; "Giorgos Keramidas"
<[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Saturday, June 26, 2004 10:35 PM
Subject: Re: A SED script


> On Sunday 27 June 2004 07:49, antenneX wrote:
> > - Original Message -----
> > From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
> > To: "antenneX" <[EMAIL PROTECTED]>
> > Cc: <[EMAIL PROTECTED]>
> > Sent: Saturday, June 26, 2004 1:40 PM
> > Subject: Re: A SED script
> >
> > > On 2004-06-26 12:08, antenneX <[EMAIL PROTECTED]> wrote:
> > > > I cannot get it to work on another file (perl.pl file) to change
the
> >
> > line:
> > > > $OrderNumPrefix = "ATX060"; to $OrderNumPrefix = "ATX070";
> > > >
> > > > I suspect I'm not handling the quotes or other operators
correctly
> >
> > and it
> >
> > > > just ignores the change.
> > > >
> > > > Here's the snippet of the script I'm trying to use:
> > > > #!/bin/sh
> > > > new=`grep -i new /path/to/newfile`
> > > > old=`grep -i new /path/to/oldfile`
>
> It would seem that the variables new and old will both be set to
something
> containing 'new' (perhaps not in lower case).
> How does this relate to "ATX060" and "ATX070"?
>
> > > > sed -i.bak -e "s/$old/$new/" /path/to/myfile
> > >
> > > The results depend heavily on the existence and contents of the
two
> >
> > files
> >
> > > named /path/to/{old,new}file.  I'm sure if you change the sed line
to:
> > >
> > > sed -i.bak -e 's/ATX060/ATX070/' /path/to/myfile
> > >
> > > it will all work fine.
> >
> > Indeed, this works fine. The old/new files are needed to set the
> > varibles to hold the new number for the next time as this is run via
> > cron.
> >
>
> You've still not shown us the relevant lines of /path/to/newfile or
> /path/to/oldfile
>
> > old = ATX060
> > new = ATX070
>
> What are these? The contents of /path/to/{new,old}file?
> If so sed will be looking to change the string "old = ATX060" to
> "new = ATX070".
>
> Or do the files simply consist of
> ATX060
> and
> ATX070
> ?
> If so then grep is not the right command to load the variables old and
new.
> Try:
>   new=`cat /path/to/newfile`
>   old=`cat /path/to/oldfile`
>
> Malcolm
>

I've solved the script ptoblem with a verbose run of the script & it
told me exactly what was wrong -- the two varibles newfile & oldfile
were not defined properly.

Running this showed the error:
/bin/sh -xv ./myscript

Sorry I didn't think to do this in the first place.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: A SED script

2004-06-26 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Saturday, June 26, 2004 1:40 PM
Subject: Re: A SED script


> On 2004-06-26 12:08, antenneX <[EMAIL PROTECTED]> wrote:
> > I cannot get it to work on another file (perl.pl file) to change the
line:
> > $OrderNumPrefix = "ATX060"; to $OrderNumPrefix = "ATX070";
> >
> > I suspect I'm not handling the quotes or other operators correctly
and it
> > just ignores the change.
> >
> > Here's the snippet of the script I'm trying to use:
> > #!/bin/sh
> > new=`grep -i new /path/to/newfile`
> > old=`grep -i new /path/to/oldfile`
> > sed -i.bak -e "s/$old/$new/" /path/to/myfile
>
> The results depend heavily on the existence and contents of the two
files
> named /path/to/{old,new}file.  I'm sure if you change the sed line to:
>
> sed -i.bak -e 's/ATX060/ATX070/' /path/to/myfile
>
> it will all work fine.
>

Indeed, this works fine. The old/new files are needed to set the
varibles to hold the new number for the next time as this is run via
cron.

old = ATX060
new = ATX070

then, after the script changes the line in the perl script, it needs
to pipe (echo/cat) in the new file contents to the old:
cat newfile > oldfile ---> which is now ATX070 for oldfile
...then incremement the newfile to become "ATX080" and so on

Now, got to figure out how to increment number up. It is an invoice
prefix number that contains the month # and must modify the perl file
that is part of a custom order set of scripts.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


A SED script

2004-06-26 Thread antenneX
Running FBSD-4.10

Below is a portion of a script that uses sed(1) to change a portion of a
line in a file. It works fone for that one.

However, I cannot get it to work on another file (perl.pl file) to
change the line:
$OrderNumPrefix = "ATX060"; to $OrderNumPrefix = "ATX070";

I suspect I'm not handling the quotes or other operators correctly and
it just ignores the change.

Here's the snippet of the script I'm trying to use:
#!/bin/sh
new=`grep -i new /path/to/newfile`
old=`grep -i new /path/to/oldfile`
sed -i.bak -e "s/$old/$new/" /path/to/myfile

and, again the line in the file:
$OrderNumPrefix = "ATX060"; <---line in the file to change

What do I need to change to make it work???

Thanks for any help!




Best regards,

Jack L. Stone

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Using sendmail

2004-06-25 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, June 24, 2004 2:08 PM
Subject: Re: Using sendmail


> [-- Format recovered from broken Outlook wrapping --]
>
> On 2004-06-24 13:18, antenneX <[EMAIL PROTECTED]> wrote:
> > Giorgos Keramidas <[EMAIL PROTECTED]> wrote:
> > > On 2004-06-24 11:33, antenneX <[EMAIL PROTECTED]> wrote:
> > > > oops! I should have said please send any config examples
> > > > needed to do this...??
> > >
> > > Look at the file /usr/share/sendmail/cf/README near line 794:
> > >
> > > : mailertable Include a "mailer table" which can be used to
override
> > > : [snip]
> > >
> > > You might also want to check out the rest of this file, [...]
> >
> > Okay, I know I still have messed it up. Tried the setup below, but
something
> > is wrong because of the errors shown and is not delivered to server
#2.
> >
> > Server #1 - IP 200.200.200.101
> > - DNS for mail.server2.net points here (was to 200.200.200.102 and
OK on
> > normal delivery)
>
> I hope you don't mean that the name "mail.server2.net" now points to
> 200.200.200.101.  Only the MX records for server2.net need to point to
> the first host, so that mail for the domain is delivered to this host.
>
> > - mail.server2.net in local-host-names
>
> IIRC, this isn't right.  You should only list mail.server2.net in the
> local-host-names of 200.200.200.102.
>
> > - In mailertable = mail.server2.net esmtp:mail.server2.net
>
> This seems ok.
>
> > Server #2 - IP 200.200.200.102
> > - has sendmail & pop3
> > - mail.server2.net in local-host-names
> > - has user "william"
>
> This seems ok too.
>
> > Send test mail: [EMAIL PROTECTED]
> > get error:
> > SYSERR(root): mail.server2.net. config error: mail loops back to me
(MX
> > problem?)
>
> That's because mail.server2.net points to the address 200.200.200.101.
> When sendmail on that host tries to deliver the message as per the
> instructions of your mailertable, it discovers that the message is
sent
> back to itself!  A loop...
>
> - Giorgos

Giorgos: Thanks for your review of my setup & I did change the IP for
server2 back to 200.200.200.102 -- however, now the emails go straight
though the firewall port on server1 to sendmail on server2 and
apparently bypasses sendmail on server1. If it bypasses sendmail on
server1, I cannot use greylisting to filter the emails before being sent
over to server2.

I'm still missing something here.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Using sendmail

2004-06-24 Thread antenneX
- Original Message - 
From: "Giorgos Keramidas" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, June 24, 2004 11:57 AM
Subject: Re: Using sendmail


> On 2004-06-24 11:33, antenneX <[EMAIL PROTECTED]> wrote:
> > oops! I should have said please send any config examples needed to
do
> > this...??
>
> Look at the file /usr/share/sendmail/cf/README near line 794:
>
> : mailertable Include a "mailer table" which can be used to override
> : routing for particular domains (which are not in class
{w},
> : i.e.  local host names).  The argument of the FEATURE
may be
> : the key definition.  If none is specified, the
definition
> : used is:
> :
> : hash /etc/mail/mailertable
> :
>
> You might also want to check out the rest of this file, as it's the
> definitive reference for sendmail configuration options.  Another good
> reference, which is always available, but seldom exploited to its full
> potential is the ``Sendmail Installation and Operation Guide''.
>
> You can find it in /usr/share/doc:
>
> $ zcat /usr/share/doc/smm/08.sendmailop/paper.ascii.gz | less
>
> HTH,
>
> - Giorgos
>

Indeed, I had read the above before and spent lost of time searchin the
sendmail website too, but could never get it right.

Okay, I know I still have messed it up. Tried the setup below, but something
is wrong because of the errors shown and is not delivered to server #2.

Server #1 - IP 200.200.200.101
- DNS for mail.server2.net points here (was to 200.200.200.102 and OK on
normal delivery)
- mail.server2.net in local-host-names
- In mailertable = mail.server2.net esmtp:mail.server2.net

Server #2 - IP 200.200.200.102
- has sendmail & pop3
- mail.server2.net in local-host-names
- has user "william"

Send test mail: [EMAIL PROTECTED]
get error:
SYSERR(root): mail.server2.net. config error: mail loops back to me (MX
problem?)

and...

Jun 24 12:43:45 server1 sm-mta[78108]: i5OHhi0f078104:
to=<[EMAIL PROTECTED]>, delay=00:00:01, xdelay=00:00:00, mailer=esmtp,
pri=30706, relay=mail.server2.net. [200.200.200.101], dsn=5.3.5, stat=Local
configuration error

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Using sendmail

2004-06-24 Thread antenneX
oops! I should have said please send any config examples needed to do
this...??

Thanks again!
Best regards,

Jack L. Stone

- Original Message - 
From: "Murat Bicer" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, June 24, 2004 11:02 AM
Subject: Re: Using sendmail


> you need to user mailertable to send the email from first server to
> the second one. no need to forward. the second server should accept
> the emails for the domains it is holding the mailboxes for (in access
> file)
>
> Let me know if you need some config examples.
>
> -M.
>
> On Thu, 24 Jun 2004 10:46:15 -0500, antenneX <[EMAIL PROTECTED]> wrote:
> >
> > Hope this isn't too far OT.
> >
> > I want to setup 2 mailservers using sendmail. The first to receive
emails
> > for all users (vhosts too) and filter through greylisting. Then forward
the
> > rest to another mailserver using SpamAssassin/Procmail on the LAN to
their
> > POP3 Inboxes (qpopper) where they will pick up their mail.
> >
> > Based on tests so far, it looks like I will have to use an "open relay"
in
> > order to forward the emails. Is this correct?
> >
> > Would appreciate any URLs where this setup is explained.
> >
> > Best regards,
> >
> > Jack L. Stone
> >
> > ___
> > [EMAIL PROTECTED] mailing list
> > http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> > To unsubscribe, send any mail to
"[EMAIL PROTECTED]"
> >
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Using sendmail

2004-06-24 Thread antenneX
Mailertable -- oho! Never thought of that. Yes, could you send an example of
the typical mailertable file that will do this?

Many, many thanks &
Best regards,

Jack L. Stone
- Original Message - 
From: "Murat Bicer" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, June 24, 2004 11:02 AM
Subject: Re: Using sendmail


> you need to user mailertable to send the email from first server to
> the second one. no need to forward. the second server should accept
> the emails for the domains it is holding the mailboxes for (in access
> file)
>
> Let me know if you need some config examples.
>
> -M.
>
> On Thu, 24 Jun 2004 10:46:15 -0500, antenneX <[EMAIL PROTECTED]> wrote:
> >
> > Hope this isn't too far OT.
> >
> > I want to setup 2 mailservers using sendmail. The first to receive
emails
> > for all users (vhosts too) and filter through greylisting. Then forward
the
> > rest to another mailserver using SpamAssassin/Procmail on the LAN to
their
> > POP3 Inboxes (qpopper) where they will pick up their mail.
> >
> > Based on tests so far, it looks like I will have to use an "open relay"
in
> > order to forward the emails. Is this correct?
> >
> > Would appreciate any URLs where this setup is explained.
> >
> > Best regards,
> >
> > Jack L. Stone
> >
> > ___
> > [EMAIL PROTECTED] mailing list
> > http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> > To unsubscribe, send any mail to
"[EMAIL PROTECTED]"
> >
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Using sendmail

2004-06-24 Thread antenneX
Hope this isn't too far OT.

I want to setup 2 mailservers using sendmail. The first to receive emails
for all users (vhosts too) and filter through greylisting. Then forward the
rest to another mailserver using SpamAssassin/Procmail on the LAN to their
POP3 Inboxes (qpopper) where they will pick up their mail.

Based on tests so far, it looks like I will have to use an "open relay" in
order to forward the emails. Is this correct?

Would appreciate any URLs where this setup is explained.


Best regards,

Jack L. Stone

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Warning: undefined file type - RESOLVED

2004-05-14 Thread antenneX
My bad fsck-it of course!

Sorry I didn't think of the obvious before my question.

Best regards,

Jack L. Stone
- Original Message - 
From: "antenneX" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, May 14, 2004 12:55 PM
Subject: DUMP: Warning: undefined file type


> Running FBSD-4.8.
>
> Folks: Hope this is too far OT, but maybe someone else has had this
problem
> with Dump(8).
>
> During mys dumps on one server, I get the warnings below about undefined
> file types. What would cause this and how do I find them to "define"
> or?? Are they corrupt files? Never got this error before after 1000s
of
> dumps.
>
> Any help appreciated.
>
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 015
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 016
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>   DUMP: Warning: undefined file type 017
>
> Best regards,
>
> Jack L. Stone
>
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
"[EMAIL PROTECTED]"

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


DUMP: Warning: undefined file type

2004-05-14 Thread antenneX
Running FBSD-4.8.

Folks: Hope this is too far OT, but maybe someone else has had this problem
with Dump(8).

During mys dumps on one server, I get the warnings below about undefined
file types. What would cause this and how do I find them to "define"
or?? Are they corrupt files? Never got this error before after 1000s of
dumps.

Any help appreciated.

  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 015
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 016
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017
  DUMP: Warning: undefined file type 017

Best regards,

Jack L. Stone

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Lost expat dependency

2004-04-18 Thread antenneX

- Original Message - 
From: "Kent Stewart" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: "antenneX" <[EMAIL PROTECTED]>; "Remko Lodder" <[EMAIL PROTECTED]>
Sent: Sunday, April 18, 2004 1:17 PM
Subject: Re: Lost expat dependency


> On Sunday 18 April 2004 10:22 am, Remko Lodder wrote:
> > antenneX wrote:
> > > It seems that when I updated to expat-1.95.7, it replaced some
> > > 1.95.5 dependencies needed for some other programs. For instance
> > > some daemons will not load (or update) because of this error:
> > > #Shared object "libintl.so.4" not found#
> > > or then some ".so" module cannot be loaded
> >
> > Did you use portupgrade to update it recursivly? then everythint that
> > had .5 as dep was reinstalled using .7 instead..
> >
> > Perhaps you can (dirty solution)
> >
> > ln -s libintl.so.5 libintl.so.4
> > in the directory wehere libintl.so.5 lives.
> >
> 
> The solution is in /usr/ports/UPDATING. They changed the interface and 
> you have to portupgrade -rf expat.
> 
> Kent
> 
> > HTH
> >
> > > I updated the expat according the the instructions in
> > > /usr/ports/UPDATING.
> > >
> > > Any suggestions on how to fix this???
> > >
> > > Thanks!
> > >
> > > Jack
> 
> -- 
> Kent Stewart
> Richland, WA
> 

Kent: Indeed I had read UPDATING as my message stated, I used the:
#portupgrade -rf expat
...but, some programs are making that same complaint and won't load.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Lost expat dependency

2004-04-18 Thread antenneX
It seems that when I updated to expat-1.95.7, it replaced some 1.95.5
dependencies needed for some other programs. For instance some daemons will
not load (or update) because of this error:
#Shared object "libintl.so.4" not found#
or then some ".so" module cannot be loaded

I updated the expat according the the instructions in /usr/ports/UPDATING.

Any suggestions on how to fix this???

Thanks!

Jack

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Setting Sendmail to Refuse Possibly Forged Headers

2004-04-16 Thread antenneX
- Original Message - 
From: "Dan Nelson" <[EMAIL PROTECTED]>
To: "antenneX" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, April 15, 2004 11:01 PM
Subject: Re: Setting Sendmail to Refuse Possibly Forged Headers


> In the last episode (Apr 15), antenneX said:
> > > SLocal_check_mail
> > > R$* $: $1 $| $&s Put helo name in workspace
> > > R$* $| $={RejectHelo} $#error $@ 5.7.1 $: "550 Spammer access denied"
> > > R$* $| $* $: $1 Extract helo from workspace if it doesn't match
> > > #-/\-
> >
> > Dan: Your suggestions here were appealing, but I'm batting zero.
> >
> > 1- Will milter-sender work alongside spamass-milter...??
> > I *think* it was working on a test box, but failed on production
box.
>
> They should coexist peacefully.  In general, milters should be unaware
> of each other.  I'd put milter-sender in front of spamass-milter, since
> spamassassin can be CPU-hungry and there's no need to mark a message as
> spam if milter-sender is just going to deny it anyway.
>
> > 2- Each of your 3 lines above for "local_check_mail" yelled about
> > expecting a Tab when sendmail was restarted... not sure how to fix
> > that.
>
> My outgoing message had tabs; if your mailer removes them or replaces
> them with spaces, here's where they go:
>
> R$*$: $1 $| $&sPut helo name in workspace
> R$* $| $={RejectHelo}$#error $@ 5.7.1 $: "550 Spammer access denied"
> R$* $| $*$: $1Extract helo from workspace if it doesn't match
>
> -- 
> Dan Nelson
> [EMAIL PROTECTED]

Dan: Thanks for clearing that up.

If I may ask one more thing about the milter-sender:
The only feature I really wanted from the milter was the option to control
the number of connections for "unknown users". I get a lot of those -- 
dozens -- hundreds. I believe that is called the "Rumplestilkin" (sp?)
attack where a search is conducted for good emails on a system.

I have not yet seen this option available inside Sendmail and wonder if
there is one out there yet...?? -- without having to install the milter?

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Setting Sendmail to Refuse Possibly Forged Headers

2004-04-15 Thread antenneX
- Original Message - 
From: "Dan Nelson" <[EMAIL PROTECTED]>
To: "Martin McCormick" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Thursday, April 15, 2004 12:26 PM
Subject: Re: Setting Sendmail to Refuse Possibly Forged Headers


> In the last episode (Apr 15), Martin McCormick said:
> > The sendmail that comes with FreeBSD is set to disallow all
> > third-party relaying which is wonderful and how I want to keep
> > things.
> >
> > In addition to that, I would like to try to set it to refuse
> > incoming mail with forged address headers.  Judging from the logs, it
> > seems to be pretty good at catching such messages and most of the
> > ones I look at that trigger this warning are spam.
>
> Take a look at the milter-sender port, which checks the sender's email
> address and verifies that an smtp server is listening.  It's not
> something that can be done within sendmail, which is why it's a milter.
>
> Another thing to check is the HELO string.  The following will block
> all incoming mails claiming to be the mailserver itself.  Replace
> XX your with server's IP and domainnames, spearated by spaces (so
> "C{RejectHelo} 1.2.3.4 mydomain.com", for example).  I deny ~500 spams
> a day with this rule alone.
>
> #+\/+ Block connections from servers that try and send our IP or hostname
in the HELO
> LOCAL_CONFIG
> C{RejectHelo} XX
>
> LOCAL_RULESETS
>
> SLocal_check_mail
> R$* $: $1 $| $&s Put helo name in workspace
> R$* $| $={RejectHelo} $#error $@ 5.7.1 $: "550 Spammer access denied"
> R$* $| $* $: $1 Extract helo from workspace if it doesn't match
> #-/\-
>
> -- 
> Dan Nelson
> [EMAIL PROTECTED]

Dan: Your suggestions here were appealing, but I'm batting zero.

1- Will milter-sender work alongside spamass-milter...??
I *think* it was working on a test box, but failed on production box.

2- Each of your 3 lines above for "local_check_mail" yelled about expecting
a Tab when sendmail was restarted... not sure how to fix that.

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"