Page 1 of 2 12 LastLast
Results 1 to 10 of 18

Thread: Can we speed up Network Manager?

Hybrid View

  1. #1
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631

    Can we speed up Network Manager?

    My Windows 7 boots to wi-fi on-line in ~60 seconds.
    My Knoppix 6.4.4 LiveUSB does so in 1m46s.
    Looking at syslog, it appears that the last 48 seconds
    of any boot-up are spent doing Network Manager negotiations.

    NM is doing its job here, but doesn't seem as clever as
    Win7 in getting its job done; certainly not as fast.
    In my case, wi-fi means a Dell internal Broadcom wireless
    with a (non-free) wl driver, a DHCP router connected
    to the internet via Verizon FiOS at 15 Mb/s. Simple
    WEP security. Applet says NM is version 0.8.1.

    I have an external wireless adapter that doesn't use a
    non-free driver, and get the same results.

    Are there some tweaks that would speed up NM?

  2. #2
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631
    Well, thank you all for your suggestions.
    Here's how far I've got, and I'm open for further enhancements.

    1...I found this nice Ubuntu How-To which helps a lot:
    http://ubuntuforums.org/showthread.php?t=684495

    2...I did what it says, and put, as root, this in my /etc/rc.local:
    sudo dhclient -r eth1
    sudo ifconfig eth1 up
    sudo iwconfig eth1 essid "alpha=num essid"
    sudo iwconfig eth1 key "10 char hex key"
    #sudo iwconfig eth1 key open # didn't need this apparently
    sudo iwconfig eth1 mode Managed
    sudo dhclient eth1

    3...I revised my LiveUSB DEFAULT, as root, to read:
    DEFAULT knoppix nonetworkmanager edd=off fromhd=/dev/sdb1
    That's the 1st line in /Desktop/KNOPPIX/boot/syslinux/syslinux.cfg

    4...Rebooted.‎

    5...Did less /var/log/syslog.
    Found that start-of-boot to wi-fi on-line now takes 58 seconds.

    Beat that.

  3. #3
    Senior Member
    Join Date
    Jan 2011
    Posts
    242
    Quote Originally Posted by utu View Post
    Well, thank you all for your suggestions.
    What ? Deprive you of your learning opportunity ? In my book that's a cardinal sin.

    Besides, if I suggested that the best way of speeding up the Network Manager was to not run the Network Manager I'd have had klaus2008 down on my tail (http://www.knoppix.net/forum/threads...ot-in-Adrianne).

    Quote Originally Posted by utu View Post
    I found this nice Ubuntu How-To which helps a lot:
    http://ubuntuforums.org/showthread.php?t=684495
    Beat that.
    http://wiki.debian.org/WiFi
    http://wiki.debian.org/WiFi/HowToUse

    You managed to find a real hacker's hacker - he didn't mention /etc/networks/interfaces once ! You then come up with a solution that names your wireless interface eth1 instead of the usual wlan0. Extra marks.

    Here's what the Debian installer put in my /etc/networks/interfaces to bring up my wifi with WEP:

    Code:
    # The primary network interface
    allow-hotplug wlan0
    iface wlan0 inet dhcp
            # wireless-* options are implemented by the wireless-tools package
            wireless-mode managed
            wireless-essid MyEssid
            wireless-key1 **********
    It is my understanding that with this the most you would need in /etc/rc.local is:

    Code:
    ifup wlan0
    and you might not even need that.

    Ever since I first met the wonderful Network Manager, I've had a manual way of getting my wireless going just in case. I normally use WPA PSK2. If my WPA PSK2 configuration is hidden away in:

    Code:
    /etc/wpa_supplicant.conf
    Then I can start my wireless by hand with:

    Code:
    sudo wpa_supplicant -B -c/etc/wpa_supplicant.conf -iwlan0
    sudo dhclient
    How many sudos did you use ? BTW I don't think you need sudo in /etc/.rc.local.

    I found recently that I can combine the two approaches with:

    Code:
    # The primary network interface
    allow-hotplug wlan0
    iface wlan0 inet dhcp
        wpa-conf /etc/wpa_supplicant.conf
    The problem with the Network Manager is not just that it is started when your PC / LT is busy starting everything else, it's not just that the Network Manager is a big desktop app, it's not just that the LXNetMan is still 'in development'. It's that the Network Manager does not try to connect until you login in. This is not obvious with Knoppix but if you try it on a real desktop installation you'll see what I mean. Thus the Network Manager starts connecting very late in the startup sequence so it appears slower that Windoze.

    By connecting without the Network Manager, you starting connecting much earlier in the startup sequence. The cost is that you must already know which network you want to connect to. This may not be a concern to you but for those that carry their laptop round like security blankets and use them everywhere like they were mobiles (or handys or cells), this could be a real drawback.

    Enter wicd. This is a new, ligthweight, alternative to the Network Manager. It is not as flash as the Network Manager but I understand it will connect in both GUI and console modes. This leads me to believe it must be possible to start it much earlier in the start up sequence.

    I have it running on one Debian laptop but I don't have the time to experiment with it any further. You might like to. If your name is dinoesep, back up your knoppix-data.img first 'cos I think you'll need to uninstall Network Manager in order to install wicd. Obviously, start your network first !

    Cheers
    Last edited by Forester; 03-05-2011 at 01:45 PM.

  4. #4
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631
    Faint praise accepted.
    I never uninstalled NM, just added nonetworkmanager cheatcode to my DEFAULT;
    see step 3.
    Also, my /etc/rc.local belongs to root.

  5. #5
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631
    FYI, Here's how I've been timing these results.

    I've added these to my .bashrc:

    alias wl.go='less /var/log/syslog|grep restart|cut -c11-16'
    alias wl.up='less /var/log/syslog|grep renewal|cut -c11-16'

    So right after booting up, I can time the event this way:

    knoppix@Microknoppix:~$ wl.up; wl.go
    57:17
    56:27

    I do the subtraction myself, of course.
    Glad to have an expert show me how to program that detail

  6. #6
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631
    Heres' my latest. On-line now in 50 seconds.

    #!/bin/bash

    # /etc/rc.local (mine is root:root and executable)

    # other stuff(1)

    setwifi () { # see http://ubuntuforums.org/showthread.php?t=684495
    WIFI="eth1"; dhclient -r $WIFI; ifconfig $WIFI up
    iwconfig $WIFI essid "(alphanumeric ssid)" key "(hexadecimal wep)" mode "Managed"
    nohup dhclient $WIFI; wait >/dev/null 2>&1
    aplay -vv /usr/lib/libreoffice/basis3.3/share/gallery/sounds/ok.wav
    }

    # other stuff(2)

    setwifi

    # other stuff(3)

    exit 0
    Last edited by utu; 06-13-2011 at 12:39 AM. Reason: correct typos in post #5

  7. #7
    Senior Member
    Join Date
    Feb 2012
    Posts
    146
    Quote Originally Posted by utu View Post
    Heres' my latest. On-line now in 50 seconds.

    #!/bin/bash

    # /etc/rc.local (mine is root:root and executable)

    # other stuff(1)

    setwifi () { # see http://ubuntuforums.org/showthread.php?t=684495
    WIFI="eth1"; dhclient -r $WIFI; ifconfig $WIFI up
    iwconfig $WIFI essid "(alphanumeric ssid)" key "(hexadecimal wep)" mode "Managed"
    nohup dhclient $WIFI; wait >/dev/null 2>&1
    aplay -vv /usr/lib/libreoffice/basis3.3/share/gallery/sounds/ok.wav
    }

    # other stuff(2)

    setwifi

    # other stuff(3)

    exit 0
    Dear utu:

    Q: Which version's of knoppix is this script compatible?

    I'm interested using WLAN CLI alternatives to the bloated network-manager GUI w/7.0.3!

    Regards,
    luther

  8. #8
    Senior Member
    Join Date
    Feb 2012
    Posts
    146
    Quote Originally Posted by utu View Post
    Heres' my latest. On-line now in 50 seconds.

    #!/bin/bash

    # /etc/rc.local (mine is root:root and executable)

    # other stuff(1)

    setwifi () { # see http://ubuntuforums.org/showthread.php?t=684495
    WIFI="eth1"; dhclient -r $WIFI; ifconfig $WIFI up
    iwconfig $WIFI essid "(alphanumeric ssid)" key "(hexadecimal wep)" mode "Managed"
    nohup dhclient $WIFI; wait >/dev/null 2>&1
    aplay -vv /usr/lib/libreoffice/basis3.3/share/gallery/sounds/ok.wav
    }

    # other stuff(2)

    setwifi

    # other stuff(3)

    exit 0
    ATT: knoppix team
    Q: How would this script be ammended to my existing 'rc.local' and made 'root:root' & 'executable'?

    Code:
    #!/bin/bash
    #
    # rc.local
    #
    # Start local services after hardware detection
    
    SERVICES="cups"
    
    for i in $SERVICES; do
     [ -x /etc/init.d/"$i" ] && /etc/init.d/"$i" start >/dev/null 2>&1
    done
    
    exit 0
    THX!
    luther

  9. #9
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631
    Heres' my latest. On-line now in 50 seconds.

    #!/bin/bash

    # /etc/rc.local (mine is root:root and executable)

    # other stuff(1)

    setwifi () { # see http://ubuntuforums.org/showthread.php?t=684495
    WIFI="eth1"; dhclient -r $WIFI; ifconfig $WIFI up
    iwconfig $WIFI essid "(alphanumeric ssid)" key "(hexadecimal wep)" mode "Managed"
    nohup dhclient $WIFI; wait >/dev/null 2>&1
    aplay -vv /usr/lib/libreoffice/basis3.3/share/gallery/sounds/ok.wav
    }

    # other stuff

    setwifi(2)

    # other stuff(2)

    exit 0

  10. #10
    Senior Member registered user
    Join Date
    Dec 2009
    Posts
    423
    If you are concerned about security, NEVER NEVER NEVER used wep.
    WEP can be cracked in about 5-30 minutes, does not matter how long your password/passhrase.

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


