Re: Multiple servers and NFS

2014-07-29 Thread Nick Edwards
On 7/29/14, Daniel Parthey  wrote:
> Nick Edwards wrote:
>> On 7/26/14, Robert Schetterer  wrote:
>> > Am 25.07.2014 um 16:12 schrieb Eduardo Ramos:
>> >> I did not understand what the advantage of use dovecot LMTP with
>> >> director too.
>> >
>> > in "very short" words...
>> > with nfs ,the director should avoid concurrent events
>> > which may happen with lmtp too, depending to multiple server setup
>>
>> using director was considered in risk assessment as its another point
>> of failure, and weighed against its claimed benefit, the decision was
>> made its not justified.
>>
>> mail_location = maildir:/mail/%1n/%1.1n/%2.1n/%n/Maildir:INDEX=MEMORY
>
> With maildir you won't have data-loss without the director,
> since the index files are auto-regenerated without any problem.
>

disagree, if we'd had data loss we would have a case to use director,
we also had none when we were using qmail and vpopmail, if dovecot
did, and as said we are yet to see it, but if it did have data loss,
than thats dovecots design issue, but I have no doubt it is that much
of an issue.

and from memory the only difference is some messages that just arrive
may or may not appear immediately, this is only a problem with imap,
and of all the users, we have a some total of about 200 that bother
with imap, the other 100K plus use pop3

> With mdbox on NFS and no director, you will have data-loss sooner or later:

irrelevant, we use Maildir, it is time proved.
>
>


Re: Multiple servers and NFS

2014-07-28 Thread Daniel Parthey
Nick Edwards wrote:
> On 7/26/14, Robert Schetterer  wrote:
> > Am 25.07.2014 um 16:12 schrieb Eduardo Ramos:
> >> I did not understand what the advantage of use dovecot LMTP with
> >> director too.
> >
> > in "very short" words...
> > with nfs ,the director should avoid concurrent events
> > which may happen with lmtp too, depending to multiple server setup
> 
> using director was considered in risk assessment as its another point
> of failure, and weighed against its claimed benefit, the decision was
> made its not justified.
> 
> mail_location = maildir:/mail/%1n/%1.1n/%2.1n/%n/Maildir:INDEX=MEMORY

With maildir you won't have data-loss without the director,
since the index files are auto-regenerated without any problem.

With mdbox on NFS and no director, you will have data-loss sooner or later:

http://wiki2.dovecot.org/MailboxFormat/dbox


One of the main reasons for dbox's high performance is that it uses Dovecot's
index files as the only storage for message flags and keywords, so the indexes
don't have to be "synchronized". Dovecot trusts that they're always up-to-date
(unless it sees that something is clearly broken). This also means that you
must not lose the dbox index files, they can't be regenerated without data
loss.


Regards
Daniel


Re: Multiple servers and NFS

2014-07-28 Thread Timo Sirainen
On 24 Jul 2014, at 20:09, Nathan Schultheiss  wrote:

> When I go on Roundcube with a mailbox who I've 96000 in the INBOX "cur" 
> folder, the first time I need 1 minutes waiting.
> The second time it's a little more quick 10 seconds... But when I go back 
> again (after a few hours) it's slow again... And we'are just 5 users at the 
> moment for test...

See if maildir_very_dirty_syncs=yes helps.


Re: Multiple servers and NFS

