Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Qmail: users

how can i filter my mail

 

 

Qmail users RSS feed   Index | Next | Previous | View Threaded


tobeinto at gmail

May 1, 2008, 10:36 AM

Post #1 of 6 (368 views)
Permalink
how can i filter my mail

HI List,
I M very much new to this list. can anyone guide me to in filtering mail
using maildrop. on the based on subject line can i filter mail on the time
of delivery to the user's mailbox?


cheers,
Anairban


dsr at tao

May 1, 2008, 12:22 PM

Post #2 of 6 (351 views)
Permalink
Re: how can i filter my mail [In reply to]

On Thu, May 01, 2008 at 11:06:41PM +0530, Anirban Mukherjee wrote:
> HI List,
> I M very much new to this list. can anyone guide me to in filtering mail
> using maildrop. on the based on subject line can i filter mail on the time
> of delivery to the user's mailbox?

In the user's .qmail:
|/usr/bin/maildrop
(or whatever path is needed)

In the user's homedirectory, a .mailfilter file, including
things like:

if (/^Subject:\ stuff-you-will-filter-on.*/:h)
to /path/to/filtered/Maildir/

For more details, consult http://www.courier-mta.org/maildrop/

-dsr-


--
http://tao.merseine.nu/~dsr/eula.html is hereby incorporated by reference.

"Someone is wrong on the Internet." - Randall Munroe


tobeinto at gmail

May 7, 2008, 3:35 AM

Post #3 of 6 (312 views)
Permalink
Re: how can i filter my mail [In reply to]

On Fri, May 2, 2008 at 12:52 AM, Dan Ritter <dsr[at]tao.merseine.nu> wrote:

> On Thu, May 01, 2008 at 11:06:41PM +0530, Anirban Mukherjee wrote:
> > HI List,
> > I M very much new to this list. can anyone guide me to in filtering mail
> > using maildrop. on the based on subject line can i filter mail on the
> time
> > of delivery to the user's mailbox?
>
> In the user's .qmail:
> |/usr/bin/maildrop
> (or whatever path is needed)
>
> In the user's homedirectory, a .mailfilter file, including
> things like:
>
> if (/^Subject:\ stuff-you-will-filter-on.*/:h)
> to /path/to/filtered/Maildir/
>
> For more details, consult http://www.courier-mta.org/maildrop
>


>
> -

I have done the above mentioned solution, but the problem is mail is getting
stuck in the queue.
here is qmail-send log
/@400000004822d6b616251eec starting delivery 2: msg 2360673 to local
t<http://www.courier-mta.org/maildrop/>
est.com-trm[at]test.com
@400000004822d6b616255984 status: local 1/10 remote 0/255
@400000004822d6b61bc0aed4 delivery 2: deferral:
This_account_is_currently_not_available./maildrop:_error_writing_to_mailbox.//usr/local/bin/maildrop:_Unable_to_deliver_to_mailbox./
@400000004822d6b61bc0f524 status: local 0/10 remote 0/255
@400000004822d6cf1bbd2494 starting delivery 3: msg 2357969 to local
test.com-trm[at]test.com
@400000004822d6cf1bc27fac status: local 1/10 remote 0/255
@400000004822d6cf2126a7fc delivery 3: deferral:
This_account_is_currently_not_available./maildrop:_error_writing_to_mailbox.//usr/local/bin/maildrop:_Unable_to_deliver_to_mailbox./
<http://www.courier-mta.org/maildrop/>
my .qmail file[root[at]test trm]# cat .qmail
|/var/qmail/bin/preline /usr/local/bin/maildrop

.mailfilter

[root[at]test trm]# cat .mailfilter
if (/^Subject:\ SPAM.*/:h)
to "/home/vpopmail/domains/test.com/trm/Maildir/.Spam"

--
AM


dsr at tao

May 7, 2008, 4:03 AM

Post #4 of 6 (313 views)
Permalink
Re: how can i filter my mail [In reply to]

On Wed, May 07, 2008 at 04:05:12PM +0530, Anirban Mukherjee wrote:
> On Fri, May 2, 2008 at 12:52 AM, Dan Ritter <dsr[at]tao.merseine.nu> wrote:
> > For more details, consult http://www.courier-mta.org/maildrop
>
>
> I have done the above mentioned solution, but the problem is mail is getting
> stuck in the queue.
> here is qmail-send log
> /@400000004822d6b616251eec starting delivery 2: msg 2360673 to local
> t<http://www.courier-mta.org/maildrop/>
> est.com-trm[at]test.com
> @400000004822d6b616255984 status: local 1/10 remote 0/255
> @400000004822d6b61bc0aed4 delivery 2: deferral:
> This_account_is_currently_not_available./maildrop:_error_writing_to_mailbox.//usr/local/bin/maildrop:_Unable_to_deliver_to_mailbox./

Well, there's your problem.

> my .qmail file[root[at]test trm]# cat .qmail
> |/var/qmail/bin/preline /usr/local/bin/maildrop
>
> .mailfilter
>
> [root[at]test trm]# cat .mailfilter
> if (/^Subject:\ SPAM.*/:h)
> to "/home/vpopmail/domains/test.com/trm/Maildir/.Spam"

I see no default delivery instructions, and I suspect that
/home/vpopmail/domains/test.com/trm/Maildir/.Spam does not exist
(as a mailbox) or is a Maildir which hasn't been properly
specified (Maildirs need / at the end).

-dsr-

--
http://tao.merseine.nu/~dsr/eula.html is hereby incorporated by reference.

When freedom gets lots of exercise, it protects itself.


tobeinto at gmail

May 7, 2008, 5:34 AM

Post #5 of 6 (313 views)
Permalink
Re: how can i filter my mail [In reply to]

