wicd - stuck "Obtaining IP Address..." - my fix

YDL running on the Sony Playstation 3

Moderator: billb

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby sun » 13 May 2009, 03:50

sun wrote:I've tried to write code into wicd's monitor to check for this case, and have had luck with auto-reconnect, but it also seems to break code in the gui.py. The issue now is that wicd-client displays the connect button while it is currently connected instead of the disconnect button. If I can get by this I will try to post something.
-sun


... and here it is. It's simple and crude, but wicd will now drop connection and try to reconnect if your iwconfig Access Point: value changes to anything other than a valid MAC Address (ie. "Not-Associated")

wicd-1.5.9_patched.tar.gz
wicd v1.5.9 patched tarball installer
**includes**
"Stuck Obtaining IP Address" fix
"0% Signal Strength" fix
"Auto-Reconnect" fix
(250.68 KiB) Downloaded 704 times

Since multiple files needed to be edited for this one, I've decided to post it as a modified installer tarball. The good news is, by installing this, you don't have to worry about any of my other patches because they're already in here. Should you wish to try this out, I have provided basic install instructions below. It's a pretty simple tarball install.

Intructions:
( * ) = must be done as logged in as root, or through a su - or sudo console

Step 1*: Backup and delete all files located in /usr/lib/wicd/
Step 2*: Backup and delete all files located in /usr/lib/python2.x/site-packages/wicd/ <-- x could be 4 or 5 depending on python version installed
Step 3: In console, extract tarball with the command tar-zxvf wicd-1.5.9_patched.tar.gz <-- this will extract the files to a folder called wicd-1.5.9_patched
Step 4: In console, type cd wicd-1.5.9_patched to enter that folder
Step 5: In console, type python ./setup.py configure <-- this will gather information about your system and prep for install
Step 6: If not done already, type su - and when prompted, type your root password to root yourself
Step 7*: In console, type python ./setup.py install <-- this will copy all the files to where they need to be
Step 8: Finally. reboot

*disclaimer* -- This tarball is provided "as-is." Although I have tested it on my system following the instructions above, I cannot guarantee that it will work on your system. I will also not be held accountable for any damage YOU do using this file. That said, if it doesn't work let me know and I may be able to get it going.

-sun
Last edited by sun on 19 May 2009, 01:26, edited 3 times in total.
User avatar
sun
ydl beginner
ydl beginner
 
Posts: 47
Joined: 27 Dec 2008, 05:30

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby ppietro » 13 May 2009, 05:30

sun wrote:... and here it is. It's simple and crude, but wicd will now drop connection and try to reconnect if your iwconfig Access Point: value changes to anything other than a valid MAC Address (ie. "Not-Associated")

wicd-1.5.9_patched.tar.gz


Hi everyone,

Just thought I'd point out that this is not the wicd that comes by default with YDL 6.1. So - for all the beginners - let me make this clear: You can't apply this particular patch on a default YDL 6.1 installation.

The version of wicd that comes with is 1.5.3. wicd 1.5.9 must be custom installed on YDL 6.1.

Cheers,
Paul
User avatar
ppietro
Site Admin
Site Admin
 
Posts: 4965
Joined: 13 Sep 2007, 22:18

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby sun » 13 May 2009, 15:42

ppietro wrote:Just thought I'd point out that this is not the wicd that comes by default with YDL 6.1. So - for all the beginners - let me make this clear: You can't apply this particular patch on a default YDL 6.1 installation.

The version of wicd that comes with is 1.5.3. wicd 1.5.9 must be custom installed on YDL 6.1.


To further clarify, this is a modified version of the wicd v1.5.9 source installer tarball that is available on http://www.wicd.net under the stable development branch. This installer is the full 1.5.9 version and has the patches already applied. For those users familiar with installing from a source tarball and those that have installed v1.5.9 already, you would install this just as you would with the standard wicd-1.5.9 tarball install. You do not need to have wicd already installed to use this installer, and do not need to download any other files. When complete you will have a full install of wicd v1.5.9 with the patches applied.

-sun
User avatar
sun
ydl beginner
ydl beginner
 
Posts: 47
Joined: 27 Dec 2008, 05:30

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby ppietro » 14 May 2009, 06:55

sun wrote:To further clarify, this is a modified version of the wicd v1.5.9 source installer tarball that is available on http://www.wicd.net under the stable development branch. This installer is the full 1.5.9 version and has the patches already applied. For those users familiar with installing from a source tarball and those that have installed v1.5.9 already, you would install this just as you would with the standard wicd-1.5.9 tarball install. You do not need to have wicd already installed to use this installer, and do not need to download any other files. When complete you will have a full install of wicd v1.5.9 with the patches applied.


So - I'm not familiar with the wicd source installer tarball. Should folks with stock YDL 6.1 and wicd 1.5.3 attempt installing this?

It would sound to me like beginners should stay away from this for the time being. At least, I would think they should uninstall 1.5.3 before installing this, or RPM/YUM will get confused.

Thoughts, sun? I just want to make sure that beginners don't get confused here. :D

Cheers,
Paul
User avatar
ppietro
Site Admin
Site Admin
 
Posts: 4965
Joined: 13 Sep 2007, 22:18

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby sun » 14 May 2009, 12:02

ppietro wrote:So - I'm not familiar with the wicd source installer tarball. Should folks with stock YDL 6.1 and wicd 1.5.3 attempt installing this?

It would sound to me like beginners should stay away from this for the time being. At least, I would think they should uninstall 1.5.3 before installing this, or RPM/YUM will get confused.


This Q is a tough one to answer. IF users are happy with the patched 1.5.3 wicd installation, THEN they certainly don't HAVE to install this and can run on 1.5.3. One has to weigh the pros/cons of upgrading or not.