2014-07-28 Thread Robert Schetterer
Am 28.07.2014 um 13:09 schrieb Nick Edwards:
> On 7/26/14, Robert Schetterer  wrote:
>> Am 25.07.2014 um 16:12 schrieb Eduardo Ramos:
>>> I did not understand what the advantage of use dovecot LMTP with
>>> director too.
>>
>> in "very short" words...
>> with nfs ,the director should avoid concurrent events
>> which may happen with lmtp too, depending to multiple server setup
>>
> 
> A few of us run large NFS based systems without director, however
> mostly 99% pop3, not using director on imap has little impact either
> from our tests, remember, director is only a couple years at most old,
> people have been doing NFS mailstorage for decades, and with relation
> to dovecot, ten years or so, the sky never collapsed back then, it
> hasnt now either thus far :->
> using director was considered in risk assessment as its another point
> of failure, and weighed against its claimed benefit, the decision was
> made its not justified.
> 
> note: we dont use lmtp, each mx mounts/stores directly to EMC storgage
> with dovecot-lda, 14 front ends = 14 direct storages, sure, means
> dovecot needs to be installed on each mx (but not listening), but it
> eliminates the need for dedicated back ends to send to, each mx is
> that backend.
> 
> 12 pop3 servers, of note however, we use index:memory on pop3 and smtp's
> 
> mail_location = maildir:/mail/%1n/%1.1n/%2.1n/%n/Maildir:INDEX=MEMORY
> 
> only 3 imaps one of which is webmail, and of course we do not use
> index:memory on them, these are behind real (serveriron's) load
> balancers, so if using pretend load balancers :-> YMMV
> 

That looks fine
but now whats the problem ?
For sure there are many ways to goal. do what you like.
I also have no director setup using cluster file systems with
loadbalancers working fine.


Best Regards
MfG Robert Schetterer

-- 
[*] sys4 AG

http://sys4.de, +49 (89) 30 90 46 64
Franziskanerstraße 15, 81669 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer
Aufsichtsratsvorsitzender: Florian Kirstein


Re: Multiple servers and NFS

2014-07-28 Thread Nick Edwards
On 7/26/14, Robert Schetterer  wrote:
> Am 25.07.2014 um 16:12 schrieb Eduardo Ramos:
>> I did not understand what the advantage of use dovecot LMTP with
>> director too.
>
> in "very short" words...
> with nfs ,the director should avoid concurrent events
> which may happen with lmtp too, depending to multiple server setup
>

A few of us run large NFS based systems without director, however
mostly 99% pop3, not using director on imap has little impact either
from our tests, remember, director is only a couple years at most old,
people have been doing NFS mailstorage for decades, and with relation
to dovecot, ten years or so, the sky never collapsed back then, it
hasnt now either thus far :->
using director was considered in risk assessment as its another point
of failure, and weighed against its claimed benefit, the decision was
made its not justified.

note: we dont use lmtp, each mx mounts/stores directly to EMC storgage
with dovecot-lda, 14 front ends = 14 direct storages, sure, means
dovecot needs to be installed on each mx (but not listening), but it
eliminates the need for dedicated back ends to send to, each mx is
that backend.

12 pop3 servers, of note however, we use index:memory on pop3 and smtp's

mail_location = maildir:/mail/%1n/%1.1n/%2.1n/%n/Maildir:INDEX=MEMORY

only 3 imaps one of which is webmail, and of course we do not use
index:memory on them, these are behind real (serveriron's) load
balancers, so if using pretend load balancers :-> YMMV


Re: Multiple servers and NFS

2014-07-25 Thread Robert Schetterer
Am 25.07.2014 um 16:12 schrieb Eduardo Ramos:
> I did not understand what the advantage of use dovecot LMTP with
> director too.

in "very short" words...
with nfs ,the director should avoid concurrent events
which may happen with lmtp too, depending to multiple server setup

Best Regards
MfG Robert Schetterer

-- 
[*] sys4 AG

http://sys4.de, +49 (89) 30 90 46 64
Franziskanerstraße 15, 81669 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer
Aufsichtsratsvorsitzender: Florian Kirstein


Re: Multiple servers and NFS

2014-07-25 Thread Eduardo Ramos

Hi Richard,

I think its better balance with a router too. Is there any problem with 
use postfix+amavis in the front-end? I did not understand what the 
advantage of use dovecot LMTP with director too.



On 07/25/2014 01:58 AM, Richard Hector wrote:

On 25/07/14 15:30, Eduardo Ramos wrote:

Hi Richard,

In fact I thought it a little confusing. I had some bad experience with
DNS RR when one of my IMAP server got down. Clients continued trying
connect to broken server and it caused some problems. But when
everything is ok, it works well.

I drew a diagram with my idea. What do you think?

https://dl.dropboxusercontent.com/u/41373531/mail.png

Interesting, thanks. I'd forgotten to draw in the director ring.

As I said, if we need load balancing we can do that on the router, which
as I understand it will do more or less the same thing as LVS. It might
be Cisco SLB, but I'm not sure; I'm not the router guy :-)

But what interests me most is that your diagram shows the mx servers
connecting directly to the backend servers, rather than going through
the proxy director - I thought that was a no-no. Oh, and I don't think
we want to load down our front-end MX servers with amavis, either.

Thanks for your input :-)

Richard


Re: Multiple servers and NFS

