# SAMBA - Service will not start without eth0 or ppp0 [SOLVED]

## Richard Morris

Hi,

I've recently got a new laptop that I have installed with gentoo. I'm using the AMD64 2008.0 profile and ~amd64.

I've just installed samba, however I can't get it to start. I get the following errors depending on how I'm connecting to the network:

Connected Wirelessly Only

```

compaq ~ # /etc/init.d/samba start

 * WARNING: samba is scheduled to start when net.eth0, net.ppp0 has started

```

Connected Wired as well

```

compaq ~ # /etc/init.d/samba start

 * WARNING: samba is scheduled to start when net.ppp0 has started

```

I have three network devices configured, a wired network eth0, a wireless network wlan0 and a 3G connection via bluetooth and my phone ppp0. 

All three devices are started by the default runlevel, and netplug is installed too.

```

compaq ~ # rc-update show | grep -e net\\.[a-z][a-z][a-z].

             net.eth0 |      default

             net.ppp0 |      default

            net.wlan0 |      default

```

The init scripts for them are symlinked to net.lo

```

compaq ~ # ls -la /etc/init.d | grep -e net\\.[a-z][a-z][a-z].

lrwxrwxrwx  1 root root     6 Apr 26 16:32 net.eth0 -> net.lo

lrwxrwxrwx  1 root root    18 Jun 19 21:28 net.ppp0 -> net.lo

lrwxrwxrwx  1 root root     6 May 23 10:47 net.wlan0 -> net.lo

```

This has appeared to be reliable and network interfaces are initialized as required, for example net.ppp0 doesn't start dialing the internet unless a network cable isn't connected and a wireless network connection can't be negotiated. What do I need to change so that samba will start with either a wired or wireless network connected?Last edited by Richard Morris on Tue Aug 12, 2008 3:35 pm; edited 1 time in total

----------

## defenderBG

Remove the net.* that you dont need.

If you are to use net.wlan0 (wireless), than remove the other nets (rc-update del net.eth0 net.ppp0)

then restart samba.

The idea behind that script is that you have a server, where the connections are persistent and it should wait until all connections are online and then start.

----------

## richard.scott

It sounds to me like you've installed something like ifplugd that will monitor the link status of a connection and only start services when the link is up.

In theory there's nothing wring with this as it should start the service only when it seens a live interface.

What happens after you try and start samba if you do the following:

```
rjs ~ # ps -edf | grep mbd
```

You should see the following:

```
rjs ~ # ps -edf | grep mbd

root     28099     1  0 14:54 ?        00:00:00 /usr/sbin/smbd -D

root     28103 28099  0 14:54 ?        00:00:00 /usr/sbin/smbd -D

root     28109     1  0 14:54 ?        00:00:00 /usr/sbin/nmbd -D
```

That is if "ifconfig" shows your device as being up then the daemons should be running.

----------

## Richard Morris

Gentlemen, thank you very much for your suggestions and pointing me in the right direction.

After a little more googing and including ifplugd in the search terms too (currently I'm using netplugd, but ifplugd looks a little more useful). I've found that I needed to edit /etc/rc.conf and change 

```

rc_depend_strict="yes"

```

to

```

rc_depend_strict="no"

```

----------

