I am trying to configure a router as a client to an WPA-EAP site.  The configuration using using LuCI does not connect, but I installed the wpa_supplicant, and when I start that manually, it connects without a problem.  I tried to manually change the /etc/config/wireless file so that it matched the wpa_supplicant.conf, but that did not help.  I seems from teh log that a critical error is that the '/var/run/wpa_supplicant-wlan0.conf' file can't be parse, but I am not sure how to fix this.  At this stage, I would be happy if I could get the supplicant to start automatically.  I tried creating a startup script for that, but it did not work either.  Any help would be appreciated.

Here are the details.

Router:         WRT54G v2.2
Firmware:     openwrt-brcm47xx-squashfs.trx
Supplicant:    wpa-supplicant_0.6.3-1_mipsel.ipk


*********** Processes ****************
---------------------------------------------------
  PID USER       VSZ STAT COMMAND
    1 root      1968 S    init
    2 root         0 SW<  [kthreadd]
    3 root         0 SW<  [ksoftirqd/0]
    4 root         0 SW<  [events/0]
    5 root         0 SW<  [khelper]
   19 root         0 SW<  [kblockd/0]
   53 root         0 SW   [pdflush]
   54 root         0 SW   [pdflush]
   55 root         0 SW<  [kswapd0]
   56 root         0 SW<  [aio/0]
   68 root         0 SW<  [mtdblockd]
  238 root         0 SWN  [jffs2_gcd_mtd3]
  250 root      1968 S    logger -s -p 6 -t
  251 root      1968 S    init
  265 root      1980 S    syslogd -C16
  267 root      1964 S    klogd
  279 root      1136 S    /sbin/hotplug2 --override --persistent --max-children
  438 root         0 SW<  [b43]
  559 root         0 SW<  [ipolldevd]
  575 root      1980 S    udhcpc -t 0 -i wlan0 -b -p /var/run/wlan0.pid -R
  760 root      1940 S    /usr/sbin/dropbear -p 22
  765 root      1964 S    /usr/sbin/httpd -p 80 -h /www -r OpenWrt
  792 nobody    1280 S    /usr/sbin/dnsmasq -K -D -y -Z -b -E -s lan -S /lan/ -
  800 root      1996 S    /usr/sbin/dropbear -p 22
  801 root      1976 S    -ash
  806 root      1968 R    ps -aux


************  /etc/config/wireless *****************

config 'wifi-device' 'wlan0'
        option 'type' 'mac80211'
        option 'channel' '5'
        option 'disabled' '0'

config 'wifi-iface'
        option 'device' 'wlan0'
        option 'ssid' 'OpenWrt'
        option 'network' 'wan'
        option 'mode' 'sta'
        option 'eap_type' 'PEAP'
        option 'password' '<password>'
        option 'encryption' 'wpa'
        option 'auth' '<domain\user>'
        option 'identity' '<domain\user>'


********** Command used to successfully, but manually start supplicant **************

wpa_supplicant -B -iwlan0 -c/etc/wpa_supplicant.conf &




************ wpa_supplicant.conf  *************


network={
       ssid="<SSID>"
       scan_ssid=1
       key_mgmt=WPA-EAP
       eap=PEAP
       anonymous_identity="<domain\user>"
       identity="<domain\user>"
       password="<password>"
       phase1="peaplabel=0"
       phase2="auth=MSCHAPV2"
}



*********** Partial System Log Pre-Manual Start ****************

Feb  5 22:27:39 OpenWrt user.info kernel: Registered led device: b43-phy0::radio
Feb  5 22:27:39 OpenWrt user.debug kernel: b43-phy0 debug: Wireless interface started
Feb  5 22:27:39 OpenWrt user.debug kernel: b43-phy0 debug: Adding Interface type 2
Feb  5 22:27:39 OpenWrt user.info : udhcpc (v1.11.2) started
Feb  5 22:27:40 OpenWrt user.info : Line 10: unknown network field 'eap_type'.
Feb  5 22:27:40 OpenWrt user.info : Line 17: failed to parse network block.
Feb  5 22:27:40 OpenWrt user.info : Failed to read or parse configuration '/var/run/wpa_supplicant-wlan0.conf'.
Feb  5 22:27:40 OpenWrt user.info : enable_mac80211(wlan0): Failed to set up wpa_supplicant for interface wlan0
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: Removing Interface type 2
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: Wireless interface stopped
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: DMA-30 rx_ring: Used slots 1/64, Failed frames 0/0 = 0.0%, Average tries 0.00
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: DMA-30 tx_ring_AC_BK: Used slots 0/128, Failed frames 0/0 = 0.0%, Average tries 0.00
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: DMA-30 tx_ring_AC_BE: Used slots 0/128, Failed frames 0/0 = 0.0%, Average tries 0.00
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: DMA-30 tx_ring_AC_VI: Used slots 0/128, Failed frames 0/0 = 0.0%, Average tries 0.00
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: DMA-30 tx_ring_AC_VO: Used slots 2/128, Failed frames 0/8 = 0.0%, Average tries 1.00
Feb  5 22:27:40 OpenWrt user.debug kernel: b43-phy0 debug: DMA-30 tx_ring_mcast: Used slots 0/128, Fail



*********** Partial System Log Post-Manual Start ****************

Feb  5 22:33:10 OpenWrt user.debug kernel: b43-phy0 debug: Wireless interface started
Feb  5 22:33:10 OpenWrt user.debug kernel: b43-phy0 debug: Adding Interface type 2
Feb  5 22:33:12 OpenWrt user.debug kernel: wlan0: authenticate with AP 00:e0:b8:76:26:9e
Feb  5 22:33:12 OpenWrt user.debug kernel: wlan0: authenticate with AP 00:e0:b8:76:26:9e
Feb  5 22:33:12 OpenWrt user.debug kernel: wlan0: authenticated
Feb  5 22:33:12 OpenWrt user.debug kernel: wlan0: associate with AP 00:e0:b8:76:26:9e
Feb  5 22:33:12 OpenWrt user.debug kernel: wlan0: RX AssocResp from 00:e0:b8:76:26:9e (capab=0x431 status=0 aid=5)
Feb  5 22:33:12 OpenWrt user.debug kernel: wlan0: associated
Feb  5 22:33:14 OpenWrt user.info : Sending select for <ip>...
Feb  5 22:33:14 OpenWrt user.info : Lease of <ip> obtained, lease time 87000
Feb  5 22:33:14 OpenWrt user.info : adding router <ip>
Feb  5 22:33:14 OpenWrt user.info : deleting old routes
Feb  5 22:33:14 OpenWrt user.info : adding dns <ip>
Feb  5 22:33:14 OpenWrt user.info : adding dns <ip>
Feb  5 22:33:16 OpenWrt user.notice root: adding wan (wlan0) to firewall zone wan
Feb  5 22:33:25 OpenWrt daemon.info dnsmasq[882]: reading /tmp/resolv.conf.auto
Feb  5 22:33:25 OpenWrt daemon.info dnsmasq[882]: using nameserver <ip>#53
Feb  5 22:33:25 OpenWrt daemon.info dnsmasq[882]: using nameserver <ip>#53
Feb  5 22:33:25 OpenWrt daemon.info dnsmasq[882]: using local addresses only for domain lan