2014-07-24 Thread Richard Hector
On 25/07/14 15:30, Eduardo Ramos wrote:
> Hi Richard,
> 
> In fact I thought it a little confusing. I had some bad experience with
> DNS RR when one of my IMAP server got down. Clients continued trying
> connect to broken server and it caused some problems. But when
> everything is ok, it works well.
> 
> I drew a diagram with my idea. What do you think?
> 
> https://dl.dropboxusercontent.com/u/41373531/mail.png

Interesting, thanks. I'd forgotten to draw in the director ring.

As I said, if we need load balancing we can do that on the router, which
as I understand it will do more or less the same thing as LVS. It might
be Cisco SLB, but I'm not sure; I'm not the router guy :-)

But what interests me most is that your diagram shows the mx servers
connecting directly to the backend servers, rather than going through
the proxy director - I thought that was a no-no. Oh, and I don't think
we want to load down our front-end MX servers with amavis, either.

Thanks for your input :-)

Richard


Re: Multiple servers and NFS

2014-07-24 Thread Eduardo Ramos

Hi Richard,

In fact I thought it a little confusing. I had some bad experience with 
DNS RR when one of my IMAP server got down. Clients continued trying 
connect to broken server and it caused some problems. But when 
everything is ok, it works well.


I drew a diagram with my idea. What do you think?

https://dl.dropboxusercontent.com/u/41373531/mail.png

On 07/24/2014 09:25 PM, Richard Hector wrote:

On 25/07/14 09:12, Richard Hector wrote:

Rather than trying to draw increasingly complex diagrams in ASCII, I've
put some here (without the LVS layer):
https://walnut.gen.nz/mail-architectures.png


I've come up with a revised plan - I think we can do without LVS; SMTP 
should just work with multiple MX records, and IMAP/POP should be fine 
as well with RRDNS - the machines should be up most of the time, and 
if a customer has to click to reconnect every now and then on the rare 
occasions when they're not it's not a huge deal. Otherwise, we could 
also do load balancing on our routers.


Anyway - any comments on the sanity of this diagram most welcome :-)

https://walnut.gen.nz/mail-architecture-2.png

Richard


Re: Multiple servers and NFS

2014-07-24 Thread Richard Hector

On 25/07/14 09:12, Richard Hector wrote:

Rather than trying to draw increasingly complex diagrams in ASCII, I've
put some here (without the LVS layer):
https://walnut.gen.nz/mail-architectures.png


I've come up with a revised plan - I think we can do without LVS; SMTP 
should just work with multiple MX records, and IMAP/POP should be fine 
as well with RRDNS - the machines should be up most of the time, and if 
a customer has to click to reconnect every now and then on the rare 
occasions when they're not it's not a huge deal. Otherwise, we could 
also do load balancing on our routers.


Anyway - any comments on the sanity of this diagram most welcome :-)

https://walnut.gen.nz/mail-architecture-2.png

Richard


Re: Multiple servers and NFS

2014-07-24 Thread Richard Hector

On 25/07/14 00:01, Eduardo Ramos wrote:

You can use one or more instances of Dovecot on the same machine, as you
can see here (http://wiki2.dovecot.org/RunningDovecot) "Running Multiple
Invocations of Dovecot".

The problem with DNS round-robind is that if you server goes down, DNS
continues resolving for it. I would recommend use some balancer like
LVS+keepalived.

Consider that multi layer solution:

| LVS + keepalived || LVS + keepalived |

  ||
   --   --
   | Director 1 |   | Director 2 |
   --   --
  ||
  -   -
  | IMAP/POP/LMTP |   | IMAP/POP/LMTP |
  |Backend|   |Backend|
  -   -
  \/
   \  /
\    /
 ---|  NetAPP  |-



Thanks.

Presumably each LVS (in VRRP setup?) has to talk to both directors, and 
the directors each have to talk to both backends. ASCII art is tricky :-)


I accept that I could run multiple dovecots on the same machine, true. 
And keepalived/LVS is a good plan, thanks.


The key point I wanted to confirm is that I need to run the lmtpds on 
the same set of backend machines as the imapd/popds, and behind the same 
directors, so that all sessions relating to the same user can be 
directed to the same backend. Correct?


Rather than trying to draw increasingly complex diagrams in ASCII, I've 
put some here (without the LVS layer): 
https://walnut.gen.nz/mail-architectures.png


