This is the old SliTaz forum - Please use the main forum.slitaz.org

Fritz!WLAN USB stick works, but does not start automatically. [SOLVED]
  • on4aaon4aa March 2011

    [Update: In order to keep oversight, I posted the solution in a separate discussion: http://forum.slitaz.org/index.php?p=/discussion/2671/there-is-something-seriously-wrong-with-the-rcs-boot-sequence-and-network.sh-solved/p1 ]

    Hello,

    A couple of days ago, I installed SliTaz 2.6.30.3 on a 12 year old Toshiba Satellite 4000CDT (Pentium II 233MHz, 156MB RAM @66MHz, 800x600x24bit video, 40GB HD, 1 USB1.0 via ISA). I am really positively impressed with the responsiveness Slitaz is getting out of this machine. More so then when I tried Puppy Linux.


    My problem:
    I managed to get a Fritz!WLAN USB stick working via ndiswrapper and surf the net, however it never starts automatically...until I manually restart with /etc/init.d/network.sh restart

    I wonder if somebody can help me with this minor annoyance?

    When I click on the Network Status Monitor, I get:
    Connection
    Name: Unknown (and only "lo" is available as selectable value)
    Status: Disconnected

    Continuing by clicking on Configure, shows under the Connections tab, the following:
    Interface   Type         Status
     lo             Loopback connected (127.0.0.1)
     wlan0       Wireless   -

    Full status correctly shows the wireless interface, all wireless networks it hears and the routing data.

    My /etc/network.conf looks like this:
    # Config file used by: /etc/init.d/network.sh
    #

    # Set default interface.
    INTERFACE="wlan0"

    # Dynamic IP address.
    # Enable/disable DHCP client at boot time.
    DHCP="yes"

    # Static IP address.
    # Enable/disable static IP at boot time.
    STATIC="no"

    # Set IP address and netmask for a static IP.
    IP="192.168.0.6"
    NETMASK="255.255.255.0"

    # Set route gateway for a static IP.
    GATEWAY="192.168.0.1"

    # Set DNS server for a static IP.
    DNS_SERVER="192.168.0.1"

    # Wifi connection.
    # Enable/disable wireless connection at boot time.
    WIFI="yes"

    # Wifi interface (iwconfig) and ESSID.
    WIFI_INTERFACE="wlan0"
    WIFI_ESSID="my_essid"
    WIFI_MODE=""
    WIFI_KEY="my_password"
    WIFI_KEY_TYPE="wpa"
    WPA_DRIVER="wext"
    WIFI_CHANNEL=""WIFI_IWCONFIG_ARGS=""

    and my_essid.conf looks like this and was added to the favorites:
    # Wireless connection configuration.
    #
    WIFI_ESSID="my_essid"
    WIFI_KEY="my_password"
    WIFI_KEY_TYPE="wpa"

    Now, only when I click Restart under the Netbox Configuration tab, do I get connected. The option "wlan0" now becomes available under Network Status Monitor, but I also need to manually select it.
    What am I overlooking here? How can I automate my connection?



  • slicelslicel March 2011
    I asked a similar question a few years ago but have not received an answer yet.

    Maybe a local.sh or udev script would do it.
  • on4aaon4aa March 2011

    @slicel: Good to know!

    As a matter of fact, when booting I see a red udev failure quickly passing by...

    Attached is a boot log extract:

    Processing /etc/init.d/rcS...
    Mounting proc filesystem... [ [1;33mOK[22;37m ]
    Searching for early boot options... [ [1;33mOK[22;37m ]
    Starting udev daemon... [ [1;31mFailed[22;37m ]
    Udevadm requesting events from the Kernel... [ [1;33mOK[22;37m ]
    Udevadm waiting for the event queue to finish... [ [1;33mOK[22;37m ]
    Checking filesystem on : /dev/hda2
    /dev/hda2: clean, 15253/327680 files, 158003/1309297 blocks
    Remounting rootfs read/write...
    EXT3 FS on hda2, internal journal
    Mounting filesystems in fstab...

  • Trixar_zaTrixar_za March 2011
    I get that too. It has to do with udev being started too quickly, but as long as HAL starts with an OK, you won't have a problem.

    Try slicel's solution and try the following:
    1. Start a terminal and su to root.
    2. leafpad /etc/init.d/local.sh
    3. Add: ./etc/init.d/network.sh restart
    4. Save and exit.

    Then try rebooting and see if that works.
  • on4aaon4aa March 2011

    @Trixar_za: Thanks for offering your help!

    Like you, I am completely convinced that we are dealing with a timing error where the USB WLAN stick is not given the time to get up and running.

    This finding is supported by the fact that the WLAN USB stick *is* detected after a warm reboot, contrary to a startup after a complete shutdown. Most probably this is because during a warm reboot the power to the WLAN USB stick is not interrupted.

  • on4aaon4aa March 2011

    @Trixar_za: I tried out your suggestion of changing the local.sh, however still without success... (see log below)

    Are you sure that network.sh restart is doing the same as hitting the "Restart" button in the network manager???

    Starting local startup commands...
    Stopping all interfaces
    ifconfig: SIOCGIFFLAGS: No such device
    ifconfig: SIOCGIFFLAGS: No such device
    Killing all daemons
    killall: udhcpc: no process killed
    wlan0 No such device

    ifconfig: SIOCGIFFLAGS: No such device
    ifconfig: SIOCGIFFLAGS: No such device
    wlan0 is not a wifi interface, changing it.
    Configuring ...ifconfig: up: error fetching interface information: Device not found
    lo no wireless extensions.

    dummy0 no wireless extensions.

    [70G[ [1;33mOK[0;39m ]
    Starting wpa_supplicant for WPA-PSK...
    wpa_supplicant: option requires an argument -- 'i'
    wpa_supplicant v0.6.9
    Copyright (c) 2003-2009, Jouni Malinen and contributors

    This program is free software. You can distribute it and/or modify it
    under the terms of the GNU General Public License version 2.

    Alternatively, this software may be distributed under the terms of the
    BSD license. See README and COPYING for more details.

    This product includes software developed by the OpenSSL Project
    for use in the OpenSSL Toolkit (http://www.openssl.org/)

    usage:
    wpa_supplicant [-BddhKLqqtuvW] [-P] [-g] \
    -i -c [-C] [-D] [-p] \
    [-b
    ] [-f] \
    [-N -i -c [-C] [-D] \
    [-p] [-b
    ] ...]

    drivers:
    wext = Linux wireless extensions (generic)
    hostap = Host AP driver (Intersil Prism2/2.5/3)
    atmel = ATMEL AT76C5XXx (USB, PCMCIA)
    wired = wpa_supplicant wired Ethernet driver
    options:
    -b = optional bridge interface name
    -B = run daemon in the background
    -c = Configuration file
    -C = ctrl_interface parameter (only used if -c is not)
    -i = interface name
    -d = increase debugging verbosity (-dd even more)
    -D = driver name
    -g = global ctrl_interface
    -K = include keys (passwords, etc.) in debug output
    -t = include timestamp in debug messages
    -h = show this help text
    -L = show license (GPL and BSD)
    -p = driver parameters
    -P = PID file
    -q = decrease debugging verbosity (-qq even less)
    -v = show version
    -W = wait for a control interface monitor before starting
    -N = start describing new interface
    example:
    wpa_supplicant -Dwext -iwlan0 -c/etc/wpa_supplicant.conf
    Starting udhcpc client on: ...
    Selected interface 'wlan0'
    Failed to connect to wpa_supplicant - wpa_ctrl_open: Connection refused
    Starting all daemons specified in /etc/rcS.conf...
    Starting message bus daemon: DBUS... Unknown username "polkituser" in message bus configuration file
    [70G[ [1;33mOK[0;39m ]
    Starting Hardware Abstraction Layer: HAL... [70G[ [1;33mOK[0;39m ]
    Setting up kernel security rules... [70G[ [1;33mOK[0;39m ]
    Iptables rules are disabled in: /etc/firewall.conf...
    Starting slim login manager: Slim... [70G[ [1;33mOK[0;39m ]

    [3g H H H H H H H H H
    c]R
    [1mWelcome to your box.[0m
    SliTaz boot time: 15s

  • Trixar_zaTrixar_za March 2011
    Hmmm, still trying to run too early for it then.

    Well, that leaves having to use openbox's auto-start script. So go to "Red Spider Button" --> Preferences --> Auto start applications, click the Configuration button and add ./etc/init.d/network.sh restart to the bottom of it. Save and exit.

    You'd probably want to remove what you added to local.sh again since it's not working.
  • on4aaon4aa March 2011

    @Trixar_za: After making another 50 or something cold boot ups, systematically trying out every change, i finally found the solution to getting wlan0 up automatically. In order to keep an oversight, I posted the solution here:

    http://forum.slitaz.org/index.php?p=/discussion/2671/there-is-something-seriously-wrong-with-the-rcs-boot-sequence-and-network.sh-solved/p1

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Apply for Membership

SliTaz Social