How to run hostpad daemon WAS: Is hostapd really necessary?

Manjunathan PY pymanju
Mon May 12 03:10:22 PDT 2003


Hi Doug,
   It would be complete if you can add bridge setup too !
Please find the bridge setup below !

-----------------------cut here--------------------------
#Assuming that the wired interface is "eth0" and wireless interface is
"wlan0"
#Hostap daemon running on the Linux box with IP address 192.11.128.13
brctl addbr br0
brctl addif br0 eth0
brctl addif br0 wlan0
ifconfig eth0 0.0.0.0
ifconfig wlan0 0.0.0.0
echo "Starting to bridge br0 Assigning IP address 217.1.128.153!"
ifconfig br0 192.11.12.13 up
echo "Adding default gateway to the route table for bridge br0 "
route add default gw 192.11.128.2
-------------------------cut here--------------------------

Note: brctl application comes with bridge-utils package, can be downloaded
from http://bridge.sourceforge.net/download.html


Thanks,
Manjunathan PY



-----Original Message-----
From: hostap-admin at shmoo.com [mailto:hostap-admin at shmoo.com]On Behalf Of
Douglas Held
Sent: Sunday, May 11, 2003 5:15 AM
To: Jouni Malinen
Cc: hostap at shmoo.com
Subject: How to run hostpad daemon WAS: Is hostapd really necessary?


To recap, then:

HOWTO: Running the hostapd userspace daemon :

1.  obtain the hostap file tree
2.  choose hardware support type and configure ./Makefile according to
README docs
3.  edit ./driver/modules/hostap_config.h : remove /*comments*/ around the
line:
        #define PRISM2_HOSTAPD
4,  type 'make clean'
5.  type 'make plx' || 'make pccard' || 'make pci'
6.  type 'make install'
7.  cd ./hostapd
8.  type 'make'
9.  edit ./hostapd/hostapd.conf
10,
10. copy ./hostapd/hostapd to suitable bin directory like /usr/local/bin/
11. copy ./hostapd/hostapd.conf to /etc/hostapd.conf
12. create a file such as the following in /etc/init.d :

                #!/bin/bash
                # filename: /etc/init.d/hostap
                case "$1" in
                start)
                        insmod hostap_crypt
                        insmod hostap_crypt_wep
                        insmod hostap
                        insmod hostap_plx
                        /usr/local/bin/hostapd -B /etc/hostapd.conf
                        echo "hostapd apparently running as pid `pidof
hostapd`"
                        pidof hostapd > /var/run/hostapd.pid
                        ;;
                stop)
                        echo "Bringing down AP..."
                        kill -9 `cat /var/run/hostapd.pid`
                        ifconfig wlan0ap down
                        rmmod hostap_plx
                        rmmod hostap
                        rmmod hostap_crypt_wep
                        rmmod hostap_crypt
                        ;;
                "")
                        echo "no command given"
                        ;;
                esac

13. Enter runlevel 3 and ensure that no scripts are bringing up the wireless
interface already.
    (This can be done by rebooting, logging in as root and typing
'ifconfig')
14. The commands '/etc/init.d/hostap start' and '/etc/init.d/hostap stop'
can now be used at will to take up and put down the AP.
15. Optionally, soft link the script created in step 12 to rc?.d
directories.  Example:
        cd /etc/rc3.d
        ln -s /etc/init.d/hostap S90hostap
        chmod +x S90hostap
        cd /etc/rc2.d
        ln -s /etc/init.d/hostap K10hostap
        chmod +x K10hostap
16. The AP should now be configured to come up and down when the router
restarts.


Thanks to everyone who helped.  I hope this message will be easy for newbies
like me to find when searching the archives for help.

--Doug






At 07:35 PM 5/9/2003, you wrote:
>On Fri, May 09, 2003 at 09:26:05AM -0700, doug held wrote:
>
>> and now I get symbol errors.  malloc?  These look like very average
symbols, and /usr/src/linux does indeed soft link to linux-2.4.20-8.
>
>Well, they are average _user space_ symbols..
>
>> /sbin/depmod -ae
>> depmod: *** Unresolved symbols in /lib/modules/2.4.20-8/net/hostapd.o
>> depmod:         malloc
>> depmod:         hostapd_flush
>
>How did that hostapd.o end up being copied into kernel module directory?
>It is an object file for the user space hostapd daemon and it most
>certainly should not be in that directory. hostapd.o is created when you
>run 'make' in hostapd directory. However, I don't think 'make install'
>in any directory should copy it anywhere..
>
>--
>Jouni Malinen                                            PGP id EFC895FA
>_______________________________________________
>HostAP mailing list
>HostAP at shmoo.com
>http://lists.shmoo.com/mailman/listinfo/hostap

_______________________________________________
HostAP mailing list
HostAP at shmoo.com
http://lists.shmoo.com/mailman/listinfo/hostap





More information about the Hostap mailing list