HPGYT DELL Micron 5100 PRO 960GB SATA 6Gb/s 2.5in SSD 0HPGYT MTFDDAK960TCB Gen14 picture

HPGYT DELL Micron 5100 PRO 960GB SATA 6Gb/s 2.5in SSD 0HPGYT MTFDDAK960TCB Gen14

$69.00



G5T03 Dell Intel DC S3700 Series 800GB SATA 6Gb/s 2.5

G5T03 Dell Intel DC S3700 Series 800GB SATA 6Gb/s 2.5" SSD 0G5T03 SSDSC2BA800G3E

$55.00



### MZ-7KE1T0 Samsung 850 Pro Series 1TB 2.5 inch SATA3 SSD ### picture

### MZ-7KE1T0 Samsung 850 Pro Series 1TB 2.5 inch SATA3 SSD ###

$105.00



Brand New 128GB-240GB-256GB-512GB 2.5 inch SATA3 Solid State Drive 2.5

Brand New 128GB-240GB-256GB-512GB 2.5 inch SATA3 Solid State Drive 2.5" SSD

$17.99



Patriot P210 128GB 256GB 512GB 1TB 2TB 2.5

Patriot P210 128GB 256GB 512GB 1TB 2TB 2.5" SATA 3 6GB/s Internal SSD PC/MAC Lot

$14.99



Micron 5100 MAX 120GB SATA 6Gb/s 2.5

Micron 5100 MAX 120GB SATA 6Gb/s 2.5" Internal SSD MTFDDAK120TCC Solid State

$9.89



Netac 1TB 2TB 512GB Internal SSD 2.5'' SATA III 6Gb/s Solid State Drive lot picture

Netac 1TB 2TB 512GB Internal SSD 2.5'' SATA III 6Gb/s Solid State Drive lot

$13.99



Fanxiang SSD 512GB 1TB 2TB 4TB 2.5'' SSD SATA III Internal Solid State Drive lot picture

Fanxiang SSD 512GB 1TB 2TB 4TB 2.5'' SSD SATA III Internal Solid State Drive lot

$13.99



M.2 NVMe SSD 128GB 256GB 512GB Single Notch with Windows Installed 10 / 11 picture

M.2 NVMe SSD 128GB 256GB 512GB Single Notch with Windows Installed 10 / 11

$85.25



Fanxiang M.2 SATA SSD 2TB 1TB 512GB 256GB SSD Internal M2 Solid State Drive Lot picture

Fanxiang M.2 SATA SSD 2TB 1TB 512GB 256GB SSD Internal M2 Solid State Drive Lot

$109.99