basic level configuration: non-standard maildir location

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

basic level configuration: non-standard maildir location

David Benfell
Hi all,

I'm trying to move my maildirs to a non-standard location (trying to balance disk activity) and there's something I think I'm missing. Here's what I tried:

home_mailbox = /Maildir/$user/

But when I ran 'postfix check' it said, several times:

/usr/bin/postconf: warning: /etc/postfix/main.cf: undefined parameter: user

What I want is if the recipient is [hidden email] for the mail to be delivered to /Maildir/benfell/

What am I doing wrong?

Thanks!
Reply | Threaded
Open this post in threaded view
|

Re: basic level configuration: non-standard maildir location

Mihira Fernando
On Tue, Aug 6, 2013 at 10:10 AM, David Benfell <[hidden email]> wrote:

>
> Hi all,
>
> I'm trying to move my maildirs to a non-standard location (trying to balance disk activity) and there's something I think I'm missing. Here's what I tried:
>
> home_mailbox = /Maildir/$user/
>
> But when I ran 'postfix check' it said, several times:
>
> /usr/bin/postconf: warning: /etc/postfix/main.cf: undefined parameter: user
>
> What I want is if the recipient is [hidden email] for the mail to be delivered to /Maildir/benfell/
>
> What am I doing wrong?
>
> Thanks!


The home_mailbox parameter works for local shell accounts and its
relative to the user's home folder.
look up the mail_spool_directory parameter. It looks like thats the
one you need to use.

--
The mysteries of the Universe are revealed when you break stuff.
Reply | Threaded
Open this post in threaded view
|

Re: basic level configuration: non-standard maildir location

Stan Hoeppner
On 8/6/2013 1:57 AM, The_Ace wrote:
> On Tue, Aug 6, 2013 at 10:10 AM, David Benfell <[hidden email]> wrote:
>>
>> Hi all,
>>
>> I'm trying to move my maildirs to a non-standard location (trying to balance disk activity) and there's something I think I'm missing. Here's what I tried:
>>
>> home_mailbox = /Maildir/$user/

That's not how it works.  home_mailbox is a relative path within a user
home directory.  Postfix already knows the username, already knows the
path of the user's home directory.  What you specify here gets tacked
onto the home directory path.  I.e.

homedir:
/home/stan

home_mailbox=Maildir/

Maildir style mail is written into

/home/stan/Maildir/

http://www.postfix.org/postconf.5.html#home_mailbox

>> But when I ran 'postfix check' it said, several times:
>>
>> /usr/bin/postconf: warning: /etc/postfix/main.cf: undefined parameter: user
>>
>> What I want is if the recipient is [hidden email] for the mail to be delivered to /Maildir/benfell/

This is a really important point you need to clarify.  Are you wanting
to write different users' mail to different filesystem locations,
different disks?  I.e. David's mail to disk A and Susie's to disk B?  Or
do you want to move everyone's mail to a new location?  Each requires a
different main.cf config.  And if these are system user accounts, not
virtual, then you may not be able to specify storage path on a per user
basis.

> The home_mailbox parameter works for local shell accounts and its
> relative to the user's home folder.
> look up the mail_spool_directory parameter. It looks like thats the
> one you need to use.

This is only valid if he wants to deliver all users' mail to a single
path/location.  It won't work for the per user case.

--
Stan

Reply | Threaded
Open this post in threaded view
|

Re: basic level configuration: non-standard maildir location

/dev/rob0
In reply to this post by Mihira Fernando
On Tue, Aug 06, 2013 at 12:27:04PM +0530, The_Ace wrote:

> On Tue, Aug 6, 2013 at 10:10 AM, David Benfell <[hidden email]>
> wrote:
> > I'm trying to move my maildirs to a non-standard location (trying
> > to balance disk activity) and there's something I think I'm
> > missing. Here's what I tried:
> >
> > home_mailbox = /Maildir/$user/
> >
> > But when I ran 'postfix check' it said, several times:
> >
> > /usr/bin/postconf: warning: /etc/postfix/main.cf: undefined
> > parameter: user
> >
> > What I want is if the recipient is [hidden email] for
> > the mail to be delivered to /Maildir/benfell/
> >
> > What am I doing wrong?
>
> The home_mailbox parameter works for local shell accounts and its
> relative to the user's home folder.
> look up the mail_spool_directory parameter. It looks like thats
> the one you need to use.

