A mail account stops sending after many messages in an hour
When a mail account sends many messages, the mail client gets 451 4.7.1 Ratelimit "urbestack_account" exceeded. Rspamd enforces UrbeStack's hourly limits for mail accounts and domains, and you can raise them.
Symptoms
The mail client gets this temporary rejection.
451 4.7.1 Ratelimit "urbestack_account" exceededThe mail log at /var/log/maillog on AlmaLinux or /var/log/mail.log on Ubuntu shows an entry like this for each refused message.
postfix/cleanup[2596]: B643B10BBF2B: milter-reject: END-OF-MESSAGE from server.example.net[127.0.0.1]: 4.7.1 Ratelimit "urbestack_account" exceeded; from=<user@example.com> to=<someone@example.org> proto=ESMTP helo=<server.example.net>Cause
Rspamd enforces UrbeStack's hourly sending limits. The defaults are 100 messages an hour for each mail account and 300 for each domain.
A limit of N messages works as a bucket that holds N messages and refills at N messages an hour. You can send N messages at once, then one more each time the bucket refills enough for another message.
The refusal is temporary. The mail client may try again later.
Resolution
Check the mail trace for the sender. It shows that the
hourly_limitrule fired.urbestack-mail-trace --q user@example.com --dir senderTo raise the hourly limit for one mail account, set it on that account.
urbestack-mail-account-set --address user@example.com --hourly-limit 500To raise the hourly limit for all mail from a domain and the limit for each of its mail accounts, set both limits on the domain.
urbestack-mail-domain-set --name example.com --hourly-limit 1000 --account-hourly-limit 500To change the server defaults for mail accounts and domains without their own limits, use
mail.account_hourly_limitandmail.domain_hourly_limit. This command sets the mail account default to 200 messages an hour.urbestack-setting-set --key mail.account_hourly_limit --value 200If a mail account suddenly sends far more mail than usual, someone may have stolen its password. See A mail account is sending spam.