Como a opção tipo systemd afeta o início de outras unidades?

1

A página manual systemd.service(5) explica as opções Type para serviços:

Type=

Configures the process start-up type for this service unit. One of simple, forking, oneshot, dbus, notify or idle.

If set to simple (the default if neither Type= nor BusName=, but ExecStart= are specified), it is expected that the process configured with ExecStart= is the main process of the service. In this mode, if the process offers functionality to other processes on the system, its communication channels should be installed before the daemon is started up (e.g. sockets set up by systemd, via socket activation), as systemd will immediately proceed starting follow-up units.

Isso implica para mim que o systemd não iniciará as unidades em paralelo aqui. Também aqui:

If set to forking, it is expected that the process configured with ExecStart= will call fork() as part of its start-up. The parent process is expected to exit when start-up is complete and all communication channels are set up. The child continues to run as the main daemon process. This is the behavior of traditional UNIX daemons. If this setting is used, it is recommended to also use the PIDFile= option, so that systemd can identify the main process of the daemon. systemd will proceed with starting follow-up units as soon as the parent process exits.

Em outras palavras, de acordo com esta man page systemd, executa as unidades de serviço sequencialmente? Então, quando o systemd ativa um processo daemon, ele o aguarda antes de ativar as unidades de acompanhamento? Não faz sentido em tudo.

Como Type afeta o procedimento de inicialização de outras unidades?

    
por direprobs 28.09.2017 / 13:17

0 respostas