Yes. Also note that when using maildir with mail_spool_directory, the
top-level directory must be created in advance; local(8) won't create
them even if filesystem permissions allow; see "note" here:

http://www.postfix.org/postconf.5.html#mail_spool_directory

Another reference which might be of interest is the local(8) manual:

http://www.postfix.org/local.8.html

DELIVERY METHOD CONTROLS lists the precedence of delivery methods.
--
  http://rob0.nodns4.us/ -- system administration and consulting
  Offlist GMX mail is seen only if "/dev/rob0" is in the Subject:
Reply | Threaded
Open this post in threaded view
|

Re: basic level configuration: non-standard maildir location

David Benfell
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 08/06/2013 08:53 AM, /dev/rob0 wrote:

> On Tue, Aug 06, 2013 at 12:27:04PM +0530, The_Ace wrote:
>> On Tue, Aug 6, 2013 at 10:10 AM, David Benfell
>> <[hidden email]> wrote:
>>> I'm trying to move my maildirs to a non-standard location
>>> (trying to balance disk activity) and there's something I think
>>> I'm missing. Here's what I tried:
>>>
>>
>> The home_mailbox parameter works for local shell accounts and
>> its relative to the user's home folder. look up the
>> mail_spool_directory parameter. It looks like thats the one you
>> need to use.
>
> Yes. Also note that when using maildir with mail_spool_directory,
> the top-level directory must be created in advance; local(8) won't
> create them even if filesystem permissions allow; see "note" here:
>
> http://www.postfix.org/postconf.5.html#mail_spool_directory
>
> Another reference which might be of interest is the local(8)
> manual:
>
> http://www.postfix.org/local.8.html
>
> DELIVERY METHOD CONTROLS lists the precedence of delivery methods.
>
Thanks very much guys. I can't dig into all this right now, because it
turns out the reason I was having disk issues that led me to want to
rebalance the load is that I was really having disk issues. :-( I'm in
the process of resolving that right now. ;-)

- --
David Benfell / [hidden email]
Please see https://parts-unknown.org/node/2 for GnuPG information (or
the attachment you don't understand)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJSAUotAAoJELJhbl/uPb4Sj4wP/2JY2tdtRkf+/+PGmscVWfkK
CBOILesoYgwfGB+QAD0i2DYfbUe5IOsAKaCU8Fa9rH423+0xkoQj3HFnViJGSEQW
+s+21w+EyKoHXD5Eslj1v5FqcyfK0tuisu1Zf6zoS6cIExVP2jiot2HiRnicJFzY
4X2GUM5pvDZ/HeOwy0c33dIQ/Ka7VEFLAk617k/mVDPylgfxPAo6ONNV4bssXFvn
reGrnmcqb2dtdHvI5qfamz7/zAL6WzzbznSvk6j4HtZz8SN+r0r2lLl6DWoxrDns
wyKyQ/BHTIb+gc/yF4WbURNnE7UPJrUKRLT8UzEyy6JUnFmqMcuE966Nfdzku+n0
6NL1F029msw5+DBn+snQmkGgdayC9A1cVE+Y8wBbd01hZffDNCI6Sy29FL06pU68
lr4LyjGrJ7sTkOJSpbZGljMpGyALiI+BuRuDtzyO++xfLZHcx0VrIX20WZNtAHjx
GOoVUG2ie6tgTxOxBuVk89nLyYJ+fYm6jQhYpEG9lPiZJbop2cNHb7AB/D14Rfg+
AC5y8s7pq+xhi43I9c9IiP91TkMsCq2uucdbMEgVThqNtSbPabHHeojHcIkYDjVN
AcOtdEnd+sSW2WdVjND00YMY3hkG/GZshFwhOFUpUYPD6w6ii+3kt2kB1bEDyLmV
+bT76mhUx4Jmcy0XHQ91
=HuYE
-----END PGP SIGNATURE-----