I suspect that A is what I need, though the docs suggest that if I turn 
off writing of index files in lmtp, I could get away with one of the 
others, right? What disadvantages are there in that? One concern is the 
ability to scale up to more servers for some particular parts of the 
chain as load dictates - we're concerned that amavis might be a 
significant candidate. I assume amavis could go either in front of or 
behind the director.


Thanks,
Richard


Re: Multiple servers and NFS

2014-07-24 Thread Stan Hoeppner
On 7/24/2014 12:09 PM, Nathan Schultheiss wrote:
...
> |> Mail it's stored in MailDir format "mail_location = maildir:%h"
> 
> When I go on Roundcube with a mailbox who I've 96000 in the INBOX "cur" 
> folder, the first time I need 1 minutes waiting.
> The second time it's a little more quick 10 seconds... But when I go back 
> again (after a few hours) it's slow again... And we'are just 5 users at the 
> moment for test...

This is a caching problem, not an NFS problem.
See /etc/roundcube/main.inc.php

// enable caching of messages and mailbox data in the local database.
// this is recommended if the IMAP server does not run on the same
// machine
$rcmail_config['enable_caching'] = FALSE;

Change that to TRUE.  You will also need a database configured on the RC
host, such as sqlite or mysql.


Cheers,

Stan


Re: Multiple servers and NFS

2014-07-24 Thread Nathan Schultheiss
Hello Eduardo,

Thank for your reply.

2 days ago I've try to setup the "INDEX" and "CONTROL" file on my local 
Harddrive (outside the NFS who the maildir it's stored).

That was my config line:
maildir:%h:INDEX=/opt/dovecot/indexes/%u:CONTROL=/opt/dovecot/indexes/%u

But that was allway slow on the first access, I've think the "cache" expire 
after 1h for example and Dovecot need make a new "cache" after and that's the 
reason why the first access need 60 sec. and the next access need just 10 sec.

I've read the dovecot doku, she's really more clear that postfix doku... really 
:)
It's easy to read it and understand the doc because we learn step by step and 
when we're in one step we learn everything about it and don't need to go in 
another section and come back again for finish the step...

Now I think my config (NFS mount/options) it's just a little poor and that's 
the reason why it's slow.

Bests Regards,
Nathan

- Mail original -
De: "Eduardo Ramos" 
À: dovecot@dovecot.org
Envoyé: Jeudi 24 Juillet 2014 19:27:50
Objet: Re: Multiple servers and NFS

Hi Nathan!

I think you can consider about your index files. By default dovecot 
stores index files in mailbox, but you can define another location. 
Local disk could be better choice. Take I look at this:

http://wiki2.dovecot.org/MailLocation
http://wiki2.dovecot.org/MailLocation/SharedDisk
http://wiki2.dovecot.org/IndexFiles

I think it will help you.

