Re: The network init.d wont run at startup



lovecreatesbeauty@xxxxxxxxx wrote:
On Oct 29, 7:38 pm, Bill Marcum <marcumb...@xxxxxxxxxxxxx> wrote:
On 2008-10-29, lovecreatesbea...@xxxxxxxxx <lovecreatesbea...@xxxxxxxxx> wrote:
On the Fedora 10 Beta, the network and samba function are not ready
after startup, unless I issue the following two pieces of command
manually:
$ su -c '/etc/init.d/network restart'
$ su -c '/etc/init.d/smb restart'
Why do these startup scripts fail to run at boot time, and how to
correct it? The dmesg and network-scripts say so:
$ dmesg | grep eth
eth0: registered as PCnet/PCI II 79C970A
$ grep ONBOOT /etc/sysconfig/network-scripts/ifcfg-eth0
ONBOOT=yes
$
You have a set of directories /etc/rc?.d or /etc/init.d/rc?.d, one for
each runlevel. Inside those directories are symbolic links with names
that begin with S or K and a number. You might need to increase the
numbers on the S??network and S??smb links.


The Fedora is started in runlelvel 3. Therer're these startup scripts
shown in the following. Same records exist in /etc/rc5.d/ directory.
Do the files with name beginning with `K' mean the functions aren't
invoked at startup? Do I change the K to S and how to deal with the
two digits following the S letter?

Links that start with K are invoked with the "stop" argument when the level is entered. Links that start with S are invoked with the "start" argument when the level is entered. Use the chkconfig command rather than manually creating links to configure what scripts run at what levels.

$ ls -l /etc/rc3.d/ | grep [Nn]etwork
lrwxrwxrwx 1 root root 17 2008-10-29 01:55 K90network -> ../init.d/
network
lrwxrwxrwx 1 root root 24 2008-10-29 02:12 S27NetworkManager -> ../
init.d/NetworkManager
$ ls -l /etc/rc3.d/ | grep smb
lrwxrwxrwx 1 root root 13 2008-10-29 02:10 K35smb -> ../init.d/smb
$

To see what runs when, you can also use chkconfig.

$ /sbin/chkconfig --list
or
# chkconfig --list

To remove NetworkManager, if that's what you really want to do, as root do:

# rpm -e NetworkManager

but then you'll need to use the network init script. Since you have NetworkManager installed, I'd say that you don't have it configured correctly. It's mostly intended for laptops and choosing between wired and wireless cards, anyway, so you can yank it for a server. I do, although, as I posted before, someday soon we aren't going to be able to avoid it, I think. You might have to yank a few things that depend on it, too, if rpm complains about dependencies. Alternatively to leave it installed and turn it off, as root do:

# chkconfig NetworkManager off

To configure the network init script to start the network (if you remove NetworkManager or turn it off) in runlevels 2, 3, 4, and 5, as root do:

# chkconfig --levels 2345 network on

To configure the smb init script to start sharing (looks like you need to do it, anyway) in runlevels 3, 4, and 5, as root do:

# chkconfig --levels 345 smb on

HTH
.



Relevant Pages

  • Re: ntp woes (and more-general questions about startup and logging)
    ... the script didn't run the "stop" ... Our 10.4 machines are 10.4.7. ... been thinking that the underlying network, ... deny) what traffic (IP + port) goes to what port. ...
    (comp.sys.mac.system)
  • Re: EventID 1054 from Userenv for startup script
    ... The startup script policy: This is a GPO which only contains a ... The "Wait for network" policy: On the server's Default Domain Policy, ...
    (microsoft.public.windows.group_policy)
  • Making FORWARD_IPV4=YES permanent / DHCP multiple routers
    ... I'd like to configure my system to forward ip, to act as a gateway for my network. ... however I want this permanent so I don't have to run the script on startup. ...
    (Fedora)
  • Re: Modelling Complex Sentences
    ... re-inventing the network data model). ... If such as classifying node does not exist, ... Since people complained that dbd's scripts were too long, ... you typically use the CREATE/INSERT commands to ...
    (comp.databases.theory)
  • Re: Request help with simple network
    ... You do need to let DNS queries through the firewall, ... >> well as web browser connections. ... the machines behind the network to get them working (they just had the ... Below is my networking script, I run it *ONCE* on my gateway PC, whenever ...
    (alt.os.linux.redhat)