Hello,

I'm currently researching how services work within Dovecot and what scope these services are capable of. For example, I created a service as such:

service myservice {
  executable = /home/me/executable
  type          = worker
  unix_listener myservice {
    mode = 0666
  }
}


When data is provided to the myservice unix socket, Dovecot appears to create a new process by executing "/home/me/executable". I found out about "status updates" through examining the logs. At first I received this:

master: Error: service(myservice): Initial status notification not received in 30 seconds, killing the process

What is this status notification?

I found out that writing to file descriptor 5 from the executable does seem to be valid. When I write out 12 bytes I don't get an error, but when I write out 13 bytes I get the following:

master: Error: service(dmon): service sent partial status update (13 bytes)

What I've also noticed is that exiting 0 will cause Dovecot to spawn the process again, in what appears to be infinitely.

Are there any resources/documentation that I could reference to learn more about how services work on a lower level besides just looking at the source code?

Thanks.

Reply via email to