On 07/24/2014 02:09 PM, Nathan Schultheiss wrote:
> Hi Eduardo,
>
> Since I few day I try to setup this config 2, but I've really problem with 
> the NFS.
>
> We come from Google Apps :) I several people on the hospital have large 
> mailbox.
> For example 96000 mails in the INBOX folder, when I do "ls" that is quick for 
> display mail, but with dovecot... I need wait 1 minuts the first time and 
> after display the amount of mail it's quick.
>
> We don't have NetAPP, we've Dell Equallogic with SATA2 7200rpm, gigabits 
> ports.
> The Equallogic it's just for store email, and index file.
>
> My config:
>
> Dell Equallogic
> |-> VMWare ESXI (iscsi mount in VMware with VMWare VMFS 5 format 4To)
> |--> Mounted as slave disk on a VM Ubuntu and exported with this options 
> "(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,async)" and 
> formated as ReiserFS (I've read it's the best for many small files).
> |---> My 2 Dovecot Backend mount the NFS (fstab) to my previous VM with this 
> options "nfs  defaults  0  0"
> |> Mail it's stored in MailDir format "mail_location = maildir:%h"
>
> When I go on Roundcube with a mailbox who I've 96000 in the INBOX "cur" 
> folder, the first time I need 1 minutes waiting.
> The second time it's a little more quick 10 seconds... But when I go back 
> again (after a few hours) it's slow again... And we'are just 5 users at the 
> moment for test...
>
> I've not setup director for the moment I try first dovecot on my lab befor 
> add director and move mailbox from Google...
>
> Have you recommandation for tune or make NFS more quickly, because with 
> Google it's really fast (ok it's google) but if we move to a more slow 
> system, the user on the hospital would no be happy.
> I've try many config, but no really success for have a fast NFS, I don't know 
> if the problem it's VMWARE or if the problem it's just my NFS options.
>
> I'm not pettry good with linux, I'm most good with Windows server, I'm not a 
> good man Google, Microsoft, I know it's devil for every linux sysadmin :)
>
> Thanks,
> Nathan
>
> - Mail original -
> De: "Eduardo Ramos" 
> À: dovecot@dovecot.org
> Envoyé: Jeudi 24 Juillet 2014 14:01:33
> Objet: Re: Multiple servers and NFS
>
> Hi Richard,
>
> You can use one or more instances of Dovecot on the same machine, as you
> can see here (http://wiki2.dovecot.org/RunningDovecot) "Running Multiple
> Invocations of Dovecot".
>
> The problem with DNS round-robind is that if you server goes down, DNS
> continues resolving for it. I would recommend use some balancer like
> LVS+keepalived.
>
> Consider that multi layer solution:
> 
> | LVS + keepalived || LVS + keepalived |
> 
>||
> --   --
> | Director 1 |   | Director 2 |
> --   --
>|   

Re: Multiple servers and NFS

2014-07-24 Thread Nathan Schultheiss
Hallo Patrick,

I've a Dell Equallogic, I make one "volume" with 4 To capacity.
This volume have a iscsi key, I had this key to VMWare for link VMware with 
this "volume".

After on VMware I format this volume with the VMFS5 format, VMware add it 
"Datastore2".

I make a first VM (storage VM) with 2 Hard Drive:
First Hardrive (located in Datastore1) with 20Go capacity, I setup on it the 
ubuntu system.
Second Hardrive (located in Datastore2) with 4To capacity, That's my slave hard 
drive formated in ReiserFS and mounted has /home/vmail
I setup nfs-server service with this options in my "export" file 
(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,async), the 
/home/vmail it's the export point.

I setup now 2 new VM (Dovecot Backend) with just one local Hard Drive (20Go).
After the setup, I install nfs-client and mount /home/vmail to my "storage 
VMAIL".

Dovecot would store mail in /home/vmail/user
I've just 1 domain, it's why I store direct in user directore (ex: 
/home/vmail/nathan.schultheiss ).

The storage VM it's here because I can't mount the ISCSI session on the 2 
Backend server.
I mount this "volume" first on VMWare because it's more easy for manage it and 
setup it on a Virtual Server (my storage server in this case).

It's not impossible that I make a total wrong archi...
But I've think, easy, I mount the ISCSI session on my 2 backend in /home/vmail, 
that work for 1 but not for the second, and I receive many error.
I think Equallogic don't like that 2 Virtual Server wrote on the same time to 
the same ISCSI session.

Freundliche Grüße aus Frankreich,
Nathan


- Mail original -
De: "Patrick Westenberg" 
À: dovecot@dovecot.org
Envoyé: Jeudi 24 Juillet 2014 19:56:26
Objet: Re: Multiple servers and NFS

Nathan Schultheiss schrieb:

> My config:
>
> Dell Equallogic
> |-> VMWare ESXI (iscsi mount in VMware with VMWare VMFS 5 format 4To)
> |--> Mounted as slave disk on a VM Ubuntu and exported with this options 
> "(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,async)" and 
> formated as ReiserFS (I've read it's the best for many small files).
> |---> My 2 Dovecot Backend mount the NFS (fstab) to my previous VM with this 
> options "nfs  defaults  0  0"
> |> Mail it's stored in MailDir format "mail_location = maildir:%h"

I don't understand your setup esp. that your backend servers mount
something from the "previous VM"?

Patrick


Re: Multiple servers and NFS

2014-07-24 Thread Patrick Westenberg

Nathan Schultheiss schrieb:


My config:

Dell Equallogic
|-> VMWare ESXI (iscsi mount in VMware with VMWare VMFS 5 format 4To)
|--> Mounted as slave disk on a VM Ubuntu and exported with this options 
"(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,async)" and formated as 
ReiserFS (I've read it's the best for many small files).
|---> My 2 Dovecot Backend mount the NFS (fstab) to my previous VM with this options 
"nfs  defaults  0  0"
|> Mail it's stored in MailDir format "mail_location = maildir:%h"


I don't understand your setup esp. that your backend servers mount
something from the "previous VM"?

Patrick


Re: Multiple servers and NFS

2014-07-24 Thread Eduardo Ramos

Hi Nathan!

I think you can consider about your index files. By default dovecot 
stores index files in mailbox, but you can define another location. 
Local disk could be better choice. Take I look at this:


http://wiki2.dovecot.org/MailLocation
http://wiki2.dovecot.org/MailLocation/SharedDisk
http://wiki2.dovecot.org/IndexFiles

I think it will help you.

On 07/24/2014 02:09 PM, Nathan Schultheiss wrote:

Hi Eduardo,

Since I few day I try to setup this config 2, but I've really problem with the 
NFS.

We come from Google Apps :) I several people on the hospital have large mailbox.
For example 96000 mails in the INBOX folder, when I do "ls" that is quick for 
display mail, but with dovecot... I need wait 1 minuts the first time and after display 
the amount of mail it's quick.