Users like monkey have uppped to v1.5.9 and he is still having issues even with my patch (I'm not suprised either). Since wicd v1.5.9 RPMs are hard to come by, I assume that monkey has followed the source tarball procedure for a his v1.5.9 install, and then applied my patch. I have also upgraded my YDL6.1 and Fedora10 systems to each successive wicd version this way as well. Which is why I have posted patches for several wicd versions. Since this last patch required several files to be edited, I decided to roll them all back into the source installer, to make the process as simple as possible.

Installing a package from a source tarball is the 'old skool' pre-RPM way of going about it. RPM came about as a way to bypass the compiling and to easily manage and update installed packages, since you can have 2000+ packages on a 'basic' linux install. Installing from a source tarball is also the first step in creating an RPM for many software packages. The term 'tarball' just refers to the .tar.gz file format that these source packages often come in. Since installing from source does bypass the RPM package manager, it will not register as an installed package in YUM. Users attempting this install with a wicd version already installed from YUM/RPM should first uninstall wicd using YUM/RPM to avoid any package confusion. However, I didn't bother doing this with my systems and have not run into any issues yet. I do have to keep in mind that my wicd version is not RPMed. If a new wicd RPM is added to the YUM repos, it may complain about conflict files if I again attempt to install wicd via YUM. This is a minor issue that I am willing to shrug off since it's the only package I have to be mindful of.

Although you don't have to go and install evertying from source, my opinion is that anyone using linux or any *nix OS for any extended period of time should become familiar with the 'from-source' install proceedure. Not all packages come in ready made RPMs. Most developers (the wicd people included) don't bother to create them. Instead, they rely on the community and distro providers to do that for them. I would create an RPM for the patched wicd v1.5.9 myself, if I didn't have notoriously bad luck doing so.

This source tarball install proceedure is pretty much straight forward in most cases. Almost all source installers use these commands: tar -zxvf <package>.tar.gz, cd <package>, ./configure, make, make install in that order. Most come with an INSTALL text file in the tarball to outline the specifics, so read that first. The most common issues are dependencies, which the ./configure command will inform you of and will usually not let you continue untill resolved. Users attempting a source install for the first time should first read up on the subject and start with a simple package to get a feel for things. It may at first feel like a daunting task, but in time it will become a no-brainer. That said, wicd, although slightly different in terms of the commands used, is a very simple install.

I think of it in this light. If the repos don't have what I want. I'll get 'old skool.'

-sun
User avatar
sun
ydl beginner
ydl beginner
 
Posts: 47
Joined: 27 Dec 2008, 05:30

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby ppietro » 14 May 2009, 21:04

sun wrote:This source tarball install proceedure is pretty much straight forward in most cases. Almost all source installers use these commands: tar -zxvf <package>.tar.gz, cd <package>, ./configure, make, make install in that order.


Oh - okay - yeah - I'm very familiar with that procedure. I thought you were referring to some kind of wicd-specific installer tarball. I just call that building and installing from source instead of source tarball install (tomehto, tomahto, right? :D )

So - yeah - I would recommend that beginners not install this for the time being. It won't register in YUM/RPM, plus most beginners don't install the software developer's package during installation, so gcc, make, etc. aren't present.

Obviously, though, if you're comfortable building from source, this is the way to go. :D

Cheers,
Paul
User avatar
ppietro
Site Admin
Site Admin
 
Posts: 4965
Joined: 13 Sep 2007, 22:18

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby sun » 14 May 2009, 21:24

ppietro wrote:Oh - okay - yeah - I'm very familiar with that procedure. I thought you were referring to some kind of wicd-specific installer tarball. I just call that building and installing from source instead of source tarball install (tomehto, tomahto, right? :D )

So - yeah - I would recommend that beginners not install this for the time being. It won't register in YUM/RPM, plus most beginners don't install the software developer's package during installation, so gcc, make, etc. aren't present.


wicd is unique in that its source is a python scipt and not gcc code and is never compiled, it's components are merely copied to where they need to be. This is why it's install method is different. You don't need gcc or make installed to get it going. Python is really the only requirement, and if it's not installed you won't get anywhere with the command python ./setup.py configure.

-sun
User avatar
sun
ydl beginner
ydl beginner
 
Posts: 47
Joined: 27 Dec 2008, 05:30

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby ppietro » 15 May 2009, 06:07

sun wrote:wicd is unique in that its source is a python scipt and not gcc code and is never compiled, it's components are merely copied to where they need to be. This is why it's install method is different. You don't need gcc or make installed to get it going. Python is really the only requirement, and if it's not installed you won't get anywhere with the command python ./setup.py configure.


That does sound easier - but what I would really like for beginners is an RPM that could be installed, and that would update the existing 1.5.3 to the patched 1.5.9 - possibly with a custom RPM build number (i.e. 1.5.9-ydltest1, etc.). The original patch was safe enough because it replaced one file, but anything "source installing" starts to get into situations where I might have to handhold a beginner step by step through a system recovery, manually deleting files, copying others, resetting chkconfig, etc.

When I get back to my computers, I could try putting together a 1.5.9 RPM using your new code modifying a 1.5.3 SRPM. That might do the trick.

Otherwise, I would think we should modify your procedure to include the RPM uninstallation of 1.5.3. Hopefully, if we do this, the 1.5.9 python install script will create the appropriate wicd startup scripts in /etc/init.d and create the symbolic links for the run levels accordingly. If it doesn't, and the only way this works in YDL is to install 1.5.3 via RPM, then overwrite all of the files with patched 1.5.9, this may not be the best solution for a beginner.

It's been my experience that keeping things simple leads to less problems later. :D

Cheers,
Paul

P.S. Have you considered contributing this code back to the wicd folks in some way? You're doing a lot of valuable work here. :D
User avatar
ppietro
Site Admin
Site Admin
 
Posts: 4965
Joined: 13 Sep 2007, 22:18

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby sun » 19 May 2009, 01:04

ppietro wrote:P.S. Have you considered contributing this code back to the wicd folks in some way? You're doing a lot of valuable work here. :D


I have tried in the past, but was unable to connect to any freenode irc server, where the #wicd channel is located. Since you asked, I tried once again and was suprised to find that I was able to connect. I informed the wicd developers of the issues we are experiencing, and they grabbed copies of my posted patch to tear apart. They also informed me that the method I used to fix the IP address issue was not the best. Wicd handles commands internally as a list variable to better handle SSIDs with spaces, and I changed the affected command to a string. This way, users with space characters in their SSIDs may still have an issue. Regardless of this, wicd also converts the string back to a list just before dumping the command to the command line. With this list/string issue in mind I looked over my code again and noticed something that also wasn't in the original code. I had wrapped the SSID in "s, something that should not be needed for iwconfig essid. I decided to try the original code with the addition of "s around the SSID and it worked, both in 1.5.9 and 1.6.0b1. I again shared this information with the wicd developers. At this point they informed me that they have looked at all the issues and may have them resolved for the next version, but need to complete further testing before releasing. I will try any updates to the 1.6.0b code, and keep them posted. In the interim I have again rolled the updated code back into the 1.5.9 source tarball and will update my previous post with the updated version. I have tested this on my system already, but again I request anyone trying this to report back on their success or failure.

You can also grab the newest wicd 1.5.9 patched source tarball here
download/file.php?id=119

-sun
User avatar
sun
ydl beginner
ydl beginner
 
Posts: 47
Joined: 27 Dec 2008, 05:30

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby sun » 07 Jun 2009, 20:09

... adding patch for wicd v1.6.0. All issues reported to the developers have been resolved, except the issue obtaining IP address. I have applied my patch to v1.6.0 as well to allow it to connect.

wicd v1.6.0
wnettools.py.tar.gz
wnettools.py v1.6.0 -
YDL 6.1: extract and place in /usr/lib/python2.4/site-packages/wicd/
Fedora 10: extract and place in /usr/lib/python2.5/site-packages/wicd/
(11.07 KiB) Downloaded 501 times

-sun

p.s. I have also created a fully patched source tarball. However, since there is only one file that needs replacement and the source tarball is larger than the board allowed max filesize, I have not posted it.
User avatar
sun
ydl beginner
ydl beginner
 
Posts: 47
Joined: 27 Dec 2008, 05:30

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby mellofello » 09 Jun 2009, 16:15

Hi guys first of I am very very new to Linux. Never even seen what it looks like till yesterday so please explain anything even if you think it is super obvious (you have no idea how long I have spent trying to swap files to add the patch, hours taken to realise that I can log out and log back in as root)

Anyway so I installed yellowdog 6.1 or what ever the latest is. I just figured out how to replace the relevant file in wicd to get the patch to work for version 1.5.3. Before that wicd said that it was conected to my wireless network at 0% and wouldn't load anything when trying to use firefox. Now after swapping file and rebooting it says that it is connected at about the same % as the signal strength coming from the router. However still when I open firefox nothing will load. I've tried google and a few other sites but nothing works.

So would installing a newer version of wicd help? If so which one and how? do I need to install any inbetween steps?

Perhaps I haven't set it up right to use the wireless internet connection? Something I should have done aswell as the wicd patch?

I cannot stress how new I am to this I REALLY KNOW NOTHING! I'm fine when it comes to windows but linux seems quite a different beast. Whats all this command input stuff ey?!?!? Seriously though there were bits in some of the guides where I felt steps were possibly missing and abit too much previous knowledge was assumed so go easy on me.

Any help much appreciated guys

peace

mello
mellofello
ydl newbie
ydl newbie
 
Posts: 4
Joined: 09 Jun 2009, 15:59

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby ppietro » 09 Jun 2009, 19:23

mellofello wrote:Hi guys first of I am very very new to Linux. Never even seen what it looks like till yesterday so please explain anything even if you think it is super obvious (you have no idea how long I have spent trying to swap files to add the patch, hours taken to realise that I can log out and log back in as root)


Or - if you'd followed the steps here - you could have just used the su command :D

viewtopic.php?f=19&t=4534#p24084

Anyway so I installed yellowdog 6.1 or what ever the latest is. I just figured out how to replace the relevant file in wicd to get the patch to work for version 1.5.3. Before that wicd said that it was conected to my wireless network at 0% and wouldn't load anything when trying to use firefox. Now after swapping file and rebooting it says that it is connected at about the same % as the signal strength coming from the router. However still when I open firefox nothing will load. I've tried google and a few other sites but nothing works.


This sounds like an authentication error, somehow. Are you sure you're using the right encryption type for your wireless access point? Password okay, etc?

If you had to manually enter your IP address, subnet mask, etc. to connect to your wireless access point, then, 9 times out of 10, you have an encryption error - most likely incorrect password. Entering this information manually bypasses the encryption check and connects you to the access point - even if you can't decrypt anything it sends you.

Cheers,
Paul
User avatar
ppietro
Site Admin
Site Admin
 
Posts: 4965
Joined: 13 Sep 2007, 22:18

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby mellofello » 10 Jun 2009, 12:57

Thanks Paul,

I did try the su method entering commands into the terminal but for some reason I couldn't get it to overrite the file. I'm sure it was down to me making an error somewhere with what I typed in but I tried quite a few times with no luck.

I did manually enter all of my connection details such as IP, subnet mask and DNS. I called my broadbnd provider and got them to give me them so I'm pretty sure they are correct. If it makes a difference I have a static IP. My router uses WPA and I've tried both of the WPA options, the first works fine in that it connects but the other type of WPA doesn't work.

I'll try it again and see if I have better luck

peace

mello
mellofello
ydl newbie
ydl newbie
 
Posts: 4
Joined: 09 Jun 2009, 15:59

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby ppietro » 10 Jun 2009, 19:21

mellofello wrote:Thanks Paul,

I did try the su method entering commands into the terminal but for some reason I couldn't get it to overrite the file. I'm sure it was down to me making an error somewhere with what I typed in but I tried quite a few times with no luck.


Hmmm - that doesn't sound right. If you're su you should be able to anything you want. If you look on my post here:
viewtopic.php?f=19&t=4534#p24084
you enter su first, give it your password, then, without closing the window, keep entering commands. If you close the window, you lose the "su", if you will. (Technical explanation - the terminal window is what we call a "process" in Unix-speak. Entering su in the terminal window switches the terminal window's process owner from you to root. A process running as root has absolute rights on your system)

mellofello wrote:I did manually enter all of my connection details such as IP, subnet mask and DNS. I called my broadbnd provider and got them to give me them so I'm pretty sure they are correct. If it makes a difference I have a static IP. My router uses WPA and I've tried both of the WPA options, the first works fine in that it connects but the other type of WPA doesn't work.


Ah - this gets to an interesting question.

Do you have a Wireless Access Point - or a Wireless Access Point Firewall/Router? These are two different things. A wireless access point simply puts your computer on your network via wireless - it's the same as having a phantom ethernet jack floating in the air. A wireless access point firewall/router has its own internal network that connects to your network.

If your broadband is static, but you connect via a wireless access point firewall/router, you wouldn't use your static addresses for that. Anything that connects to the wapf/r (my own acronym!) would be on a sub-net, usually DHCP controlled.

It sounds like your WPA authentication settings are correct. I would try connecting with DHCP, instead of manually entering IP information. My guess is that your wireless is firewalled/routed, and has its own network, which doesn't understand your static IP.

(And - yes - this is the way I run at home. :))

If you do have a pure wireless access point, it won't have a DHCP server, and we might have to look at your broadband connection a little closer.

Cheers,
Paul
User avatar
ppietro
Site Admin
Site Admin
 
Posts: 4965
Joined: 13 Sep 2007, 22:18

Re: wicd - stuck "Obtaining IP Address..." - my fix

Postby mellofello » 12 Jun 2009, 14:55

Ok so I tried unchecking the use static IP box in the advanced settings for the connection in wicd manager.It still connected and obtained an IP address but when I try to load up a page in firefox it get the failed to connect error. I don't now if it makes a difference but when I do have the static IP details filled in the error I get in firefox is address not found instead.

How can I tell if I have just a wireless access point or a firewall/ router too? I'm afraid it came straight from the braodband provider pretty much plug and play so I never needed to know!I do know that it creates a local network aswell as connecting to the internet.

thanks

mello
mellofello
ydl newbie
ydl newbie
 
Posts: 4
Joined: 09 Jun 2009, 15:59

PreviousNext

Return to Playstation 3

Who is online

Users browsing this forum: No registered users and 97 guests

cron