# Getting sshd to start when I plug in my ethernet cable

## chrisstankevitz

Hi,

How do I setup my gentoo system so that:

a) if my computer boots nearby my wifi it brings up the wireless

b) if my computer is booted without wifi nearby, and later it comes near wifi, it brings up wifi

c) if my computer has ethernet plugged in when it boots, it brings up eth0

d) when (c) happens, sshd is started it if was not already

e) if my computer is booted without ethernet plugged in, and later the cable is plugged in, it brings up eth0

f) when (e) happens, sshd is started if it was not already

I do not get (e) and (f) using my current setup which I produced by following the gentoo handbook (net.eth0 on default, wicd on boot).

Thank you!

Chris

----------

## new_item

Maybe it will be solution:

- configure eth0 with static IP addres.

- change parameter "ListenAddress" in sshd_config to that static addres.

```

ListenAddress 172.16.0.9

```

- add sshd to default runlevel.

----------