We don't have NetAPP, we've Dell Equallogic with SATA2 7200rpm, gigabits ports.
The Equallogic it's just for store email, and index file.

My config:

Dell Equallogic
|-> VMWare ESXI (iscsi mount in VMware with VMWare VMFS 5 format 4To)
|--> Mounted as slave disk on a VM Ubuntu and exported with this options 
"(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,async)" and formated as 
ReiserFS (I've read it's the best for many small files).
|---> My 2 Dovecot Backend mount the NFS (fstab) to my previous VM with this options 
"nfs  defaults  0  0"
|> Mail it's stored in MailDir format "mail_location = maildir:%h"

When I go on Roundcube with a mailbox who I've 96000 in the INBOX "cur" folder, 
the first time I need 1 minutes waiting.
The second time it's a little more quick 10 seconds... But when I go back again 
(after a few hours) it's slow again... And we'are just 5 users at the moment 
for test...

I've not setup director for the moment I try first dovecot on my lab befor add 
director and move mailbox from Google...

Have you recommandation for tune or make NFS more quickly, because with Google 
it's really fast (ok it's google) but if we move to a more slow system, the 
user on the hospital would no be happy.
I've try many config, but no really success for have a fast NFS, I don't know 
if the problem it's VMWARE or if the problem it's just my NFS options.

I'm not pettry good with linux, I'm most good with Windows server, I'm not a 
good man Google, Microsoft, I know it's devil for every linux sysadmin :)

Thanks,
Nathan

- Mail original -
De: "Eduardo Ramos" 
À: dovecot@dovecot.org
Envoyé: Jeudi 24 Juillet 2014 14:01:33
Objet: Re: Multiple servers and NFS

Hi Richard,

You can use one or more instances of Dovecot on the same machine, as you
can see here (http://wiki2.dovecot.org/RunningDovecot) "Running Multiple
Invocations of Dovecot".

The problem with DNS round-robind is that if you server goes down, DNS
continues resolving for it. I would recommend use some balancer like
LVS+keepalived.

Consider that multi layer solution:

| LVS + keepalived || LVS + keepalived |

   ||
--   --
| Director 1 |   | Director 2 |
--   --
   ||
   -   -
   | IMAP/POP/LMTP |   | IMAP/POP/LMTP |
   |Backend|   |Backend|
   -   -
   \/
\  /
 \    /
  ---|  NetAPP  |-
 

Remember, directors and backends could run on the same machine. I have a
lab running that way. Maybe I can help you deploy.
On 07/23/2014 07:23 PM, Richard Hector wrote:

Hi all,

For some reason, I didn't go to http://wiki2.dovecot.org/NFS until
now, and I'm starting to get worried ...

The plan was to have multple servers (MXes) receiving mail, and
delivering via LMTP to multiple backend dovecot servers (with amavis
in front of dovecot; LMTP both sides). Then we'd have multiple servers
for clients to use IMAP or POP3.

This is more or less how the system already works, except with Courier
IMAP, and postfix on the backends, delivering to maildirs with procmail.

But with the recommendation to use the Director for both IMAP/POP3 and
LMTP - that starts to sound like I need a whole bunch more servers to
run Directors and proxies, and even then it might not be a good idea
to have different servers running lmtp and imap/pop.

One possible mitigating point is that our 'load balancing' is DNS
round-robin, so a given client will probably stick with a sing

Re: Multiple servers and NFS

2014-07-24 Thread Nathan Schultheiss
Hi Eduardo,

Since I few day I try to setup this config 2, but I've really problem with the 
NFS.

We come from Google Apps :) I several people on the hospital have large mailbox.
For example 96000 mails in the INBOX folder, when I do "ls" that is quick for 
display mail, but with dovecot... I need wait 1 minuts the first time and after 
display the amount of mail it's quick.

