devoid mailbox status for mail reloaded from a tape backup
Steffen Kaiser
skdovecot at smail.inf.fh-brs.de
Tue Dec 9 16:00:26 UTC 2014
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tue, 9 Dec 2014, Stephen Lidie wrote:
>> On Dec 9, 2014, at 2:34 AM, Steffen Kaiser <skdovecot at smail.inf.fh-brs.de> wrote:
>> On Mon, 8 Dec 2014, Stephen Lidie wrote:
>>
>>> I've only be able to status a mailbox for currently existing users, is
>>> it possible to status a mailbox reloaded from tape to an alternate
>>> location? The user may or may not exist at this time, but I still
^^^^^^
>>> need to inspect the mailbox ... thank you,
>
> Well, although I am able to issue a mailbox status command regardless, the implication was that the command displayed an empty string (nothing useful), and thus a working example using files not in the locations specified by mail_location would be useful. In my configuration mail_locations is defined as:
>
> mail_location = mdbox:~/mail:INDEX=/var/dovecot/index/%u
>
> So a command of the form “doveadm mailbox status -u userName all INBOX” uses mail_location as defined in dovecot.conf to locate the mail and index files, and displays appropriate information about the specified user’s INBOX.
>
> If I have mail and index files in an alternate location - restored from a backup tape for example - how do I obtain data such as unseen, message count, vsize, etc about mailboxes residing at that alternate location, a location not pointed to by mail_location? As I mentioned, “doveadm import” allows one to provide an alternate source location, but “doveadm mailbox status” does not AFAIK, thus, a sample command would be wonderful.
if the user does not exist at all, you could create a dummy "restore"
account, where you restore the data to and can use as any other user.
This would work for any existing user, too.
For me this is working, too:
doveadm -o mail_location=maildir:/home/user2/Maildir mailbox status \
-u user1 all INBOX
shows the same as
doveadm mailbox status -u user2 all INBOX
but not the same as:
doveadm mailbox status -u user1 all INBOX
So, if you craft a good -o mail_location= and an "-u", which has
access permissions on filesystem level (e.g. if you are using system
users), it should work. Maybe, you need to specify "-o home=...", too.
- --
Steffen Kaiser
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQEVAwUBVIccm3z1H7kL/d9rAQJ5sAgAnwLKX+GHvrvdnWOkMfAVl68tamJCZEvw
7tWQCjK7LpcctjiRO7xFVZSKq4OruD6tkU0pnPut6w2sIL8DIhp4lyVBHbuNMA4s
QyA0oLq2tMfEYEiSn8g1G5NpCPnSeo8uFinhHcSAwPWJNo5ly22QHZmZI787olM2
Q7A2insZTvVKLSOe+tcK8SMX05GJLXb5lIRQHj2SkvkmBFiMKI2s6xxakLmEnB4h
3LOFqMoXTmvgGioOtoppZxPJ5jJfUNyGGCfDH7CmKwg6nbUpehf61OdQekCUSoH7
383RgWCW/BUb6ink9nzQDVGLSRCmzT5U0KRZ7nkMobqjuwZ/8L0AMw==
=oNin
-----END PGP SIGNATURE-----
More information about the dovecot
mailing list