Mail Server Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationMail Server Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old April 18th, 2004, 06:10 PM
nednieuws nednieuws is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 70 nednieuws User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 58 sec
Reputation Power: 5
qmail equivalent of sendmail's virtmaps

I'm trying to figure out how to implement sendmail's virtmaps feature. As an example, let's say mail addressed to user@domain.com should be forwarded to local user joe. Some thoughts I have so far:

~/.qmail [www.lifewithqmail.org]
I don't think this is the way to go as I'm looking for something that goes the other way around, correct?

/var/qmail/.qmail-users [qmail-users(5)]
Looks right, but I'm missing the domain name in the address part. Furthermore, the fact that I'd need the uid/gid of the local user seems a bit odd.

That's how far I've gotten.

Requirements: users should be able to get their mail using either POP3 or IMAP and should have access to procmail should they so desire. I'm using the ./Maildir format.
__________________
Regards, Charles.

Reply With Quote
  #2  
Old April 18th, 2004, 06:38 PM
alexgreg's Avatar
alexgreg alexgreg is offline
Full Access
Dev Shed Regular (2000 - 2499 posts)
 
Join Date: Jun 2000
Location: London, UK
Posts: 2,019 alexgreg User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 sec
Reputation Power: 11
Quote:
I'm trying to figure out how to implement sendmail's virtmaps feature. As an example, let's say mail addressed to user@domain.com should be forwarded to local user joe. Some thoughts I have so far:

~/.qmail [www.lifewithqmail.org]
I don't think this is the way to go as I'm looking for something that goes the other way around, correct?

No - I think this (combined with /var/qmail/control/virtualdomains) is what you're looking for. Put an entry like:
Code:
domain.com:alias-domain

into /var/qmail/control/virtualdomains and add domain.com to /var/qmail/control/rcpthosts and restart qmail. Then just create .qmail files in /var/qmail/alias like this:
Code:
echo joe > /var/qmail/alias/.qmail-domain-user

This will deliver all mail to user@domain.com to local user joe's maildir (assuming that's the defaultdelivery) in his home directory. You can use procmail via the .qmail file - see http://cr.yp.to/qmail/faq/incominguser.html#procmail for more details.

Quote:
Requirements: users should be able to get their mail using either POP3 or IMAP and should have access to procmail should they so desire. I'm using the ./Maildir format.

See Life with qmail for POP3 and IMAP installation instructions. Using procmail is described above.
__________________
Alex
(http://www.alex-greg.com)

Reply With Quote
  #3  
Old April 18th, 2004, 07:11 PM
nednieuws nednieuws is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 70 nednieuws User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 58 sec
Reputation Power: 5
Hello Alex,

I've looked at the virtual domain section, but especially the part where it says example.com:user is unclear to me. I'll explain that below.

I hope you can walk me through the following: Let's say I want to have qmail's equivalent of this fictitious /etc/virtusertable:



If I understand things correctly:

1. In /var/qmail/control/rcpthosts and locals I need to add
Code:
rijndersholding.nl
rijndersenvanschaik.nl


2. In /var/qmail/control/virtualdomains I need to add
Code:
rijndersholding.nl:alias-rijndersholding.nl
rijndersenvanschaik.nl:alias-rijndersenvanschaik.nl


In the docs, alias-rijndersholding.nl and alias-rijndersenvanschaik.nlare local users. I don't get this, they will never receive any mail anyway. Who does get the mail is defined in part 3.

3. In /var/qmail/alias I need to execute
Code:
echo jos > /var/qmail/alias/.qmail-rijndersholding.nl-mailer-daemon
echo jos > /var/qmail/alias/.qmail-rijndersholding.nl-postmaster
echo jos > /var/qmail/alias/.qmail-rijndersholding.nl-root
echo rh001 > /var/qmail/alias/.qmail-rijndersholding.nl-jos
echo rh002 > /var/qmail/alias/.qmail-rijndersholding.nl-linda

et cetera.

Quote:
See Life with qmail for POP3 and IMAP installation instructions. Using procmail is described above.

I have this working. Just stated it in case it was relevant (thought maybe you would give me reasons for virtual accounts using courier-imap or something else).

Does this all sound good to you? (It doesn't to me, but then again, the one file in sendmail is so easy :/.)

PS. How do I get this forum to not turn e-mail addresses into e-mail links?

Last edited by nednieuws : April 18th, 2004 at 07:18 PM. Reason: Added post scriptum.

Reply With Quote
  #4  
Old April 18th, 2004, 08:10 PM
nednieuws nednieuws is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 70 nednieuws User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 58 sec
Reputation Power: 5
Stop the presses!

In a message sent to the qmail mailing list I see that the virtusertable "equivalency" (non-native english speaker) goes a lot further than I thought. Here's what I actually want qmail to do:

Quote:
# > @wibble.com %1.wibble
# >
# > => deliver mail addressed to someuser@xxxxxxxxxx into the POP3 mailbox
# > someuser.wibble. That is, take the user and add ".wibble" to form the
# > mailbox name.


Unfortunately, the answer is "Look into qmail-users", which is perfectly reasonable. But I can't figure out how. Switching MTA's is harder than I thought it would be .

How can I set this up as a line in /var/qmail/users/assign needs the username/uid/gid of a particular user, so how can it be wildcarded?

Reply With Quote
  #5  
Old April 19th, 2004, 03:09 PM
nednieuws nednieuws is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 70 nednieuws User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 58 sec
Reputation Power: 5
Let's put this on hold...

I've found out where to look and how to do this. But first, it seems my qmail isn't sending or receiving messages. Gotta fix that first...

Reply With Quote
  #6  
Old April 19th, 2004, 04:13 PM
nednieuws nednieuws is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Posts: 70 nednieuws User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 7 m 58 sec
Reputation Power: 5
We're back on track.

LWQ has the delivery set to /Mailbox instead of /Maildir/. There's working past midnight for ya .

Anyway, do I need to add the local domains to /var/qmail/control/virtualdomains also?

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationMail Server Help > qmail equivalent of sendmail's virtmaps


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway