# [Solved] looking for network advice

## MrStill

Hi,

I am trying to set up networking on my laptop. I have only wired connection. If I have the network cable unplugged KDE fails to start properly. I would like to install a network manager (such as knetworkmanager) to help manage wireless connections. But, I usually only connect to one of three networks. I am not sure what information is needed. 

iwconfig:

```

lo        no wireless extensions.

eth0      no wireless extensions.

wmaster0  no wireless extensions.

wlan0     IEEE 802.11bg  ESSID:""

          Mode:Managed  Frequency:2.412 GHz  Access Point: Not-Associated

          Tx-Power=0 dBm

          Retry  long limit:7   RTS thr:off   Fragment thr:off

          Encryption key:off

          Power Management:off

          Link Quality:0  Signal level:0  Noise level:0

          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0

          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

sit0      no wireless extensions.

```

Forgive me, as I did not quite understand how to set up this file:

```

  GNU nano 2.1.10                  File: /etc/conf.d/net

# This blank configuration will automatically use DHCP for any net.*

# scripts in /etc/init.d.  To create a more complete configuration,

# please review /etc/conf.d/net.example and save your configuration

# in /etc/conf.d/net (this file :]!).

modules=( "iwconfig" )

config_eth0=( "dhcp" )

essid_wlan0="joseph"

key_joseph="xxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xx"

essid_wlan0="ufw"

preferred_aps=( "joseph" "ufw" )

```

Any advice would be awesome.Last edited by MrStill on Tue Feb 09, 2010 3:51 am; edited 1 time in total

----------

## d2_racing

Hi, can you post this :

```

# emerge --info

# rc-update show

# lspci -n

```

I suggest that you use WICD because it's stable enough and right now, are you using KDE 4.3.3 or KDE 3.x ?

Finally, what is the error when you say that KDE is not working properly ?

----------

## MrStill

Below are the outputs you requested. I am using KDE 4.3.3. I get no error message (that I know of). I get a log in screen followed by a black screen. Eventually I hear the KDE log in tone. If I press hot keys I have set up, I get what ever program I assigned to launch with that key combo. Once I close it ... black screen again. 

I tried wicd; it wouldn't connect to my wireless access point. It would connect to my wired network though. But if I had the wire disconnected, I would get the same misbehavior of KDE. I unmerged wicd after a couple of days trying to get it to work. I am, however, willing to reinstall it if need be.

It might also help for me to mention that I installed ifplugd and I have a desktop widget that requires Internet connection. 

emerge --info:

```

Portage 2.1.7.16 (default/linux/x86/10.0/desktop, gcc-4.3.4, glibc-2.10.1-r1, 2.6.31-gentoo-r6 i686)                                                                                                

=================================================================                                 

System uname: Linux-2.6.31-gentoo-r6-i686-Intel-R-_Atom-TM-_CPU_N270_@_1.60GHz-with-gentoo-1.12.13

Timestamp of tree: Sat, 30 Jan 2010 18:30:01 +0000                                                

app-shells/bash:     4.0_p35                                                                      

dev-java/java-config: 2.1.10                                                                      

dev-lang/python:     2.6.4                                                                        

dev-util/cmake:      2.6.4-r3                                                                     

sys-apps/baselayout: 1.12.13                                                                      

sys-apps/sandbox:    1.6-r2                                                                       

sys-devel/autoconf:  2.13, 2.63-r1                                                                

sys-devel/automake:  1.8.5-r3, 1.9.6-r2, 1.10.2                                                   

sys-devel/binutils:  2.18-r3                                                                      

sys-devel/gcc-config: 1.4.1                                                                       

sys-devel/libtool:   2.2.6b                                                                       

virtual/os-headers:  2.6.27-r2                                                                    

ACCEPT_KEYWORDS="x86"                                                                             

ACCEPT_LICENSE="* -@EULA"                                                                         

CBUILD="i686-pc-linux-gnu"                                                                        

CFLAGS="-O2 -march=native -pipe"                                                                  

CHOST="i686-pc-linux-gnu"                                                                         

CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/config"                                        

CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/sandbox.d /etc/splash /etc/terminfo /etc/udev/rules.d"         

CXXFLAGS="-O2 -march=native -pipe"                                                                

DISTDIR="/usr/portage/distfiles"                                                                  

FEATURES="assume-digests distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms strict unmerge-logs unmerge-orphans userfetch"                                                     

GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"                                                                                               

LDFLAGS="-Wl,-O1"                                                                                 

MAKEOPTS="-j2"                                                                                    

PKGDIR="/usr/portage/packages"                                                                    

PORTAGE_CONFIGROOT="/"                                                                            

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"      

PORTAGE_TMPDIR="/var/tmp"                                                                         

PORTDIR="/usr/portage"

SYNC="rsync://rsync.gentoo.org/gentoo-portage"

USE="X a52 aac acl acpi alsa berkdb bluetooth branding bzip2 cairo cdr cli consolekit cracklib crypt cups cxx dbus dri dts dvd dvdr eds emboss encode evo fam fbcondecor firefox flac fortran gdbm gif gpm gstreamer hal iconv ipv6 jpeg kde ldap libnotify mad mikmod mng modules mp3 mp4 mpeg mudflap ncurses nls nptl nptlonly ogg opengl openmp pam pcre pdf perl png ppds pppd python qt3support qt4 quicktime readline reflection sdl session spell spl ssl startup-notification svg sysfs tcpd thunar tiff truetype unicode usb vorbis win32codecs x264 x86 xml xorg xulrunner xv xvid zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="intel"

Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY

```

rc-update show

```

            bootmisc | boot

             checkfs | boot

           checkroot | boot

               clock | boot

         consolefont | boot

          consolekit |      default

                dbus |      default

                hald |      default

            hostname | boot

             keymaps | boot

               local |      default nonetwork

          localmount | boot

             modules | boot

              net.lo | boot

            netmount |      default

           rmnologin | boot

           syslog-ng |      default

             urandom | boot

          vixie-cron |      default

                 xdm |      default

```

lspci -n

```

00:00.0 0600: 8086:27ac (rev 03)

00:02.0 0300: 8086:27ae (rev 03)

00:02.1 0380: 8086:27a6 (rev 03)

00:1b.0 0403: 8086:27d8 (rev 02)

00:1c.0 0604: 8086:27d0 (rev 02)

00:1c.1 0604: 8086:27d2 (rev 02)

00:1c.2 0604: 8086:27d4 (rev 02)

00:1c.3 0604: 8086:27d6 (rev 02)

00:1d.0 0c03: 8086:27c8 (rev 02)

00:1d.1 0c03: 8086:27c9 (rev 02)

00:1d.2 0c03: 8086:27ca (rev 02)

00:1d.3 0c03: 8086:27cb (rev 02)

00:1d.7 0c03: 8086:27cc (rev 02)

00:1e.0 0604: 8086:2448 (rev e2)

00:1f.0 0601: 8086:27b9 (rev 02)

00:1f.2 0101: 8086:27c4 (rev 02)

00:1f.3 0c05: 8086:27da (rev 02)

02:00.0 0200: 10ec:8136 (rev 02)

03:00.0 0200: 168c:001c (rev 01)

04:00.0 0880: 197b:2382

04:00.2 0805: 197b:2381

04:00.3 0880: 197b:2383

04:00.4 0880: 197b:2384

```

thanks

Joseph

----------

## d2_racing

Right now, can you post this :

```

# dmesg | grep -i ath

# cd /usr/src/linux && cat .config | grep -i ath

# ifconfig -a

# iwconfig

# iwlist scan

# dmesg | tail

```

----------

## d2_racing

When you used wicd, did run this command : 

```

# rc-update add wicd boot

```

----------

## MrStill

When I was using WICD , I tried running it from both the default and boot run level. As instructed in the WICD tutorial, I attempted to remove anything that might automatically bring up a connection without WICD. I could have been unsuccessful . In iwlist scan,  my wlan0 interface should not return "interface doesn't support scanning," right?

```

joseph@joseph-micro ~ $ sudo dmesg | grep -i ath

[    0.920151] ath5k 0000:03:00.0: PCI INT A -> GSI 18 (level, low) -> IRQ 18

[    0.920304] ath5k 0000:03:00.0: setting latency timer to 64

[    0.920377] ath5k 0000:03:00.0: registered as 'phy0'

[    1.012666] ath: EEPROM regdomain: 0x65

[    1.012671] ath: EEPROM indicates we should expect a direct regpair map

[    1.012678] ath: Country alpha2 being used: 00

[    1.012682] ath: Regpair used: 0x65

[    1.015014] Registered led device: ath5k-phy0::rx

[    1.015232] Registered led device: ath5k-phy0::tx

[    1.015360] ath5k phy0: Atheros AR2425 chip found (MAC: 0xe2, PHY: 0x70)

```

