DOVEADM-SAVE(1)

πŸ’Œ DOVEADM-SAVE β€” the doveadm-save(1) glow-up

okay so bestie, this is doveadm-save from the Dovecot fam (you know, the manual, part 1 of the doveadm universe) and it's literally just here to yeet emails into someone's mailbox πŸ’– no drama, no fuss, just vibes.


✨ NAME ✨

doveadm-save β€” save an email to a user's mailbox πŸ’Œ


🫢 SYNOPSIS 🫢

doveadm [GLOBAL OPTIONS] save [-S socket_path] -A [-m mailbox] [-U uid]
[-g guid] [-r received-date] [mail-file]

doveadm [GLOBAL OPTIONS] save [-S socket_path] -F file [-m mailbox] [-U
uid] [-g guid] [-r received-date] [mail-file]

doveadm [GLOBAL OPTIONS] save [-S socket_path] --no-userdb-lookup [-m
mailbox] [-U uid] [-g guid] [-r received-date] [mail-file]

doveadm [GLOBAL OPTIONS] save [-S socket_path] -u user [-m mailbox] [-U
uid] [-g guid] [-r received-date] [mail-file]

four whole shapes of the same slay, pick your fighter πŸ’…


🌸 DESCRIPTION 🌸

doveadm save is your little bestie for saving messages. scripts love her, debugging loves her, she's the moment. πŸŽ€

⚠️ important tea: Sieve is NOT invoked for saved messages. she does not run your filters, she does not read your rules. BUT β€” quota is enforced, so don't try anything cute. 😭

🌈 GLOBAL OPTIONS 🌈

the doveadm(1) classics, shared by everybody:

  • -D β€” turns on verbosity and debug messages. the yapper setting fr.
  • -O β€” do not read any config file, just use defaults. the dovecot_storage_version setting defaults to the latest version, but you can override it with -o.
  • -k β€” preserve the entire environment for doveadm, not just the import_environment setting. full send. πŸ”₯
  • -v β€” enables verbosity, including the progress counter. number go up ✨
  • -i instance-name β€” if you're running multiple Dovecot instances, pick the config file based on this instance name. see the instance_name setting for more info.
  • -c config-file β€” read configuration from the given config-file. by default it first reads the config socket, then falls back to /etc/dovecot/dovecot.conf. you can also point this at the config socket of some instance running a compatible version. πŸ‘‘
  • -o setting=value β€” overrides the configuration setting from /etc/dovecot/dovecot.conf and from the userdb with the given value. wanna override multiple settings? just stack the -o option multiple times, no cap. πŸ¦‹

πŸ’… OPTIONS πŸ’…

  • -A β€” if present, the command gets performed for all users. lowkey a warning though: using this with system users from userdb { driver = passwd } is not recommended, because that also contains users with a lower UID than the one configured with the first_valid_uid setting. πŸ™ˆ

when the SQL userdb module is used, make sure the userdb_sql_iterate_query setting matches your database layout.

when using the LDAP userdb module, make sure the userdb_fields setting and the userdb_ldap_iterate_fields setting match your LDAP schema. otherwise doveadm(1) will be unable to iterate over all users. πŸ’€

  • -F file β€” execute the command for all the users in file. similar to the -A option, but instead of getting the list of users from the userdb, they're read from the given file. one username per line, bestie. πŸ“
  • --no-userdb-lookup β€” do not perform a userdb lookup. use the USER environment variable to specify the username instead. πŸŽ€
  • -S socket_path β€” the option's argument is either an absolute path to a local UNIX domain socket, or a hostname and port (hostname:port), in order to connect a remote host via a TCP socket. this lets an administrator execute doveadm(1) mail commands through the given socket. iconic. πŸ”Œ
  • -u user/mask β€” run the command only for the given user. you can also use '*' and '?' wildcards (e.g. -u *@example.org). wild. ⭐
  • -m mailbox β€” store the mail to the specified mailbox instead of INBOX. πŸ“¬
  • -U uid β€” save the mail using the given uid, if possible.
  • -g guid β€” save the mail using the given guid.
  • -r received-date β€” save the mail using the given received-date timestamp. this is in the "human timestamp" format as described by doveadm-search-query(7). πŸ•

🧚 ARGUMENTS 🧚

mail-file

the message data to save. periodt.

  • if mail-file is -, the message is read from stdin (default). πŸ’œ
  • otherwise, mail-file resolves as a file path. πŸ“

πŸ“ EXAMPLE πŸ“

echo "hello, world" | doveadm save -u testuser@testdomain

look at her go 😭 she ATE


😀 REPORTING BUGS 😀

found a bug? don't gatekeep it. report bugs, including doveconf -n output, to the Dovecot Mailing List ⟨dovecot@dovecot.org⟩. info about reporting bugs lives at: ⟨https://dovecot.org/bugreport.html⟩


πŸ‘€ SEE ALSO πŸ‘€


and that's the whole page bestie!! πŸŽ€ source/version f979264, dated April 2026, still signed DOVEADM-SAVE(1) at the bottom like the main character she is. go save some mail, ily, bye πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from