# Cannot connect to wifi,



## sk8harddiefast (Mar 26, 2014)

I finally made it to have my Intel Centrino n 2230 up and running using 11-CURRENT. But for some reason I cannot connect to my wifi.
My wifi is hidden and uses WPA2. This is all my configuration.
/boot/loader.conf

```
if_iwn_load="YES"
wlan_wep_load="YES"
wlan_ccmp_load="YES"
wlan_tkip_load="YES"
```
/etc/rc.conf

```
ifconfig_wlan0="inet 192.168.1.20 netmask 255.255.255.0"
wpa_supplicant_enable="YES"
```
/etc/wpa_supplicant.conf

```
ap_scan=1
fast_reauth=1

network={
scan_ssid=1
ssid="Ember's Network"
proto=RSN
psk=" here I give my password "
priority=1
}
```
`Ifconfig iwn0` is accosiated but I have no access on internet. Any idea how to do it work?


----------



## acheron (Mar 26, 2014)

Do you have a default route defined in /etc/rc.conf?


----------



## sk8harddiefast (Mar 26, 2014)

You mean:

```
defaultrouter="192.168.1.1"
```
Yes. My exact rc.conf is this:

```
font8x16="grfixed-8x16"
keymap="keramida.el-iso"
hostname="Unix-System"
defaultrouter="192.168.1.1"
#ifconfig_re0="dhcp"
#ifconfig_re0="inet 192.168.1.20 netmask 255.255.255.0"
wlans_iwn0="wlan0"
ifconfig_wlan0="inet 192.168.1.20 netmask 255.255.255.0"
wpa_supplicant_enable="YES"
sshd_enable="YES"
moused_enable="YES"
ntpd_enable="YES"
powerd_enable="YES"
dumpdev="AUTO"
zfs_enable="YES"
hald_enable="YES"
dbus_enable="YES"
linux_enable="YES"
nfs_client_enable="YES"
fusefs_enable="YES"
devfs_system_ruleset="system"
webcamd_enable="YES"
cupsd_enable="YES"
```


----------



## acheron (Mar 26, 2014)

Ok, can you ping the router? Does it work if you get an address with DHCP instead of static configuration?


----------



## sk8harddiefast (Mar 26, 2014)

I will test this in two hours when I will return home and I will post the results.


----------



## sk8harddiefast (Mar 26, 2014)

Ok. I am back. No. I cannot ping to router even with DHCP. I get error No route to host. Also wlan0 returns me no carrier.


----------



## wblock@ (Mar 26, 2014)

Please show the output of `ifconfig wlan0`.


----------



## sk8harddiefast (Mar 26, 2014)

```
wlan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
          ether 60:36:dd:e4:94:6d
          nd6 options=19<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
          media: IEEE 802.11 Wireless Ethernet autoselect (autoselect)
          status: no carrier
          ssid "" channel 10 (2457 MHz 11g)
          country US authmode OPEN privacy OFF txpower 15 bmiss 10 scanvalid 60
          bgscan bgscanintvl 300 bgscanidle 250 roam:rssi 7 roam:rate 5
          protmode CTS wme
```


----------



## wblock@ (Mar 26, 2014)

Turn off the "hidden" SSID and see if `ifconfig wlan0 up list scan` shows the access point.

("Hidden" SSIDs are not really hidden, anyway, they just make it more difficult to debug.)


----------



## sk8harddiefast (Mar 26, 2014)

Ok. I disable the hidden ssid option from my router and commented the

```
ap_scan=1
```
 from wpa_supplicant.conf
Now `ifconfig wlan0 up list scan`
returns me all available networks, including mine with RSN WME but still unable to connect.


----------



## sk8harddiefast (Mar 26, 2014)

Anyone....


----------



## sk8harddiefast (Mar 27, 2014)

I need wifi


----------



## deflected (Mar 27, 2014)

Hi @sk8harddiefast,

I`m worried about your ssid. I`m not completely sure that spaces and/or special symbols are allowed(or wpa_supplicant(8) accepts them). Could you please try with simpler ssid?


----------



## deflected (Mar 27, 2014)

Seem that spaces are allowed. wpa_supplicant.conf(5)


----------



## sk8harddiefast (Mar 27, 2014)

So if is not my ssid (I will try this too), then what causes the problem?


----------



## acheron (Mar 27, 2014)

Can you post the results of this command:`wlandebug -i wlan0 +scan +auth +assoc +debug`


----------

