Bug 771805

Summary: rc.local doesn't run last (after everything else is booted)
Product: [Fedora] Fedora Reporter: Scott Baker <scott>
Component: systemdAssignee: systemd-maint
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 16CC: johannbg, lpoetter, metherid, mschmidt, notting, plautrba, systemd-maint
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-01-05 10:38:37 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Scott Baker 2012-01-05 02:44:08 UTC
Description of problem:
Traditionally /etc/rc.d/rc.local was run after all other services were started, this isn't the case any more. 

Version-Release number of selected component (if applicable):
systemd-37-3.fc16.x86_64

How reproducible:
Easily

Steps to Reproduce:
1. Create an /etc/rc.d/rc.local file
2. Put "ifconfig -a > /tmp/ifconfig.txt" in it
3. Reboot
  
Actual results:
Ethernet ports don't have IPs assigned when rc.local is run. I'm sure there are other services that start after this, but the network is one that I noticed.

It's worth noting that I have disabled NetworkManager, and am instead using "network".

Expected results:
/etc/rc.d/rc.local is the LAST thing to run after the system is booted up, but before the login prompt is shown. Users who have scripts that expect this behavior, specifically entries that start network services, will encounter problems.

Comment 1 Michal Schmidt 2012-01-05 10:38:37 UTC
We're changing rc-local to run after network.target in bug 754789, because talking to the network seems to be a common use-case.

However, running a service "after everything else" is not directly supported by systemd. Just plan to migrate away from using rc-local. Define your own service unit with whatever minimal dependencies are truly needed.

*** This bug has been marked as a duplicate of bug 754789 ***