On Wed, May 7, 2008 at 4:33 PM, Dan Ritter <dsr[at]tao.merseine.nu> wrote:

> On Wed, May 07, 2008 at 04:05:12PM +0530, Anirban Mukherjee wrote:
> > On Fri, May 2, 2008 at 12:52 AM, Dan Ritter <dsr[at]tao.merseine.nu> wrote:
> > > For more details, consult http://www.courier-mta.org/maildrop
> >
> >
> > I have done the above mentioned solution, but the problem is mail is
> getting
> > stuck in the queue.
> > here is qmail-send log
> > /@400000004822d6b616251eec starting delivery 2: msg 2360673 to local
> > t<http://www.courier-mta.org/maildrop/>
> > est.com-trm[at]test.com
> > @400000004822d6b616255984 status: local 1/10 remote 0/255
> > @400000004822d6b61bc0aed4 delivery 2: deferral:
> >
> This_account_is_currently_not_available./maildrop:_error_writing_to_mailbox.//usr/local/bin/maildrop:_Unable_to_deliver_to_mailbox./
>
> Well, there's your problem.
>
> > my .qmail file[root[at]test trm]# cat .qmail
> > |/var/qmail/bin/preline /usr/local/bin/maildrop
> >
> > .mailfilter
> >
> > [root[at]test trm]# cat .mailfilter
> > if (/^Subject:\ SPAM.*/:h)
> > to "/home/vpopmail/domains/test.com/trm/Maildir/.Spam"
>
> I see no default delivery instructions, and I suspect that
> /home/vpopmail/domains/test.com/trm/Maildir/.Spam does not exist
> (as a mailbox) or is a Maildir which hasn't been properly
> specified (Maildirs need / at the end).


I have changed the "mailfilter" file here it is VPOP="|
/home/vpopmail/bin/vdelivermail '' bounce-no-mailbox"
VHOME=`/home/vpopmail/bin/vuserinfo -d $EXT@$HOST`

if (/^X-Spam-Flag: *YES/)
{
# try filtering it using user-defined rules
exception {
include $VHOME/Maildir/.mailfilter
}
# then try delivering it to a Spam folder
exception {
# to "$VPOP"
to "$VHOME/Maildir/.Spam/"
}
# ah well, I guess they'll just have to live with disappointment
exception {
to "$VPOP"
}
}
else
{
exception {
include $VHOME/Maildir/.mailfilter
}
exception {
to "$VPOP"
}
}

in user's ".qmail" file is contain
cat trm/.qmail
# deliver into a file in $HOME/Maildir/
./Maildir/

cat .qmail-default
| maildrop mailfilter
#| /home/vpopmail/bin/vdelivermail '' bounce-no-mailbox
#|/usr/local/bin/maildrop /home/vpopmail/.mailfilter

eventhough no luck

--
AM


tobeinto at gmail

May 7, 2008, 11:15 PM

Post #6 of 6 (297 views)
Permalink
Re: how can i filter my mail [In reply to]

On Wed, May 7, 2008 at 4:33 PM, Dan Ritter <dsr[at]tao.merseine.nu> wrote:

> On Wed, May 07, 2008 at 04:05:12PM +0530, Anirban Mukherjee wrote:
> > On Fri, May 2, 2008 at 12:52 AM, Dan Ritter <dsr[at]tao.merseine.nu> wrote:
> > > For more details, consult http://www.courier-mta.org/maildrop
> >
> >
> > I have done the above mentioned solution, but the problem is mail is
> getting
> > stuck in the queue.
> > here is qmail-send log
> > /@400000004822d6b616251eec starting delivery 2: msg 2360673 to local
> > t<http://www.courier-mta.org/maildrop/>
> > est.com-trm[at]test.com
> > @400000004822d6b616255984 status: local 1/10 remote 0/255
> > @400000004822d6b61bc0aed4 delivery 2: deferral:
> >
> This_account_is_currently_not_available./maildrop:_error_writing_to_mailbox.//usr/local/bin/maildrop:_Unable_to_deliver_to_mailbox./
>
> Well, there's your problem.
>
> > my .qmail file[root[at]test trm]# cat .qmail
> > |/var/qmail/bin/preline /usr/local/bin/maildrop
> >
> > .mailfilter
> >
> > [root[at]test trm]# cat .mailfilter
> > if (/^Subject:\ SPAM.*/:h)
> > to "/home/vpopmail/domains/test.com/trm/Maildir/.Spam"
>
> I see no default delivery instructions, and I suspect that
> /home/vpopmail/domains/test.com/trm/Maildir/.Spam does not exist
> (as a mailbox) or is a Maildir which hasn't been properly
> specified (Maildirs need / at the end).
>
> I have changed the "mailfilter" file here it is VPOP="|
/home/vpopmail/bin/vdelivermail '' bounce-no-mailbox"
VHOME=`/home/vpopmail/bin/vuserinfo -d $EXT@$HOST`

if (/^X-Spam-Flag: *YES/)
{
# try filtering it using user-defined rules
exception {
include $VHOME/Maildir/.mailfilter
}
# then try delivering it to a Spam folder
exception {
# to "$VPOP"
to "$VHOME/Maildir/.Spam/"
}
# ah well, I guess they'll just have to live with disappointment
exception {
to "$VPOP"
}
}
else
{
exception {
include $VHOME/Maildir/.mailfilter
}
exception {
to "$VPOP"
}
}

in user's ".qmail" file is contain
cat trm/.qmail
# deliver into a file in $HOME/Maildir/
./Maildir/

cat .qmail-default
| maildrop mailfilter
#| /home/vpopmail/bin/vdelivermail '' bounce-no-mailbox
#|/usr/local/bin/maildrop /home/vpopmail/.mailfilter

eventhough no luck

--
AM

Qmail users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.