Fanthomas
Posts: 2
Joined: Sun Dec 23, 2012 12:49 pm

Re: Issue with known working WIFI

Sun Dec 23, 2012 12:59 pm

I have exactly the same problem!
I bought a wifi dongle very cheaply on ebay from the US (widemac) with the RT5370 chip.
It worked once and the network manager listed my network... But connecting didn't work and from then on, nothing seems to be working any more. An iwlist scan also provides no scan results (with sudo), but everything seems to be configured the right way:
iwconfig:

Code: Select all

wlan0     IEEE 802.11bgn  ESSID:off/any  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=20 dBm   
          Retry  long limit:7   RTS thr:off   Fragment thr:off
          Power Management:on
lsusb:

Code: Select all

Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. 
Bus 001 Device 004: ID 050d:0234 Belkin Components F5U234 USB 2.0 4-Port Hub
Bus 001 Device 005: ID 05a4:9881 Ortek Technology, Inc. 
Bus 001 Device 006: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
Bus 001 Device 007: ID 046a:0023 Cherry GmbH CyMotion Master Linux Keyboard
lsmod:

Code: Select all

Module                  Size  Used by
ipv6                  232884  18 
joydev                  8808  0 
spidev                  3932  0 
arc4                    1280  2 
rt2800usb              12649  0 
rt2800lib              55680  1 rt2800usb
crc_ccitt                944  1 rt2800lib
rt2x00usb               7380  1 rt2800usb
rt2x00lib              30980  3 rt2x00usb,rt2800lib,rt2800usb
mac80211              241308  3 rt2x00lib,rt2x00usb,rt2800lib
cfg80211              147928  2 mac80211,rt2x00lib
hid_cherry              1012  0 
spi_bcm2708             4088  0 
i2c_bcm2708             2820  0 
i2c_core               20536  1 i2c_bcm2708
dmesg:

Code: Select all

