Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 563720 - openrc cache not updated after removal of init.d/ symlink (scripts continue to reference old NIC name as dep even after many reboots)
Summary: openrc cache not updated after removal of init.d/ symlink (scripts continue t...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: OpenRC (show other bugs)
Hardware: All Linux
: Normal critical (vote)
Assignee: OpenRC Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-21 20:25 UTC by far jump
Modified: 2016-08-15 20:42 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (veirsmill.info,4.88 KB, application/x-info)
2015-10-21 20:28 UTC, far jump
Details
dhcpd.conf (dhcpd.conf,1.04 KB, text/plain)
2015-10-21 20:47 UTC, far jump
Details
netmount.conf (netmount.conf,1.98 KB, text/plain)
2015-10-21 20:47 UTC, far jump
Details
0001-savecache-stop-saving-nettree.patch (0001-savecache-stop-saving-nettree.patch,830 bytes, text/x-diff)
2015-10-26 13:58 UTC, William Hubbs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description far jump 2015-10-21 20:25:39 UTC
Kernel: Linux VeirsMill_III 3.17.7-gentoo #1 SMP Sun Jan 18 09:45:41 EST 2015 x86_64 AMD Phenom(tm) II X6 1100T Processor AuthenticAMD GNU/Linux

running for over 4 years.  We replaced NIC which was named enp0s8, the new NIC is enp2s0.  Edited /etc/conf.d/net and linked net.enp2s0 to net.lo. (there are no rules in /etc/udev/rules.d/) New NIC works perfectly.  However, a bunch of init.d scripts will not start as they are looking for the old NIC.  Example:

>/etc/init.d/dhcpd start
 * ERROR: cannot start dhcpd as net.enp0s8 would not start


>rc-status
Runlevel: default
 lm_sensors                                       [  started  ]
 syslog-ng                                        [  started  ]
 consolekit                                       [  started  ]
 net.enp2s0                                       [  started  ]
 netmount                                         [  started  ]
 xdm                                              [  started  ]
 ntp-client                                       [  started  ]
 ntpd                                             [  started  ]
 cupsd                                            [  started  ]
 nfs                                              [  started  ]
 screenEZ                                         [  started  ]
 dhcpd                                            [  started  ]
 sshd                                             [  started  ]
 vixie-cron                                       [  started  ]
 in.tftpd                                         [  started  ]
 denyhosts                                        [  started  ]
 postgresql-9.3                                   [  started  ]
 local                                            [  started  ]
Dynamic Runlevel: hotplugged
Dynamic Runlevel: needed
 dbus                                             [  started  ]
 rpc.pipefs                                       [  started  ]
 rpcbind                                          [  started  ]
 rpc.statd                                        [  started  ]
 xdm-setup                                        [  started  ]
 rpc.idmapd                                       [  started  ]
Dynamic Runlevel: manual
Comment 1 far jump 2015-10-21 20:28:03 UTC
Created attachment 415118 [details]
emerge --info
Comment 2 Ian Stakenvicius (RETIRED) gentoo-dev 2015-10-21 20:31:04 UTC
Please attach /etc/conf.d/dhcpd and the conf.d's for any other init script that wants the old iface started.
Comment 3 Ian Stakenvicius (RETIRED) gentoo-dev 2015-10-21 20:36:05 UTC
Also please confirm that "rc-update -a" doesn't show a net.enp0s8 service in any runlevel, if it does be sure to "rc-update del net.enp0s8 [runlevel]"
Comment 4 far jump 2015-10-21 20:47:27 UTC
Created attachment 415124 [details]
dhcpd.conf
Comment 5 far jump 2015-10-21 20:47:51 UTC
Created attachment 415126 [details]
netmount.conf
Comment 6 far jump 2015-10-21 20:56:34 UTC
Yes I did rc-update del net.enp0s8 [runlevel] for all runlevels (I can send you a ls -l of /etc/runlevels if you wish

>rc-update -a
             bootmisc | boot                         
           consolekit |      default                 
                cupsd |      default                 
            denyhosts |      default                 
                devfs |                       sysinit
                dhcpd |      default                 
                dmesg |                       sysinit
                 fsck | boot                         
             hostname | boot                         
              hwclock | boot                         
             in.tftpd |      default                 
              keymaps | boot                         
            killprocs |              shutdown        
    kmod-static-nodes |                       sysinit
           lm_sensors |      default                 
                local |      default                 
           localmount | boot                         
             loopback | boot                         
              modules | boot                         
             mount-ro |              shutdown        
                 mtab | boot                         
           net.enp2s0 |      default                 
             netmount |      default                 
                  nfs |      default                 
           ntp-client |      default                 
                 ntpd |      default                 
       postgresql-9.3 |      default                 
               procfs | boot                         
                 root | boot                         
            savecache |              shutdown        
             screenEZ |      default                 
                 sshd |      default                 
                 swap | boot                         
            swapfiles | boot                         
               sysctl | boot                         
                sysfs |                       sysinit
            syslog-ng |      default                 
         termencoding | boot                         
         tmpfiles.dev |                       sysinit
       tmpfiles.setup | boot                         
                 udev |                       sysinit
              urandom | boot                         
           vixie-cron |      default                 
                  xdm |      default
Comment 7 Ian Stakenvicius (RETIRED) gentoo-dev 2015-10-21 21:09:02 UTC
Ok, so the last thing I can think of is that there's a bad openrc cache that needs updating.  Please try rc-update -u to reset it.  

If that doesn't work, we'll need to step you through some openrc debug logging.
Comment 8 Ian Stakenvicius (RETIRED) gentoo-dev 2015-10-21 21:11:55 UTC
Oh, one final possibility -- check /etc/rc.conf and see if there might be an rc_provide_net= or anything else that mentions the old iface name.
Comment 9 far jump 2015-10-21 21:31:16 UTC
(In reply to Ian Stakenvicius from comment #7)
> Ok, so the last thing I can think of is that there's a bad openrc cache that
> needs updating.  Please try rc-update -u to reset it.  
> 
> If that doesn't work, we'll need to step you through some openrc debug
> logging.

rc-update -u seems to have worked.  (I have not rebooted the system to test)

After removing all references to net.enp0s8, wouldn't rebooting the system have that same effect?  (I rebooted twice trying to figure out what was going on)

thanks
Comment 10 William Hubbs gentoo-dev 2015-10-26 13:58:37 UTC
Created attachment 415522 [details]
0001-savecache-stop-saving-nettree.patch

All,

This patch reflects a change that should have been made to OpenRC when
netifrc was split out but wasn't which might be related to this bug.

I want to apply it on the master branch, which would make it affective
in OpenRC-0.19.

Can I have some netifrc users let me know if this causes any surprises?
Comment 11 William Hubbs gentoo-dev 2016-01-28 23:22:35 UTC
https://github.com/openrc/openrc/commit/e52b5f5

This commit is now on the master branch and will be included in
OpenRC-0.21.