# Can't clone iwi0 interface to wlan0 with ifconfig_ within rc.conf



## larrypatrickmaloney (Dec 30, 2009)

I can't get wlan0 to create via rc.conf with:


```
wlans_iwi0="wlan0"
ifconfig_wlan0="WPA DHCP"
```


I CAN clone the interface after rc.conf with:


```
ifconfig wlan0 create wlandev iwi0
```

at a shell prompt.

The wireless networking works fine after that, in fact it works great.

I just want to startup the networking via rc.conf, which appears to be the more correct way to do it.

/etc/defaults/rc.conf has a commented out entry for wlans_ath0, and I assume that works, since most of the postings are for ath0.

However, for sure it's not working for me.

I am running 8.0 kernel (optimized).

Am I doing this correctly?  Any suggestions?

(I've read man wlan and iwi and ifconfig, and this does appear on the surface to be the correct settings in rc.conf

Thank you.

Larry


----------



## egorenar (Jan 8, 2010)

We have exactly the same problem with rt2870 driver and FreeBSD 8.0 amd64. The wlan0 interface is not created automatically at boot time, but it can be created manually without any problems. The driver rt2870 is loaded automatically at boot time.

The relevant piece of rc.conf:


```
wlans_rt28700="wlan0"
create_args_wlan0="wlanmode ap"
ifconfig_wlan0="inet 192.168.111.200 netmask 255.255.255.0 ssid my_ssid mode 11g"
hostapd_enable="YES"
```

If we do it manually then it works:


```
ifconfig wlan0 create wlandev rt28700 wlanmode ap
```

:e :e :e


----------



## donxc (Jan 15, 2010)

I had same problem and ran across the following settings for rc.conf.

```
vaps_ath0="wlan0"
wlans_ath0="wlan0"
ifconfig_wlan0="WPA 192.168.27.15"
```
I don't remember where I found the vaps, seems like it was these forums, but it does take care of things during bootup.

hth


----------



## Alt (Jan 15, 2010)

donxc strange i got working this on ath driver on 8.0-release

```
wlans_ath0="wlan0"
ifconfig_wlan0="WPA DHCP"
```


----------

