summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/run-postinsts/run-postinsts/run-postinsts.service
Commit message (Collapse)AuthorAgeFilesLines
* run-postinsts: for dpkg/opkg, do not rely on /etc/*-postinstsStefan Agner2018-06-181-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Start opkg/dpkg as soon as the respective package managers status file is present, no matter whether /etc/$pm-postinsts exists. This decouples the implicit link between postinsts scripts in /etc and the package manager: Currently the package manager is only started if those scripts are present, although the package manager does not use those scripts at all! Package managers install their own set of postinst scripts. The behavior when using rpm packages stays the same. Note that using the package managers capability to execute postinst scripts is preferred for good reasons: It makes sure that the package managers database reflects that the packages have been completely installed and configured. This change allows to drop installation of the postinsts scripts when package management is present. This will be done in a separate change. Note: Before commit 5aae19959a44 ("rootfs.py: Change logic to unistall packages") rootfs.py did not install /etc/$pm-postinsts when package management is installed! The change caused YOCTO #8235 which lead to the behavior change of run-postinsts in first place. (From OE-Core rev: 1af421fcf05457223bf271f3951599b6c150cdff) Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* run-postinsts: do not reload daemon configurationMax Krummenacher2017-08-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In case a systemd service disables itself while init is still in its boot sequence the reloading of the service files can be problematic. In that case: It seems that systemd looses the state of .device units, and some services depend on such units (namely serial consoles such as serial-getty@ttymxc0.service). As a result no getty is spawned on the affected serial tty. After a power-cycle the second boot (which does not disable services) succeeds. The following sequence shows this problem: | Jan 09 16:36:28 apalis-t30 systemctl[162]: Removed /etc/systemd/system/sysinit.target.wants/run-postinsts.service. | Jan 09 16:36:28 apalis-t30 systemd[1]: Reloading. | ... | And then the failing one: | Feb 22 15:33:15 apalis-t30 systemd[1]: dev-ttyS0.device: Job dev-ttyS0.device/start timed out. | Feb 22 15:33:15 apalis-t30 systemd[1]: Timed out waiting for device dev-ttyS0.device. | Feb 22 15:33:15 apalis-t30 systemd[1]: Dependency failed for Serial Getty on ttyS0. | Feb 22 15:33:15 apalis-t30 systemd[1]: serial-getty@ttyS0.service: Job serial-getty@ttyS0.service/start failed with result 'dependency'. | Feb 22 15:33:15 apalis-t30 systemd[1]: dev-ttyS0.device: Job dev-ttyS0.device/start failed with result 'timeout'. | Feb 22 15:33:15 apalis-t30 systemd[1]: Reached target Login Prompts. (the time has been updated between this two events, but that does not influence the issue) Using --no-reload in the service file avoids the "Reloading." message above and seems to not cause such issues anymore. Reported-by: Stefan Agner <stefan.agner@toradex.com> (From OE-Core rev: 23b359b6e26d0b17037bf955bd15a16a3fd9ab8f) Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> (cherry picked from commit 4a425d05bac5dcba023b67aa3d726f7e7869404f) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* run-postinsts.service: remove redundant lineChen Qi2014-09-031-1/+0
| | | | | | | | | | The basic.target itself requires sysinit.target, so there's no need to write this redundant line in the run-postinsts unit file. (From OE-Core rev: 28835fcd78fd35db6d3bd7ee2be16904ddf11991) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* run-postinsts: Add systemd service fileRoss Burton2014-01-281-0/+17
This patch mainly adds a systmd service file for run-postinsts, which is started at first boot to run the post-install scripts. Apart from this, this patch also modifies the installation location of run-postinsts to ${sbindir}. This is because this script would be used by both sysvinit and systemd based images. So it's more reasonable to make it locate under ${sbindir}. [YOCTO #5719] (From OE-Core rev: 5933fbef26ffbc8140248ffb28957f36a813054b) Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>