Re: [Dovecot] Virtual inbox folder bug

2010-11-03 Thread Antonio Henrique Oliveira

On 03-11-2010 10:40, Timo Sirainen wrote:

On 2.11.2010, at 21.50, Antonio Henrique Oliveira wrote:


All of my email is delivered in some folder other than the real inbox via sieve 
scripts.
My inbox is, therefore, a virtual folder, which only displays the unread emails 
on all the folders in the account.

Everything works fine *except* that, when I mark an email as read or when I 
open an email directly on the inbox, it does not disappear from the inbox (as 
it should since it is not unread after being open or being marked as read).


The mail removal is delayed until you issue EXPUNGE command (in TB I guess that's called 
"purge") or reopen the mailbox. Otherwise if the message was immediately 
removed when marked as read, you wouldn't even have a chance to read it before it got 
removed.


I've tried that and it still is not working. I haven't watched the IMAP 
"conversation" between Thunderbird and Dovecot (I'll see if I can do it 
later). I've opened a message directly from the Inbox, asked TB to do a 
"compact" on the folders (which I believe issues an "EXPUNGE" command to 
the imap server) and the mails are still there, marked as read, but 
still showing up on the "virtual" inbox.


Strangely enough, if I access the virtual folder directly the messages 
do not show up there. Maybe it's thunderbird's fault? Can somebody else 
try to reproduce this and see what' happens? Maybe with a different mail 
client.


Regards,
--
Anto'nio Henrique A. Proenca de Oliveira
"Although we can never go back, like an old sweet
song with a strong refrain, memories remain" - (Someone)

Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html
$Id: .signature,v 1.5 2008/03/13 11:22:00 tat Exp tat $


Re: [Dovecot] Virtual inbox folder bug

2010-11-03 Thread Timo Sirainen
On 2.11.2010, at 21.50, Antonio Henrique Oliveira wrote:

> All of my email is delivered in some folder other than the real inbox via 
> sieve scripts.
> My inbox is, therefore, a virtual folder, which only displays the unread 
> emails on all the folders in the account.
> 
> Everything works fine *except* that, when I mark an email as read or when I 
> open an email directly on the inbox, it does not disappear from the inbox (as 
> it should since it is not unread after being open or being marked as read).