We don't have NetAPP, we've Dell Equallogic with SATA2 7200rpm, gigabits ports.
The Equallogic it's just for store email, and index file.

My config:

Dell Equallogic 
|-> VMWare ESXI (iscsi mount in VMware with VMWare VMFS 5 format 4To)
|--> Mounted as slave disk on a VM Ubuntu and exported with this options 
"(rw,no_subtree_check,all_squash,anonuid=1000,anongid=1000,async)" and formated 
as ReiserFS (I've read it's the best for many small files).
|---> My 2 Dovecot Backend mount the NFS (fstab) to my previous VM with this 
options "nfs  defaults  0  0"
|> Mail it's stored in MailDir format "mail_location = maildir:%h"

When I go on Roundcube with a mailbox who I've 96000 in the INBOX "cur" folder, 
the first time I need 1 minutes waiting.
The second time it's a little more quick 10 seconds... But when I go back again 
(after a few hours) it's slow again... And we'are just 5 users at the moment 
for test...

I've not setup director for the moment I try first dovecot on my lab befor add 
director and move mailbox from Google...

Have you recommandation for tune or make NFS more quickly, because with Google 
it's really fast (ok it's google) but if we move to a more slow system, the 
user on the hospital would no be happy.
I've try many config, but no really success for have a fast NFS, I don't know 
if the problem it's VMWARE or if the problem it's just my NFS options.

I'm not pettry good with linux, I'm most good with Windows server, I'm not a 
good man Google, Microsoft, I know it's devil for every linux sysadmin :)

Thanks,
Nathan

- Mail original -
De: "Eduardo Ramos" 
À: dovecot@dovecot.org
Envoyé: Jeudi 24 Juillet 2014 14:01:33
Objet: Re: Multiple servers and NFS

Hi Richard,

