Age | Commit message (Collapse) | Author |
|
ok gilles@
|
|
ok gilles
|
|
consistency and clarity. Remove useless and confusing extra byte in
a few arrays based on this define.
ok gilles@
|
|
- replace "users" keyword with "userbase" when providing alternate userbase
- disambiguise expansion nodes when expanding across domains and userbases
- allow use of '=' instead of '=>' when declaring a mapping
ok eric@
|
|
- improve logging of the transfer process
trace by me, logging by eric
|
|
* first bricks of ldap and sqlite support (not finished but both working)
* new table API to replace map API, all lookups are done through tables
* improved handling of temporary errors throughout the daemon
* improved scheduler and mta logic: connection reuse, optimizes batches
* improved queue: more tolerant to admin errors, new layout, less disk-IO
* improved memory usage under high load
* SSL certs/keys isolated to lookup process to avoid facing network
* VIRTUAL support improved, fully virtual setups possible now
* runtime tracing of processes through smtpctl trace
* ssl_privsep.c sync-ed with relayd
* ssl.c no longer contains smtpd specific interfaces
* smtpd-specific ssl bits moved to ssl_smtpd.c
* update mail address in copyright
FLUSH YOUR QUEUE. FLUSH YOUR QUEUE. FLUSH YOUR QUEUE. FLUSH YOUR QUEUE.
smtpd.conf(5) simplified, it will require adaptations
ok eric@
|
|
a simple QOP_WALK queue operation. Some knf and formating fixes while
there.
ok gilles@
|
|
is running. The scheduler sends the runtime state of each envelope to
the queue process which loads the envelope, fills the runtime bits and
sends the envelope back to the client. Iteration over the envelope set
happens in small chunks to make the request interruptible and to allow
the server to keep doing its job in the meantime.
Adpat "smtpctl schedule-all" to schedule the messages one by one using
the same iteration mechanism.
Document "smtpctl monitor" and "smtpctl show queue".
ok gilles@
|
|
the server is running, and flush()/next_message() helpers to make
imsg request/response loops easier.
ok gilles@
|
|
* Log more events (especially client session) and use a better scheme
for that: each messages is prefixed with a token to easily identify
its class:
- info/warn/debug: general server messages
- smtp-in: smtp client connections
- relay: status update for relayed messages
- delivery: status update for local deliveries
* Implement "smtpctl monitor" to display updates of selected internal
counters.
* When reloading the on-disk queue at startup do not commit a message
if no envelope was submitted for that message.
* Remove unused stuff in the config parser.
ok gilles@
|
|
in a human readable fashion:
uptime=123456
uptime.human=1d10h17m36s
ok gilles@
|
|
The idea is to have a file-backed map but to have smtpd(8) cache the maps
so that it cannot be partially read if edited while mail is received. The
file is read and converted to a static map (map_static.c), changes aren't
visible to smtpd until an explicit: smtpctl update map which reads file,
builds a new static map and invalidates the former.
partial-read issue discussed with beck@ and halex@
idea to convert internally to a static map by eric@
diff ok eric@ and chl@
|
|
this allows an admin to inspect the queue without having to manually
extract bucket and find the path to an envelope or message.
diff by Sunil Nimmagadda <sunil@poolp.org>
ok eric@, chl@ and I
|
|
requested by gilles@
|
|
Ignore it in existing envelopes until it gets completely dropped.
Change "smtpctl show queue" to display the address family of the
envelope source instead of the ENQUEUE flag.
ok gilles@
|
|
- remove SHOW_RUNQUEUE it was a noop since runqueues have been removed
years ago from smtpd
|
|
- statistics can now have a type (counter, timestamp, timeval, timespec and
possibly others in the future)
- stat_increment() / stat_decrement() now take an increment/decrement value
and are at the moment only of type counter
- stat_set() now takes a stat_value
- provide helpers to convert raw values to stat_value
ok eric@, ok chl@
while at it fix a rq_queue_dump() call using a bogus timestamp in scheduler
ramqueue.
|
|
ok eric@
|
|
> statistics are no longer static structures in shared memory
> statistics are only set, smtpd never uses them in its logic
> each statistic is a key/value where key can be any (dynamic) string
- convert all uses of the former API to use the new one
- implement stat_ramstat that keeps non-persistent stats in ram structure
ok eric@, ok chl@
|
|
ok gilles@ chl@
|
|
ok gilles@
|
|
longer have them and runner is actually a scheduler so rename.
- introduce scheduler_backend which does the same to scheduler than
queue_backend does to queue and map_backend does to maps
- remove all occurences of RUNNER and runner, replace them with SCHEDULER
and scheduler
ok eric@, ok chl@
|
|
Add a command-line option to specify the backend to use at runtime.
ok gilles@
|
|
internally in fsqueue backend for now, and let the fsqueue_message()
and fsqueue_envelope() dispatchers do the right thing.
Based on a diff by chl@
ok chl@ gilles@
|
|
"smtpctl show" output, and use errx rather than err for the unknown
message error.
ok gilles
|
|
Found by LLVM/Clang Static Analyzer.
ok gilles@
|
|
- introduce the scheduler_ramqueue backend
- remove all occurences of ramqueue outside of the ramqueue backend
- teach runner how to use the new API
it is now possible to write custom schedulers !
ok eric@, ok chl@
|
|
call is issued by smtpd or smtpctl. In the latter case, only perform
sanity checks and do not touch directories. A running server no
longer lose its "incoming/" directory each time smtpctl is called...
ok gilles@
|
|
notify the runner of what happened with an envelope that has been
scheduled. It is not part of the state of the envelope, and it is not
even dumped. So it should only be set by mta/mda, checked by runner
to decide what to do with the envelope, and ignored everywhere else.
ok gilles@
|
|
and confusing.
ok gilles@
|
|
ok eric@
|
|
to smtpctl.c
ok gilles@
|
|
Bug reported by Mark Patruck <mark at wrapped.cx>
ok gilles@ eric@
|
|
queue_backend into account and assumed a filesystem with a specific layout.
This commit does plenty of things:
- make qwalk an abstraction in the queue_backend API, and impose queue
drivers to implement qwalk_open(), qwalk() and qwalk_close();
- move previous qwalk_open(), qwalk() and qwalk_close() to the fsqueue
driver since they were fsqueue specific ...
- make qwalk API work with msgid/evpid instead of pathnames since we're
going to use the queue_backend API to load envelopes by evpid anyway;
- makes smtpd use *solely* the queue_backend API when manipulating the
queue. pathnames were removed from smtpd.h and moved into the fsqueue
which means we can now store a queue anywhere ... as long as we write
the ten functions or so required for a queue driver ;-)
ok eric@, ok chl@
|
|
- rename IMSG and smtpctl pause/resume parameters
- update man page
tested by me, ok chl@, eric@
|
|
- introduce 'smtpctl schedule-all'
ok eric@
|
|
couple of load/dump functions to convert to and from a human readable fmt.
while at it kill struct delivery and merge back its fields to the envelope.
this basically means we shouldn't require users to flush their queues every
time we make a change to struct envelope.
work is not done, but we're at a better state than the binary fsqueue so
we'll improve it in-tree.
has been running on my own box for the last 12 hours or so
ok eric@, chl@
|
|
simpler and hopefully saner way.
ok gilles@ chl@
|
|
ok gilles@
|
|
ok gilles@
|
|
ok gilles@
|
|
for developers to see the impact of structure changes on memory and disk
usage, and useful for users to better understand 'smtpctl show stats'
|
|
improve scheduling and general ramqueue operations. unused yet
|
|
- bring back 'smtpctl schedule' and 'smtpctl remove' to life
Things you should know:
The ramqueue data structure is not finished yet and lacks an envelope tree
for evpid lookups. I wanted to wait until I'm done but too many people are
affected by not being able to reschedule envelopes, this is a quick fix.
So right now there's an O(rrible) complexity as both commands will perform
a (possibly aborted) queue scan leading to O(n). I will make that O(log n)
soon.
Also, smtpctl remove no longer supports removing an entire message, I will
fix that very soon too.
|
|
discussed with and ok gilles@
|
|
no functionnal change
|
|
a continuous walk on the disk-queue. the implementation differs from what
jacekm@ commited (and I backed out) a while ago in that it uses a queue and
a host tree required for upcoming features.
code will be improved in tree, it requires changes to be done in queue and
bounce API, I just wanted to commit a working version first ...
tested by todd@ and I
|
|
ok gilles@
|
|
|
|
|