```

joseph@joseph-micro ~ $ cd /usr/src/linux && cat .config | grep -i ath

# CONFIG_MATH_EMULATION is not set

CONFIG_IP_ROUTE_MULTIPATH=y

CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"

# CONFIG_MD_MULTIPATH is not set

# CONFIG_DM_MULTIPATH is not set

CONFIG_ATH_COMMON=y

CONFIG_ATH5K=y

# CONFIG_ATH5K_DEBUG is not set

# CONFIG_ATH9K is not set

# CONFIG_SECURITY_PATH is not set

```

```

joseph@joseph-micro /usr/src/linux $ sudo ifconfig -a

eth0      Link encap:Ethernet  HWaddr 00:1e:68:f8:44:64  

          inet addr:192.168.0.100  Bcast:192.168.0.255  Mask:255.255.255.0

          inet6 addr: fe80::21e:68ff:fef8:4464/64 Scope:Link              

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1              

          RX packets:817 errors:0 dropped:0 overruns:0 frame:0            

          TX packets:925 errors:0 dropped:0 overruns:0 carrier:0          

          collisions:0 txqueuelen:1000                                    

          RX bytes:424927 (414.9 KiB)  TX bytes:118214 (115.4 KiB)        

          Interrupt:28 Base address:0xc000                                

lo        Link encap:Local Loopback  

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host     

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:20 errors:0 dropped:0 overruns:0 frame:0

          TX packets:20 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:1000 (1000.0 B)  TX bytes:1000 (1000.0 B)

sit0      Link encap:IPv6-in-IPv4

          NOARP  MTU:1480  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

wlan0     Link encap:Ethernet  HWaddr 00:23:4d:5e:a2:06

          BROADCAST MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

wmaster0  Link encap:UNSPEC  HWaddr 00-23-4D-5E-A2-06-00-00-00-00-00-00-00-00-00-00

          [NO FLAGS]  MTU:0  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

```

```

joseph@joseph-micro /usr/src/linux $ sudo iwconfig

lo        no wireless extensions.

eth0      no wireless extensions.

wmaster0  no wireless extensions.

wlan0     IEEE 802.11bg  ESSID:""

          Mode:Managed  Frequency:2.412 GHz  Access Point: Not-Associated

          Tx-Power=0 dBm

          Retry  long limit:7   RTS thr:off   Fragment thr:off

          Encryption key:off

          Power Management:off

          Link Quality:0  Signal level:0  Noise level:0

          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0

          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

sit0      no wireless extensions.

```

```

joseph@joseph-micro /usr/src/linux $ sudo iwlist scan

lo        Interface doesn't support scanning.

eth0      Interface doesn't support scanning.

wmaster0  Interface doesn't support scanning.

wlan0     Interface doesn't support scanning : Network is down

sit0      Interface doesn't support scanning.

```

```

joseph@joseph-micro /usr/src/linux $ sudo dmesg | tail

[   24.934564] usb usb5: uevent

[   24.934799] usb 5-0:1.0: uevent

[   24.935302] usb usb1: uevent

[   24.935647] usb 1-0:1.0: uevent

[   24.935856] usb 1-5: uevent

[   24.936371] usb 1-5:1.0: uevent

[   24.936532] usb 1-5:1.1: uevent

[   26.810294] eth0: no IPv6 routers present

[   68.082413] ksplashx used greatest stack depth: 6108 bytes left

[   73.768727] kio_http_cache_ used greatest stack depth: 6004 bytes left

```

thanks,

Joseph

----------

## Rexilion

Try scanning with your wireless card:

iwlist wlan0 scan

And then post dmesg if any new messages are printed.

----------

## MrStill

Scanning from the wireless card outputs this:

```
wlan0     Interface doesn't support scanning : Network is down   
```

I tried my wireless switch and still got the same output.

I did not notice any extra messages in dmesg

----------

## Rexilion

 *MrStill wrote:*   

> Scanning from the wireless card outputs this:
> 
> ```
> wlan0     Interface doesn't support scanning : Network is down   
> ```
> ...

 

Try

ifconfig wlan0 up

First

----------

## MrStill

After running wlan0 up, I am able to see some access point info with scan:

```

joseph@joseph-micro /usr/src/linux $ sudo iwlist wlan0 scan

wlan0     Scan completed :                                 

          Cell 01 - Address: 00:1E:58:EA:50:D1             

                    Channel:1                              

                    Frequency:2.412 GHz (Channel 1)        

                    Quality=20/70  Signal level=-90 dBm    

                    Encryption key:on                      

                    ESSID:"Joseph"                         

                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 6 Mb/s

                              12 Mb/s; 24 Mb/s; 36 Mb/s                

                    Bit Rates:9 Mb/s; 18 Mb/s; 48 Mb/s; 54 Mb/s        

                    Mode:Master                                        

                    Extra:tsf=00000104f4c901a8                         

                    Extra: Last beacon: 367ms ago                      

                    IE: Unknown: 00064A6F73657068                      

                    IE: Unknown: 010882848B960C183048                  

                    IE: Unknown: 030101                                

                    IE: Unknown: DD0600032F010001                      

                    IE: Unknown: 2A0100                                

                    IE: Unknown: 32041224606C                          

          Cell 02 - Address: 00:26:50:C3:13:69                         

                    Channel:6                                          

                    Frequency:2.437 GHz (Channel 6)                    

                    Quality=44/70  Signal level=-66 dBm                

                    Encryption key:on                                  

                    ESSID:"BLOODSWORTH"                                

                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 6 Mb/s; 9 Mb/s 

                              11 Mb/s; 12 Mb/s; 18 Mb/s                

                    Bit Rates:24 Mb/s; 36 Mb/s; 48 Mb/s; 54 Mb/s       

                    Mode:Master                                        

                    Extra:tsf=00000001297ed6e3                         

                    Extra: Last beacon: 962ms ago                      

                    IE: Unknown: 000B424C4F4F4453574F525448            

                    IE: Unknown: 010882848B0C12961824                  

                    IE: Unknown: 030106                                

                    IE: Unknown: 0706555320010B1B                      

                    IE: Unknown: 2A0100                                

                    IE: Unknown: 32043048606C

          Cell 03 - Address: 00:1E:C7:F7:DD:39

                    Channel:6

                    Frequency:2.437 GHz (Channel 6)

                    Quality=28/70  Signal level=-82 dBm

                    Encryption key:on

                    ESSID:"thekellys"

                    Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 6 Mb/s; 9 Mb/s

                              11 Mb/s; 12 Mb/s; 18 Mb/s

                    Bit Rates:24 Mb/s; 36 Mb/s; 48 Mb/s; 54 Mb/s

                    Mode:Master

                    Extra:tsf=0000007d47bc1215

                    Extra: Last beacon: 820ms ago

                    IE: Un known: 00097468656B656C6C7973

                    IE: Unknown: 010882848B0C12961824

                    IE: Unknown: 030106

                    IE: Unknown: 0706555320010B1B

                    IE: WPA Version 1

                        Group Cipher : TKIP

                        Pairwise Ciphers (1) : TKIP

                        Authentication Suites (1) : PSK

                    IE: Unknown: 2A0100

                    IE: Unknown: 3204304860y6C

```

cell 01 is mine. Should I retry WICD now? If so, will I need to run wlan0 up on boot, or is there an easy way to have this automatically at boot?

----------

## Rexilion

 *MrStill wrote:*   

> After running wlan0 up, I am able to see some access point info with scan:
> 
> ```
> 
> joseph@joseph-micro /usr/src/linux $ sudo iwlist wlan0 scan
> ...

 

Remote all the /etc/init.d/net.* . EXCEPT for the /etc/init.d/net.lo . Then add wicd to your default runlevel and try it. If memory serves me correctly, wicd uses wpa_supplicant which in turn automatically swithes the interface on en starts scanning.

----------

## MrStill

No luck there. This time, I lost wired connection too. KDE didn't crash this time though.

After validating the security key, WICD attempts to obtain an IP address. This goes on for as long as I care to watch it.

----------

## Rexilion

 *MrStill wrote:*   

> No luck there. This time, I lost wired connection too. KDE didn't crash this time though.
> 
> After validating the security key, WICD attempts to obtain an IP address. This goes on for as long as I care to watch it.

 

Try using NetworkManager, I consider it a lot more stable though...

----------

## MrStill

Network Manager works much better. Thanks!

----------

## d2_racing

Maybe you had something inside /etc/init.d/wicd, are you sure that you run wicd at the boot level ?

----------