You can use one or more instances of Dovecot on the same machine, as you 
can see here (http://wiki2.dovecot.org/RunningDovecot) "Running Multiple 
Invocations of Dovecot".

The problem with DNS round-robind is that if you server goes down, DNS 
continues resolving for it. I would recommend use some balancer like 
LVS+keepalived.

Consider that multi layer solution:

| LVS + keepalived || LVS + keepalived |

  ||
   --   --
   | Director 1 |   | Director 2 |
   --   --
  ||
  -   -
  | IMAP/POP/LMTP |   | IMAP/POP/LMTP |
  |Backend|   |Backend|
  -   -
  \/
   \  /
\    /
 ---|  NetAPP  |-


Remember, directors and backends could run on the same machine. I have a 
lab running that way. Maybe I can help you deploy.
On 07/23/2014 07:23 PM, Richard Hector wrote:
> Hi all,
>
> For some reason, I didn't go to http://wiki2.dovecot.org/NFS until 
> now, and I'm starting to get worried ...
>
> The plan was to have multple servers (MXes) receiving mail, and 
> delivering via LMTP to multiple backend dovecot servers (with amavis 
> in front of dovecot; LMTP both sides). Then we'd have multiple servers 
> for clients to use IMAP or POP3.
>
> This is more or less how the system already works, except with Courier 
> IMAP, and postfix on the backends, delivering to maildirs with procmail.
>
> But with the recommendation to use the Director for both IMAP/POP3 and 
> LMTP - that starts to sound like I need a whole bunch more servers to 
> run Directors and proxies, and even then it might not be a good idea 
> to have different servers running lmtp and imap/pop.
>
> One possible mitigating point is that our 'load balancing' is DNS 
> round-robin, so a given client will probably stick with a single 
> imap/pop server anyway, but if the user has multiple clients 
> (desktop/mobile etc) then they may still hit different servers.
>
> Can someone clarify best practice for a setup needing multiple servers 
> for load balancing and redundancy?
>
> Is Courier already likely to have been suffering these problems?
>
> Oh, the NFS server is a NetApp Filer, if that matters.
>
> I'm using dovecot 2.2.9 from debian wheezy backports, in order to get 
> the quota policy daemon support.
>
> Thanks,
> Richard


Re: Multiple servers and NFS

2014-07-24 Thread Eduardo Ramos

Hi Richard,

You can use one or more instances of Dovecot on the same machine, as you 
can see here (http://wiki2.dovecot.org/RunningDovecot) "Running Multiple 
Invocations of Dovecot".


The problem with DNS round-robind is that if you server goes down, DNS 
continues resolving for it. I would recommend use some balancer like 
LVS+keepalived.


Consider that multi layer solution:

| LVS + keepalived || LVS + keepalived |

 ||
  --   --
  | Director 1 |   | Director 2 |
  --   --
 ||
 -   -
 | IMAP/POP/LMTP |   | IMAP/POP/LMTP |
 |Backend|   |Backend|
 -   -
 \/
  \  /
   \    /
---|  NetAPP  |-
   

Remember, directors and backends could run on the same machine. I have a 
lab running that way. Maybe I can help you deploy.

On 07/23/2014 07:23 PM, Richard Hector wrote:

Hi all,

For some reason, I didn't go to http://wiki2.dovecot.org/NFS until 
now, and I'm starting to get worried ...


The plan was to have multple servers (MXes) receiving mail, and 
delivering via LMTP to multiple backend dovecot servers (with amavis 
in front of dovecot; LMTP both sides). Then we'd have multiple servers 
for clients to use IMAP or POP3.


This is more or less how the system already works, except with Courier 
IMAP, and postfix on the backends, delivering to maildirs with procmail.


But with the recommendation to use the Director for both IMAP/POP3 and 
LMTP - that starts to sound like I need a whole bunch more servers to 
run Directors and proxies, and even then it might not be a good idea 
to have different servers running lmtp and imap/pop.


One possible mitigating point is that our 'load balancing' is DNS 
round-robin, so a given client will probably stick with a single 
imap/pop server anyway, but if the user has multiple clients 
(desktop/mobile etc) then they may still hit different servers.


Can someone clarify best practice for a setup needing multiple servers 
for load balancing and redundancy?


Is Courier already likely to have been suffering these problems?

Oh, the NFS server is a NetApp Filer, if that matters.

I'm using dovecot 2.2.9 from debian wheezy backports, in order to get 
the quota policy daemon support.


Thanks,
Richard


Re: Multiple servers and NFS

2014-07-23 Thread Daniel Parthey
Richard Hector wrote:
> But with the recommendation to use the Director for both IMAP/POP3 and LMTP
> - that starts to sound like I need a whole bunch more servers to run
> Directors and proxies, and even then it might not be a good idea to have
> different servers running lmtp and imap/pop.

Running Multiple Invocations of Dovecot is totally sufficient:

http://wiki2.dovecot.org/RunningDovecot
http://wiki2.dovecot.org/Tools/Doveadm/Instance

Regards
Daniel


Multiple servers and NFS

2014-07-23 Thread Richard Hector

Hi all,

For some reason, I didn't go to http://wiki2.dovecot.org/NFS until now, 
and I'm starting to get worried ...


The plan was to have multple servers (MXes) receiving mail, and 
delivering via LMTP to multiple backend dovecot servers (with amavis in 
front of dovecot; LMTP both sides). Then we'd have multiple servers for 
clients to use IMAP or POP3.


This is more or less how the system already works, except with Courier 
IMAP, and postfix on the backends, delivering to maildirs with procmail.


But with the recommendation to use the Director for both IMAP/POP3 and 
LMTP - that starts to sound like I need a whole bunch more servers to 
run Directors and proxies, and even then it might not be a good idea to 
have different servers running lmtp and imap/pop.


One possible mitigating point is that our 'load balancing' is DNS 
round-robin, so a given client will probably stick with a single 
imap/pop server anyway, but if the user has multiple clients 
(desktop/mobile etc) then they may still hit different servers.


Can someone clarify best practice for a setup needing multiple servers 
for load balancing and redundancy?


Is Courier already likely to have been suffering these problems?

Oh, the NFS server is a NetApp Filer, if that matters.

I'm using dovecot 2.2.9 from debian wheezy backports, in order to get 
the quota policy daemon support.


Thanks,
Richard