PDA

View Full Version : Raspi boot problems


rans6andrew
24th Nov 2012, 17:18
Have we any Pi gurus on here? I have a bit of a problem getting mine to work with a WiFi adaptor.

My Pi shows some odd behaviour during initial boot up. I started with a pre loaded OS from CPC in September and have sudo apt-get updated it this week. During the boot process, when an excess of text runs up my screen, I see that wlan0 gets changed to wlan1 (Ican't remember the exact words) and then the following errors appear (I had to photo the screen to read it!)



"configuring network interfaces...wpa_supplicant: /sbin/wpa_supplicant daemon failed to start
run-parts: /etc/network/if-pre-up.d/wpasupplicant exited with return code 1
Failed to connect to wpa_supplicant - wpa_ctrl_open: no such file or directory
wpa_supplicant: /sbin/wpa_cli daemon failed to start
run-parts: /etc/network/if-up.d/wpasupplicant exited with return code 1
done."


Predictably, the wlan doesn't work, never has, although to be fair I have only just been through the very complete driver instructions found at

home automation - D.I.Y. Home Automation Projects - Raspberry Pi - Installing the Edimax EW-7811Un USB WiFi Adapter (WiFiPi) (http://www.savagehomeautomation.com/projects/raspberry-pi-installing-the-edimax-ew-7811un-usb-wifi-adapte.html).

I have the Edimax WiFi dongle referred to on that page.

I am a newbee at this. Can someone explain the above errors, why the waln0 gets changed to wlan1, how to slow the boot script so that I have time to read some of it and what I need to do to get my wireless working?

Ta,

Rans6....

Milo Minderbinder
24th Nov 2012, 18:29
I know next to nowt about Linux, but to my way of thinking you've not got the drivers for the wifi installed
Given that - according to that report - the latest OS version has the drivers already included, I'd take the cowards way out, nuke the operating system and start again with the new version. No point peeing around with out of date stuff at the rate this kind of software is evolving

green granite
24th Nov 2012, 19:36
Thank you, I now remember why I decided to abandon xxnix a few years ago. :E

MacBoero
24th Nov 2012, 21:39
Have you visited Raspberry Pi | An ARM GNU/Linux box for $25. Take a byte! (http://www.raspberrypi.org) yet?

The forum there is very good.

le Pingouin
25th Nov 2012, 11:55
To display the text that's whizzed past:

dmesg | more

To display the text that's probably relevant (this displays lines containing "wlan"):

dmesg | grep wlan


For a start show us what you get for the first three commands as per the web page you mentioned (slightly modified to only show relevant parts):

lsusb | grep Edimax

lsmod | grep 8192cu

iwconfig


Copy and paste by left clicking and dragging to highlight the relevant text in the terminal window, then centre click to paste.

rans6andrew
25th Nov 2012, 18:25
if only I could copy and paste.....

the other issue I am struggling with is a browser (Midori) that doesn't launch properly. It opens it's window and puts an error message in the top bar, something about http://wwwwwwwwwwwwwww. something or other. Yep, about 10 "W"s in the URL. It also has an error box in the middle of the browser window and mention of dial up failure. There is neither menu buttons nor address bar nor favourites but I can open a second useless tab and some help file stuff. When I can get my WiFi to connect I might start trying to fix the browser but right now it is a low priority.

re: the web page I mentioned, I get the correct responses (ie the same as the page shows but with wlan1 in every instance of wlan0) all of the way down to where it says it will restart the wlan1, it doesn't.

I will run up the Pi and type what I see for you soon.

Ta, Rans6....

rans6andrew
25th Nov 2012, 18:59
le Pingouin, thanks for your help.

for dmesg | more I see:

much stuff and then

usbcore: registered new interface driver rtl8192cu
udevd[179]: renamed network interface wlan0 to wlan1

and then much stuff.

dmesg | grep wlan produces:

udevd[179]: renamed network interface wlan0 to wlan1

and

ADDRCONF(NETDEV_UP): wlan1: link is not ready

lsusb | grep Edimax produces:

Bus 001 Device 004: ID 7392:7811 Edimax Technology Co., Ltd EW-7811Un 802.11 Wireless Adapter [Realteck RTL8188CUS]

and

lsmod | grep 8192cu produces:

8192cu 485042 0

and finally, iwconfig produces:

exactly what it shows in the webpage instructions except for wlan1 in place of wlan0.

Thanks again, I am learning as I go along, dmesg, grep and more seem to be useful, must write them down.

Rans6.....

le Pingouin
26th Nov 2012, 01:13
In the configuration details & the subsequent commands try changing wlan0 to wlan1.

rans6andrew
26th Nov 2012, 22:48
I did change 0 to 1 on the first run through the instructions!

rickity
27th Nov 2012, 21:26
Having just gone through the experiance of connecting wifi to the pi, which was painful to say the least, some lessons I learnt were. the wifi dongle must be on a powered usb adaptor of no more than 4 ports, using a dongle directly connected to the pi gave inconsistant results, using more than 4 ports corrupted the operating system. downloading a fresh OS was by far the quickest way of getting back to square one. using a cable ethernet connection even though a wireless connected PC and using ICS (internet connect sharing) to get the latest updates is very useful. get all the lastest updates by using apt-get update and apt-get install, takes a little time but is worth doing. if your using wpa-conf and/or interfaces to set up your connection, accuracy of typing is critical, I left out a "}" in wpa-conf and got a similar result you posted in your first post. and finally using a clean fully updated os I went for WICD as a connection manager and it work as advertised.

I'm left with just one wee problem although fully connected to the internet and can surf anywhere, I cant ping anything on the local network, but i can connect remotely from a local PC using ssh.

Good luck.

Rick

Saab Dastard
27th Nov 2012, 22:04
I can't ping anything on the local network, but I can connect remotely from a local PC using ssh.

What are you pinging - and is it configured not to respond, e.g. Windows firewall?

SD

rickity
28th Nov 2012, 19:55
Hi SD

I can ping all around the local network with all the other PC's and Laptops ( all windows) but not from the PI not even the router that it successfully gets its DHCP from. So I think its a pi/debain issue. even with a network analyser utility where I can see it pushing out icmp packages with successfull returns from Google (http://www.google.co.uk) and the likes but not from 192.168.1.x. masks and gateways look ok. wired ethernet pings appear ok, but with the wire disconnected and the ping forced to use the wifi interface no result. It doesnt seem to feature as a common issue on the PI forums - getting wifi to work in the first place does but not this particular problem. whilst intriguing I aint got too much more hair to pull out over it :confused:

Rick

le Pingouin
29th Nov 2012, 06:22
rans6andrew, does the following file exist and what are the contents:

/etc/wpa_supplicant.conf

Saab Dastard
29th Nov 2012, 17:54
rickity,

It's a little confusing:

I can ping all around the local network with all the other PC's and Laptops ( all windows) but not from the PI
wired ethernet pings appear ok

Is it just wireless you have a problem with??

Since you've got a packet analyser to hand, what do you see when you ping from the pi to a local address? Do you see packets sent out? Do you see responses, even if the rpi doesn't get them? Can you look at traffic on all the switch ports (monitor port)?

Does the rpi respond when pinged by something on the LAN?

Have you got both wired and wireless going at the same time (and have they got different IP addresses)?

What does the ARP table look like, both for a Windows PC pinging the rpi and vice-versa? Troubleshooting this might come down to MAC layer.

SD

rans6andrew
29th Nov 2012, 21:42
Le Pingouin, the file does exist, although it is one level further down the directory structure, ie /etc/wpa_supplicant/wpa_supplicant.conf. The instruction webpage referred to in my post #1 has you create the file and it's contents, see the page and look almost exactly half way down.

Is the file in the wrong location? I can move/copy it if you think it might help.

Thanks, Rans6...........

rickity
29th Nov 2012, 22:08
SD

its just the wireless that has the problem.

Packet analyser sees packets sent but no returns to local pings, it does see returns from internet pings.

Rpi does not respond to pings from the local network on wireless, but does on wired

Arp table has the wireless router address which is designated as a gateway but nothing else (tried adding routes but at extreme edge of knowledge on that)

tried not to have wireless and wired at the same time to prevent the confusion you allude to.

1 step forward, I eventually managed to make the local PC a wireless hotspot and make a wireless connection to it from the pi, lo and behold i can ping whatever successfully including the router. so my theory at the moment is power related in that some how the pi scans for wireless routers on high power gets the dhcp then reduces power which is insufficient for a ping. (signal strength to the router is around 30-40%) as the hotspot is feet away signal strength is 99% and ping works as expected. well thats the best I can come up with at the moment.

Rick (appologise to rans6 for hijacking his post a bit but something might be relevent)

rickity
29th Nov 2012, 22:12
I'm not sure that you really want wpa_supplicant.conf, the file that has the configuration that you want to look at is /etc/wpa.conf which should have the details of ssid, wpa, etc assuming your using the debian os

Rick

rans6andrew
30th Nov 2012, 10:34
I am expecting to get a couple of SD cards in the post today. I am going to start over with a clean download of debian. I have trouble with Midori not opening properly as well as the troubles with the WiFi software and suspect there may be corruption of the SD card image from CPC. On the plus side I have written a "hello whirled" in C and it compiles and runs.

Don't know when I will get time to play, my Ma is in hospital awaiting a pacemaker op so this issue is not at the top of my priorities list.

Thanks for you continued assistance, I do appreciate it.

Rans6....

rans6andrew
5th Dec 2012, 19:18
haha! I fetched a completely fresh wheezy download and put it onto a new sdcard and the wlan0 to wlan1 re-assignment has stopped happening. I still don't have WiFi connecting but at least the messages relating to wpa_supplicant daemon failure have stopped happening. I guess I need to work through the original WiFi instructions as per post #1

Rans6....

rans6andrew
5th Dec 2012, 20:21
I found a network config utility on the Pi desktop and used it to enter my ssid and network key. Now I can ping my desktop computer from my Pi and vice versa but I can't ping anything outside of my home network.

This seems to be exactly opposite to the issues that someone has hijacked my thread with!

Help!

Ta,

Rans5......

rans6andrew
5th Dec 2012, 20:22
ps "ping 8.8.8.8 responds with connect: Network is unreachable"

Rans6.......

rans6andrew
5th Dec 2012, 20:31
pps: I can ping and browse the www if I plug the ethernet in. Something in the WiFi setup does not let me get past my router.

mmmmm.

Rans6......

Milo Minderbinder
5th Dec 2012, 20:45
Andrew

at a rough guess
what have you set the DNS server and default pathway as on the Pi?

rans6andrew
5th Dec 2012, 20:49
Milo, now you've got me. I didn't find any reference to DNS server or pathway in the network config thingy on the Pi desktop.

Can you point me to where else I should have been to set these up? (and what I might need to set them to?)

Rans6......

Milo Minderbinder
5th Dec 2012, 22:37
sorry, don't know, but it must be there somewhere

rans6andrew
6th Dec 2012, 08:43
Got it! If I reboot with the ethernet cable unplugged from the Pi the WiFi sorts itself out with the info I set in the desktop WiFi config tool. Sorted.

Ta for the help you all gave, it has been a bit of a steep learning curve for me, good though.

Rans6.....