The mail removal is delayed until you issue EXPUNGE command (in TB I guess 
that's called "purge") or reopen the mailbox. Otherwise if the message was 
immediately removed when marked as read, you wouldn't even have a chance to 
read it before it got removed.



Re: [Dovecot] Virtual inbox folder bug

2010-11-02 Thread Tobias Daucher
Got the same "problem" with thunderbird... thunderbird wants to be intelligent and caches 
information...
the server would remove the message, but thunderbird says "hey it was not me so i don't anything 
about moving" and reads the message from its cache...
close thunderbird, delete the imapmail folder in your profile, and restart thunderbird => mail is 
gone...
and if you find a way to turn off this fu***ing caching of thunderbird it would be nice to tell it 
to me...

caching sucks with imap and i don't find any option to turn it off...
bye
tobi

Am 02.11.2010 22:50, schrieb Antonio Henrique Oliveira:

Hi all,

I've been using dovecot as our internal mail server for quite some time. It 
works very well. Each of
our mailboxes have 1000+ messages (some have more than 4-5000 messages).

I have recently started using virtual folders and, using an adaptation of an 
example script in the
dovecot site (http://wiki.dovecot.org/Plugins/Virtual), to have a virtual 
folder changed to act as
inbox.

All of my email is delivered in some folder other than the real inbox via sieve 
scripts.
My inbox is, therefore, a virtual folder, which only displays the unread emails 
on all the folders
in the account.

Everything works fine *except* that, when I mark an email as read or when I 
open an email directly
on the inbox, it does not disappear from the inbox (as it should since it is 
not unread after being
open or being marked as read).

I'm not sure if this is a bug, a "feature", or a misconfiguration :)

I'm using dovecot 1.2.13 on Debian Etch (installed using the backports 
repository). Attached is the
file with the output of "dovecot -n", the script for the virtual folder and the 
custom login script
to change the virtual folder to act as the inbox.

I'm using Thunderbird 3.1.6 on Windows XP SP3 as the main mail client and also 
using an Android
phone (Samsung Galaxy) to access the same account.

Regards,



--


Dr. Nagler & Company GmbH
Hauptstraße 9
92253 Schnaittenbach

Tel : 09622-7197-38
Fax : 09622-7197-50
Web : http://www.nagler-company.com
E-Mail : tobias.dauc...@nagler-company.com

Hauptsitz:  Schnaittenbach
Handelregister: Amberg HRB 4653
Gerichtsstand:  Amberg
Steuernummer:   201/118/51825
USt.-ID-Nummer: DE 273143997
Geschäftsführer:Dr. Martin Nagler, Dr. Dr. Karl-Kuno Kunze


[Dovecot] Virtual inbox folder bug

2010-11-02 Thread Antonio Henrique Oliveira

Hi all,

I've been using dovecot as our internal mail server for quite some time. 
It works very well. Each of our mailboxes have 1000+ messages (some have 
more than 4-5000 messages).


I have recently started using virtual folders and, using an adaptation 
of an example script in the dovecot site 
(http://wiki.dovecot.org/Plugins/Virtual), to have a virtual folder 
changed to act as inbox.


All of my email is delivered in some folder other than the real inbox 
via sieve scripts.
My inbox is, therefore, a virtual folder, which only displays the unread 
emails on all the folders in the account.


Everything works fine *except* that, when I mark an email as read or 
when I open an email directly on the inbox, it does not disappear from 
the inbox (as it should since it is not unread after being open or being 
marked as read).


I'm not sure if this is a bug, a "feature", or a misconfiguration :)

I'm using dovecot 1.2.13 on Debian Etch (installed using the backports 
repository). Attached is the file with the output of "dovecot -n", the 
script for the virtual folder and the custom login script to change the 
virtual folder to act as the inbox.


I'm using Thunderbird 3.1.6 on Windows XP SP3 as the main mail client 
and also using an Android phone (Samsung Galaxy) to access the same account.


Regards,
--
Anto'nio Henrique A. Proenca de Oliveira
"Although we can never go back, like an old sweet
song with a strong refrain, memories remain" - (Someone)

Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html
$Id: .signature,v 1.5 2008/03/13 11:22:00 tat Exp tat $
# 1.2.13: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.26-2-686 i686 Debian 5.0.6 
log_timestamp: %Y-%m-%d %H:%M:%S 
protocols: imap imaps managesieve
ssl_listen(default): *:993
ssl_listen(imap): *:993
ssl_listen(managesieve): 
ssl_cert_file: /etc/ssl/HIHCA/certs/mail.cer
ssl_key_file: /etc/ssl/HIHCA/private/mail.key
disable_plaintext_auth: no
shutdown_clients: no
login_dir: /var/run/dovecot/login
login_executable(default): /usr/lib/dovecot/imap-login
login_executable(imap): /usr/lib/dovecot/imap-login
login_executable(managesieve): /usr/lib/dovecot/managesieve-login
login_max_processes_count: 256
mail_privileged_group: mail
mbox_write_locks: fcntl dotlock
mail_executable(default): /usr/lib/dovecot/postlogin
mail_executable(imap): /usr/lib/dovecot/postlogin
mail_executable(managesieve): /usr/lib/dovecot/managesieve
mail_plugins(default): lazy_expunge virtual
mail_plugins(imap): lazy_expunge virtual
mail_plugins(managesieve): 
mail_plugin_dir(default): /usr/lib/dovecot/modules/imap
mail_plugin_dir(imap): /usr/lib/dovecot/modules/imap
mail_plugin_dir(managesieve): /usr/lib/dovecot/modules/managesieve
imap_client_workarounds(default): outlook-idle netscape-eoh
imap_client_workarounds(imap): outlook-idle netscape-eoh
imap_client_workarounds(managesieve): 
imap_logout_format(default): 
imap_logout_format(imap): 
imap_logout_format(managesieve): bytes=%i/%o
namespace:
  type: private
  separator: /
  inbox: yes
  list: yes
  subscriptions: yes
namespace:
  type: private
  separator: /
  prefix: .EXPUNGED/
  location: maildir:~/deleted-mail/expunged
  hidden: yes
  list: no
  subscriptions: yes
namespace:
  type: private
  separator: /
  prefix: .DELETED/
  location: maildir:~/deleted-mail/deleted
  hidden: yes
  list: no
  subscriptions: yes
namespace:
  type: private
  separator: /
  prefix: .DELETED/.EXPUNGED/
  location: maildir:~/deleted-mail/deleted/expunged
  hidden: yes
  list: no
  subscriptions: yes
namespace:
  type: private
  separator: /
  prefix: virtual/
  location: virtual:~/virtual-mail
  hidden: yes
  list: yes
  subscriptions: yes
namespace:
  type: private
  separator: /
  prefix: real/
  hidden: yes
  list: no
  subscriptions: yes
lda:
  postmaster_address: postmas...@homesinheaven.net
  sendmail_path: /usr/lib/sendmail
  auth_socket_path: /var/run/dovecot/auth-master
  mail_plugins: sieve virtual
auth default:
  passdb:
driver: pam
  userdb:
driver: passwd
plugin:
  lazy_expunge: .EXPUNGED/ .DELETED/ .DELETED/.EXPUNGED/
#!/bin/sh
# AUTOMATICALLY CREATE virtual DIRECTORY
#
# assumes NAMESPACE_1 is your normal mail, NAMESPACE_2
# is virtual.  ${NAMESPACE_2} contains the directory
# we need to create but in an inconvenient format, so
# here we assume it's $HOME/Maildir/virtual

export VIRTUAL=$HOME/virtual-mail

if [ ! -d "$VIRTUAL" ]; then
# su to get right ownership
su $USER -c 'mkdir -m 700 -p "$VIRTUAL"'
fi

# AUTOMATICALLY VIRTUALIZE INBOX
#
# If the user creates a virtual/INBOX/dovecot-virtual,
# switch the inbox to the virtual namespace.

if [ -s "${VIRTUAL}/INBOX/dovecot-virtual" ]; then
unset NAMESPACE_1_INBOX
export NAMESPACE_5_INBOX=1
fi

exec /usr/lib/dovecot/imap "$@"
real/*
  (unseen)