...
cfg80211: Calling CRDA to update world regulatory domain
usb 1-1.3.2: reset high-speed USB device number 6 using dwc_otg
ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'
Registered led device: rt2800usb-phy0::radio
Registered led device: rt2800usb-phy0::assoc
Registered led device: rt2800usb-phy0::quality
usbcore: registered new interface driver rt2800usb
cfg80211: World regulatory domain updated:
cfg80211:   (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
cfg80211:   (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
cfg80211:   (2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
cfg80211:   (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
cfg80211:   (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
cfg80211:   (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
Console: switching to colour dummy device 80x30
NET: Registered protocol family 10
IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
smsc95xx 1-1.1:1.0: eth0: link up, 100Mbps, full-duplex, lpa 0xCDE1
EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
Does anybody have a solution? If this won't work soon, I'll buy a new dongle...

cheers,
Fanthomas

bgirardot
Posts: 518
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: Issue with known working WIFI

Sun Dec 23, 2012 2:41 pm

Have you tried this without an ethernet cable plugged in?

Have you tried the ifup command to force it up?

poing
Posts: 1132
Joined: Thu Mar 08, 2012 3:32 pm

Re: Issue with known working WIFI

Sun Dec 23, 2012 3:03 pm

Did you try to edit /etc/network/interfaces from:

Code: Select all

allow-hotplug wlan0
to:

Code: Select all

#allow-hotplug wlan0
?

With that chipset, while setting up an access point, this was the difference between 'working sometimes' and 'working always'. Maybe this also works in client mode.

The supposed issue is that the program is waiting for the dongle to be plugged-in and come up while the dongle is too fast for the program or boot process and already came up before the program started.

Fanthomas
Posts: 2
Joined: Sun Dec 23, 2012 12:49 pm

Re: Issue with known working WIFI

Sun Dec 23, 2012 5:26 pm

I've now tried to configure the interface without network manager.
It doesn't start up the interface.
My network interfaces config is the following:

Code: Select all

auto wlan0
iface wlan0 inet dhcp
        wpa-conf /etc/wpa.conf
my wpa.conf

Code: Select all

network={
        ssid="PineappleFritz"
        psk=...
}
The error I get when ifupping wlan0:

Code: Select all

wpa_supplicant: /sbin/wpa_supplicant daemon failed to start
run-parts: /etc/network/if-pre-up.d/wpasupplicant exited with return code 1
Internet Systems Consortium DHCP Client 4.2.2
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/wlan0/00:0f:53:84:20:46
Sending on   LPF/wlan0/00:0f:53:84:20:46
Sending on   Socket/fallback
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 6
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 13
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 19
^CDHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 11
DHCPDISCOVER on wlan0 to 255.255.255.255 port 67 interval 12
No DHCPOFFERS received.
Unable to obtain a lease on first try.  Exiting.
Failed to bring up wlan0.
or using wpa supplicant:

Code: Select all

pi@raspbmc:~$ sudo wpa_supplicant -Dwext -iwlan0 -c/etc/wpa.conf
rfkill: Cannot open RFKILL control device
ioctl[SIOCSIWENCODEEXT]: Invalid argument
Something seems to be wrong with wpa supplicant...

Does anybody have a solution?

cheers,
Fanthomas

blahoo123
Posts: 1
Joined: Sun Dec 23, 2012 5:29 pm

Re: Issue with known working WIFI

Sun Dec 23, 2012 5:36 pm

If you are lucky to own a reliable wifi dongle...and follow instructions with wpa_supplicant above (by mjszczesiak » Sun Jul 15, 2012 5:46 pm) then it should work.

For those who do not broadcast the SSID from their access point and still want pi to connect - simply add scan_ssid=1 to your network config in wpa_supplicant.conf:

...
network={
...
scan_ssid=1
}

poing
Posts: 1132
Joined: Thu Mar 08, 2012 3:32 pm

Re: Issue with known working WIFI

Sun Dec 23, 2012 5:37 pm

I don't have a direct solution other than start with a fresh install of the latest Wheezy distro, go to the desktop and use the WiFi Config utility. Should work with your chipset. My experience with setting up WiFi on the Pi (as an access point) is that a small change somewhere can make all the difference, so if you have been hacking about for a while you'll never get it right anymore. YMMV.

mcgyver83
Posts: 365
Joined: Fri Oct 05, 2012 11:49 am

Re: Issue with known working WIFI

Mon Mar 25, 2013 3:00 pm

I'm stuck with the same adpter, RaLink RT5370.
It's recognized by the rasp but the problem is that sudo iwlist wlan0 scan still says: "no result found"....
But when I try with wpa_gui from desktop environment and I presso "WPS button" it detects an AP but only once I had the raspberrt "paired" with the router, after 2 day again in this situation "no result found"

Pieter-Jan5000
Posts: 40
Joined: Tue Jun 12, 2012 7:20 pm

Re: Issue with known working WIFI

Thu May 30, 2013 8:58 am

freezerburn wrote:thank you craigward, this fixed my problem. i do not need a powered hub like so many other posts i've read, i knew i could get this working. the wpa.config was the major issue. if anyone is having wifi on wpa issues then use the information below!! copy and pasting wpa.config files resulted in lots of issues for me (for one, the double quotes were not "real" double quotes). this finally works!! THANKS!

Instead of using wpa.conf, try this (directly in /etc/network/interfaces):

auto wlan0
iface wlan0 inet dhcp
wpa-ssid “NETWORK SSID”
wpa-psk “NETWORK PASSWORD”
Worked for me too ... Appearantly things can be very simple sometimes!
http://www.pieter-jan.com/

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Thu Jun 13, 2013 2:21 pm

Nothing will work for me!

I've tried the wpa_supplicant method as well as the direct into /etc/network/interfaces method.

Absolute diddly!

Using a rtl8192 micro USB thingy. Apparently, according to the vendor certified for use with the Pi! He even put a link to a forum thread on the ebay listing, detailing how to install!

Sometimes when I scan it will see the AP at full signal, but most of the time it will see nothing. It's about 6 feet from the router :-(

Not happy!

J

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Thu Jun 13, 2013 3:04 pm

G0FHM wrote:Using a rtl8192 micro USB thingy.
Not helpful at all.

What does the output of command lsusb show (with your wifi adapter plugged in of course) and the output of command uname -a.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Thu Jun 13, 2013 3:12 pm

lsusb gives this:
root@svxlink:~/SWLPT-54125# lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 002: ID 0d8c:000c C-Media Electronics, Inc. Audio Adapter
Bus 003 Device 002: ID 05e3:0606 Genesys Logic, Inc. USB 2.0 Hub / D-Link DUB-H4 USB 2.0 Hub
Bus 003 Device 003: ID 0bda:8176 Realtek Semiconductor Corp. RTL8188CUS 802.11n WLAN Adapter

And uname -a
root@svxlink:~/SWLPT-54125# uname -a
Linux svxlink 3.2.0-4-486 #1 Debian 3.2.41-2+deb7u2 i686 GNU/Linux

Hope that gives some info!

J

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Thu Jun 13, 2013 3:53 pm

G0FHM wrote:Bus 003 Device 003: ID 0bda:8176 Realtek Semiconductor Corp. RTL8188CUS 802.11n WLAN Adapter

And uname -a
root@svxlink:~/SWLPT-54125# uname -a
Linux svxlink 3.2.0-4-486 #1 Debian 3.2.41-2+deb7u2 i686 GNU/Linux

Hope that gives some info!

J
I use wifi adapters with RTL8188CUS. No trouble at all.

Linux version looks odd. Guess you compiled it yourself. With i686 it looks like it's for a PC not a Pi. Are you using a PC or Raspberry Pi?

For the RPi You may need to compile a driver for it for the rtl8188cus. There is a driver included in the Linux source rtlwifi/rtl8192cu but it does not seem to work and the driver from Realtek is now used instead and is included in all current images.

In current images the driver can be found here /lib/modules/3.x.y+/kernel/drivers/net/wireless/rtl8192cu/8192cu.ko

You can find the current source here https://github.com/raspberrypi/linux/tr ... /rtl8192cu


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Thu Jun 13, 2013 4:02 pm

Oops....

Sorry, I was logged into the wrong box!

I'm trying to get it to work on a standard Wheezy box, but as you can see - it won't work on that either!

I'll try what you have suggested and report back!

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Thu Jun 13, 2013 4:17 pm

G0FHM wrote:Oops....

Sorry, I was logged into the wrong box!

I'm trying to get it to work on a standard Wheezy box, but as you can see - it won't work on that either!

I'll try what you have suggested and report back!
The simplest setup to try and get things working is to just edit file /etc/network/interfaces. Something like

Code: Select all

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-ssid "Network-name"
wpa-psk "Network-password"
Just add your own network's name and password.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Thu Jun 13, 2013 4:29 pm

Do the network SSID & Passphrase have to be in "?

If they do, then it's all done - and still not having it!

J

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Thu Jun 13, 2013 5:43 pm

G0FHM wrote:Do the network SSID & Passphrase have to be in "?

If they do, then it's all done - and still not having it!

J
Yes you need the quotation marks.


MrEngman


Edit: what do you see for the command lsusb
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Thu Jun 13, 2013 7:54 pm

lsusb output is exactly the same as I posted a while ago :-)

I'm in the process of reinstalling from scratch - i'm trying a clean install to get it running before I load anything else on.

I've ruled a faulty wlan dongle out - i've plugged it into a Win7 box, and the drivers installed ok, and was able to connect to our AP first time.

Ifconfig was showing it as communicating with the AP, as it showed packets back and forth, but for some reason it wasn't associating.

Will see what happens in a bit!

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Thu Jun 13, 2013 8:04 pm

G0FHM wrote:lsusb output is exactly the same as I posted a while ago :-)

I'm in the process of reinstalling from scratch - i'm trying a clean install to get it running before I load anything else on.

I've ruled a faulty wlan dongle out - i've plugged it into a Win7 box, and the drivers installed ok, and was able to connect to our AP first time.

Ifconfig was showing it as communicating with the AP, as it showed packets back and forth, but for some reason it wasn't associating.

Will see what happens in a bit!
Sorry my mistake, command should have been lsmod not lsusb. lsmod shows modules loaded and it should show the wifi driver, 8192cu, if it is loading OK.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Thu Jun 13, 2013 8:42 pm

rtl8190cu
rtlwifi
rtl8192c_common
mac80211
cfg80211
rfkill


Thats all relating to wlan anyway - the usbcore entry shows echi_hcd, uhci_hcd, usb_storage, rtlwifi, rtl8192cu


Trying to configure using the tool in X, it's seeing the SSID but keeps refusing the WPA key... click ok, and it tells me it's connecting and then flashes up for the key again!


Sorry i cant copy and paste output - downstairs on the android, tab! Best spend some time with the missus!

J

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Fri Jun 14, 2013 12:10 pm

G0FHM wrote:rtl8190cu
rtlwifi
rtl8192c_common
mac80211
cfg80211
rfkill


Thats all relating to wlan anyway - the usbcore entry shows echi_hcd, uhci_hcd, usb_storage, rtlwifi, rtl8192cu


Trying to configure using the tool in X, it's seeing the SSID but keeps refusing the WPA key... click ok, and it tells me it's connecting and then flashes up for the key again!


Sorry i cant copy and paste output - downstairs on the android, tab! Best spend some time with the missus!

J
OK, those entries are what I'd expect from the driver that was included originally, rtlwifi/rtl8192cu, and did not work for some reason. There have been people trying to get it working with rtl8188cus devices but I don't think they've succeeded yet.

What is the version of code you're running on the PI, command uname -a, because in the official Raspbian versions for the Pi the rtl8192cu driver was disabled sometime last year, around August time I think, and the driver from Realtek's web site was used to replace it. It would appear from the output from lsmod that you are either using an old version of code or maybe you've compiled your own kernel version. Have you compiled your own version? For official Raspbian images for the Raspberry Pi after about Aug 2012 I would expect to see 8192cu in the list from lsmod, not rtl8192cu.

If you compiled your own kernel this paragraph will be irrelevant, but something that might help if you are using some old official Pi code. I made a script that would install the working driver pretty much automatically and was quite popular at the time before the driver was included in the code. If you are using an old version of Raspbian then it may get your wifi up and running. It is available at https://dl.dropboxusercontent.com/u/802 ... -latest.sh. If you have an old version of Raspbian for the Pi then it should work. If you've compiled your own code then it almost certainly will not work. This is the original post about the script http://www.raspberrypi.org/phpBB3/viewt ... 67#p212067 but it is now rather out of date.

If you've compiled your own code from some site other than Raspberry Pi's Github then you probably need to get the driver from Realtek's site or Raspberry Pi Github, https://github.com/raspberrypi/linux/tr ... /rtl8192cu and compile that to get a working driver module. And also blacklist the non-working driver like

Code: Select all

sudo su
echo "blacklist rtl8192cu" >> /etc/modprobe.d/blacklist.conf
exit
to stop that module loading although this is not needed with current official Pi kernel versions as this driver is not compiled by default.

Info on the precise kernel version you're using would be a big help in deciding exactly what you need to do to get the wifi working, rather than offering choices which may or may not be relevant. Then we should get your wifi up and running.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Fri Jun 14, 2013 12:45 pm

Righty Ho - This is what I have.

I've installed the latest Wheezy:

pi@G0FHM-L ~ $ uname -a
Linux G0FHM-L 3.6.11+ #464 PREEMPT Thu Jun 6 18:17:55 BST 2013 armv6l GNU/Linux
pi@G0FHM-L ~ $ lsmod
Module Size Used by
snd_bcm2835 16304 0
snd_pcm 77560 1 snd_bcm2835
snd_page_alloc 5145 1 snd_pcm
snd_seq 53329 0
snd_seq_device 6438 1 snd_seq
snd_timer 19998 2 snd_pcm,snd_seq
snd 58447 5 snd_bcm2835,snd_timer,snd_pcm,snd_seq,snd_seq_device
8192cu 490353 0
leds_gpio 2235 0
led_class 3562 1 leds_gpio
pi@G0FHM-L ~ $


Just downloaded and ran the setup script after blacklisting (just in case).... All sorted!

Sweet!

Thanks :-)

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Fri Jun 14, 2013 3:38 pm

G0FHM wrote:Righty Ho - This is what I have.

I've installed the latest Wheezy:

pi@G0FHM-L ~ $ uname -a
Linux G0FHM-L 3.6.11+ #464 PREEMPT Thu Jun 6 18:17:55 BST 2013 armv6l GNU/Linux

Just downloaded and ran the setup script after blacklisting (just in case).... All sorted!

Sweet!

Thanks :-)
Great to hear you've fixed it. Now you can get back to your real radio.

I'm a little curious about your setup. Is this the same image that showed the rtl8192cu driver in lsmod? Just a little unsure where the rtl8192cu drive appeared from as it's not included in current versions of Raspbian (wheezy) and hasn't for a long time now. Is it an old image that you've upgraded/updated - that is about the only thing I can think of that would explain why it is there. A rather unusual situation but something to bear in mind if it is.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

G0FHM
Posts: 15
Joined: Thu Jun 13, 2013 2:14 pm

Re: Issue with known working WIFI

Fri Jun 14, 2013 5:27 pm

No, it's a different image - the one I have put on now is 2013-05-29, the previous image was on a SD card given to me by a friend, as at the time I had no method of reading/writing SD's so it could have been anything!

The next challenge is to get the same adapter working on the laptop that is running Wheezy (I bought 2 off of ebay I only have a 4 port switch in the shack and they are all used!). I plan to use the Pi for svxlink (echolink) and the laptop for AllStar Link (If I could configure a module in svxlink for ASL, then it would be a bonus, but I asked on the devel list, and I got blank answers!).

Yesterday I was fretting severely, and had multiple SSH windows open - and I think at least once I pasted bogus data from the laptop, hence the i686 stuff that appeared!

It's all working well now - still trying to get the laptop up and running on wireless as per the Wiki, but it seems to be having the driver issues still. I did a "Network install" last night, where it pulled the latest packages down to install, and followed the step by step instructions but it did the same as what the Pi was doing wit the old image. But, that's not Pi, so I'll keep quiet about it!

Thanks for your help, I'm off to play real radio! :-)

J

KayKallis
Posts: 4
Joined: Sun Jun 16, 2013 4:36 pm

Re: Issue with known working WIFI

Sun Jun 16, 2013 4:57 pm

Many thanks to everyone on this thread for helping to work through these issues. I have been struggling to get things working as well.

My configuration is a Raspberry Pi Model B with a element14.com Wi-Pi wireless USB dongle (aka Ralink Technology, Corp. RT5370 Wireless Adapter). I've spent plenty of hours trying to get a proper configuration working. I've tried multiple settings with (and without) wpa_supplicant, but I seem to be stuck now. The good news it works, but only sort-of, and only when I have both a wireless and hardline connection.

ISSUE: I can get Wireless and Ethernet hardline working properly with the following setup, but if I disconnect the hardline and reboot the box, the wireless appears to be up (the dongle is glowing and the router shows its presence) though the system allow me to SSH in via wireless. Once I reconnect the hardline (hotplug while powered on), then everyone starts working fine and I can SSH in via wireless. My goal is to have a flexible configuration where I can use the Pi with or without a hardline.

Any suggestions?

Code: Select all

# /etc/network/interfaces
#
# Raspberry Pi Network Configuration
#
# (1) BRING UP LOOPBACK INTERFACE
#

auto lo
iface lo inet loopback

# (2) BRING UP WIRELESS INTERFACE
#   Hardware is the Wi-Pi USB from element14.com
#   Ralink Technology, Corp. RT5370 Wireless Adapter
#

auto wlan0
iface wlan0 inet static
wpa-ssid        <MY SSID>
wpa-psk         <MY PASSPHRASE>
address 192.168.1.98
netmask 255.255.255.0
network 192.168.1.0
gateway 192.168.1.2
broadcast 192.168.1.255
# set metric to highest priority
metric 10


# (3) BRING UP THE ETHERNET INTERFACE
#

# automatically bring up eth0 at boot
#auto eth0
# allow eth0 to be recognized if plugged in post-boot
allow-hotplug eth0
# start eth0 using static address
iface eth0 inet static
# specify static address
address 192.168.1.97
# specify network mask
netmask 255.255.255.0
# specify router's gateway address
gateway 192.168.1.2
# specify network
network 192.168.1.0
# set metric to lowest priority
metric 100

Thanks in advance to any and all who can help solve this!

MrEngman
Posts: 4140
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: Issue with known working WIFI

Mon Jun 17, 2013 7:59 pm

KayKallis wrote:ISSUE: I can get Wireless and Ethernet hardline working properly with the following setup, but if I disconnect the hardline and reboot the box, the wireless appears to be up (the dongle is glowing and the router shows its presence) though the system allow me to SSH in via wireless.
You appear to say SSH is working with just the wifi connected - do you really want to say it is NOT working - as you say it only works with both wifi and Ethernet cable connected.
KayKallis wrote:Once I reconnect the hardline (hotplug while powered on), then everyone starts working fine and I can SSH in via wireless. My goal is to have a flexible configuration where I can use the Pi with or without a hardline.

Any suggestions?

Code: Select all

# /etc/network/interfaces
#
.
.
auto wlan0
iface wlan0 inet static
wpa-ssid        <MY SSID>
wpa-psk         <MY PASSPHRASE>
address 192.168.1.98
netmask 255.255.255.0
.
.
Thanks in advance to any and all who can help solve this!
I have seen many people say you need quotation marks (") around <MY SSID> and <MY PASSWORD> like

Code: Select all

wpa-ssid "MY SSID"
wpa-psk "MY PASSPHRASE"
I have come across strange issues caused by file /etc/network/interfaces being setup in odd ways. Also I've never seen metric used in that file before. Do you really need it? What happens if you comment out the lines with metric?

I have wifi and wired connections and can SSH using both or just one and also if I have no wired connection I can SSH in with wifi OK. Also I don't need allow-hotplug eth0 to get the Ethernet to reconnect if I unplug it and then plug it back in later or if I boot with the Ethernet cable disconnected and then plug it in. My /etc/network/interfaces file looks like

Code: Select all

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-ssid "sssid"
wpa-psk "password"
I use DHCP but once a particular IP has been set it usually stays at that same IP when rebooting.

MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

Return to “Beginners”