Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make sure all dependencies for scriptlet are installed before executing them #436

Open
ffesti opened this issue Apr 24, 2018 · 3 comments
Open

Comments

@ffesti
Copy link
Contributor

ffesti commented Apr 24, 2018

Right now scriptlets are executed during the installation/removal of the package they are contained in. This is a problem in case of dependency loops as scriptlets are executed while dependencies may not yet be installed. Although the problem is unsolvable in principle delaying the script execution until all files of the loop are put down on disk can make installation more robust and breakage more rare.

@ffesti
Copy link
Contributor Author

ffesti commented Apr 25, 2018

I don't get the difference between inner and outer dependency loops. To be technically correct: RPM nowadays does not detect dependency loops any more but strongly connected components in the relation graph and we would postpone the scripts after all packages of the component have been installed. I only use "dependency loops" as this is the term most people are familiar with.

@cgwalters
Copy link
Contributor

FWIW, in rpm-ostree today we lay out all files before executing scripts. Then we execute all %pre, then %post and %posttrans. Becuase of the %pre -> passwd dependency, we then do chowns after %pre. Also, speaking of dependency loops and scripts...

@pmatilai pmatilai added the RFE label Jun 18, 2018
@ffesti ffesti added this to Needs triage in Ticket Review (Outdated) Mar 3, 2020
@ffesti ffesti moved this from Needs triage to Yes in Ticket Review (Outdated) Mar 5, 2020
@ffesti ffesti removed this from Yes in Ticket Review (Outdated) Jul 14, 2022
@JornUzon
Copy link

when I install dbus-daemon,install dbus-daemon before install shadow.so report useradd and groupadd command not found,and installtion failed. can I add shadow to setup.rpm 'Requires'? or can from rpm to solve this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Backlog
Development

No branches or pull requests

4 participants