Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wifi Services & SSID don't appear #46

Closed
ghost opened this issue Nov 8, 2014 · 42 comments
Closed

Wifi Services & SSID don't appear #46

ghost opened this issue Nov 8, 2014 · 42 comments

Comments

@ghost
Copy link

ghost commented Nov 8, 2014

Hi Andrew,

So I'm not sure if this is a connman issue or cmst, but when I click the Wifi on, nothing appears for the Services under the Status tab, and nothing appears as well under the Wireless tab.

I've been turning the Wifi on while the Wired is on, I'm assuming Wifi services should show up if the Wired is on?

I have to turn the wifi on and off several times and then sometimes it appears, or I restart cmst with the Wired off, then I turn Wifi on and it works, there's no rhyme or reason, I just play with it as many was as I can think of to make the Wifi services and ssid appear, but I have to play with it a lot to get it to work... hmm

@andrew-bibb
Copy link
Owner

Next time it happens that no wifi services appear can you open a terminal and enter the following:

connmanct technologies

That should list all technologies that connman can find. The output should agree with what you see in the technologies box in the Status tab. Assuming Wifi is listed next type:

connmanctl scan wifi

It should return shortly, then type:

connmanctl services

You should then get a list of services that connman can find. Like technologies this should agree with what appears in the services box in the Status tab.

Let me know what you find. If connmanctl is listing something and I'm not then I've got a problem.

@ghost
Copy link
Author

ghost commented Nov 9, 2014

I clicked Wifi on and this is what I get below...

connmanctl technologies

/net/connman/technology/ethernet
  Name = Wired
  Type = ethernet
  Powered = True
  Connected = True
  Tethering = False
/net/connman/technology/wifi
  Name = WiFi
  Type = wifi
  Powered = True
  Connected = False
  Tethering = False

connmanctl scan wifi

Error /net/connman/technology/wifi: No carrier

connmanctl services

*AO Wired                ethernet_10bf482ff3d3_cable

@andrew-bibb
Copy link
Owner

For whatever reason Connman is not getting a carrier on your wifi. Wonder why, but this is a Connman thing, not CMST.

One thing that might be mine however is handling the "No carrier" error message. I'll look through the API documents again. I might have missed handling an return error from the scan wifi method. If connmanctl is handling the error I should be as well.

@andrew-bibb
Copy link
Owner

I checked the API documents and there is no specific error return for scan wifi, so at least I didn't miss that.

I just implemeted a new popup message box to handle the case where you trigger a manual scan and the DBus return is anything other than a routine QBus reply message.

@ghost
Copy link
Author

ghost commented Nov 9, 2014

When would I see this popup, I was assuming when I clicked Wifi on?

By the way, when I click the rescan button I'm getitng this popup;

http://i.imgur.com/4VJCFGB.png

By the way I reported this bug to connman if you want to follow it or give input.

https://01.org/jira/browse/CM-670

@andrew-bibb
Copy link
Owner

No, the new popup is what you are getting when you hit rescan. I did some looking online and I think this is either a connman issue, or a wpa-supplicant issue. The no carrier mesasge is returned with wpa-supplicant in a fair number of search results.

Speaking of bug reports, I will file the one about counters flooding the logs this week.

@ghost
Copy link
Author

ghost commented Nov 9, 2014

Oh so the dbus popup error is the what we want to see if something goes wrong?

connman issue, or a wpa-supplicant issue, what with me not getting any wifi?

flooding report ok...

@andrew-bibb
Copy link
Owner

Not so much a dbus error as a connection error reported via dbus. Ideally one should never see it.

I have no clue why your wifi has blipped out. Thought maybe rfkill, but the output from connmanctl technologies is not consistent with that (I just rfkilled mine to check). To me no carrier means a problem with the radio, but I'm hardly an expert on wifi. I only put a card in my desktop so I could play with it working on this program.

@ghost
Copy link
Author

ghost commented Nov 9, 2014

Well all I can say is the wifi has always worked without a hiccup in wicd, I'm grabbing at straws here, but maybe just a lack of hardware support for my device... Hmm

@andrew-bibb
Copy link
Owner

This looks like it has run it's course so I'm going to close it. If I'm wrong and there is something I need to do let me know.

@ghost
Copy link
Author

ghost commented Dec 4, 2014

Funny, I just clicked the WiFi on and they all appeared instantly, so I don't get this.

Might be nice to keep this in the cabinet file so you can make sure this not something to do with cmst, rather then connman?

thanks

@andrew-bibb
Copy link
Owner

I just uploaded (2014.12.07-1) a major rework of some of the internals. Basically I took out our own periodic wifi scans in favor of the built in Connman wifi scans. Part of this was also fixing the "Rescan" button below the technology table so that it works every time, plus a few other issues with dbus signals connected to our slots. Think I've stomped this to death, but I'm reopening in case there is something I still need to do. I'm hopeful that this rework will have solved some of intermittent problems that have come up, such at this one.

If it stays here for a week or so with no discussion I'll assume all is good and close again.

@andrew-bibb andrew-bibb reopened this Dec 6, 2014
@ghost
Copy link
Author

ghost commented Dec 7, 2014

Ok let me grab and play and let you know how it goes...

@ghost
Copy link
Author

ghost commented Dec 7, 2014

I'm still having problems with it appearing.

The first time I tried it, it all looked good, then I turned it off and when I tried back on for the second time nothing. Then I played with a few times turning on and off and it took like 30 - 40 seconds of trying and waiting and it went back on...

Then I tried this a 3rd time, and then after several tries and several minutes I've not been able to get it to go again...

So sometimes it goes ok and sometimes not... Hmmm

@ghost
Copy link
Author

ghost commented Dec 7, 2014

I submiited a bug report;

https://01.org/jira/browse/CM-670

Last month I get an email and all it says is Need More Info and I repiled asking what info, but still no word back.

If this is a connman issue it would really be great if someone on that bug report would reply.

@andrew-bibb
Copy link
Owner

I've seen the same longer and longer wait periods before wifi services showing when I use the rescan button. My periods are much shorter than you are seeing, first time maybe 3 or 4 seconds, then a bit longer, then dbus times out, then back to 3 or 4 seconds again.

As I understand it Connman does not actually do a scan, rather it sends a request to wpa-supplicant to do the scan. There is a rather long thread running now on the Connman developer mailing list (by the standards of that list) about autoscanning not reconnecting to hidden AP's. If I'm understanding it right, which is debatable, it looks like it is an issue with compile options being set (or not set) by whomever compiled wpa-supplicant for the particular distro. Something like that may explain why I'm seeing a 3 or 4 second lag and you are seeing an order of magnitude larger.

While I was working on another issue I found that Connman handles autoscanning, one of the reasons I took the CMST autoscan out is that I was seeing GUI freezes and I think that was occuring while we had 2 scans running at the same time. Since Connman handles it internally anyway I removed the duplicate feature and reorginized my code to be a whole lot cleaner at a bunch of different levels.

I just did a check (shut down wifi, then powered it up again) with connmanctl running in a parallel window. Connmanctl showed exactly what CMST was indicating, and when the Connman autoscan triggered the wifi services appeared in CMST and connmanctl simultaneously.

Scans do take some time to run. You can see that with the "Rescan" button which will become inactive while a scan is running. One thing I did add for the manual rescan using the button was define a short timeout (I think it was 8, or maybe 10 seconds) before the request aborts. Normal timeout is closer to half a minute which did trigger if you waited long enough.

@ghost
Copy link
Author

ghost commented Dec 8, 2014

If I'm understanding you correctly, I don't see any wpa-supplicant options for compile time;
./configure --help, I had a look through it, nothing.

I sat like 30-40 seconds with the button On and green, and nothing appeared, so I did wait awhile, and didn't think it should take 30 seconds for the Wifi SSID to appear... Hmm

@andrew-bibb
Copy link
Owner

No it should not. What happens if you press the rescan button in CMST?

@ghost
Copy link
Author

ghost commented Dec 8, 2014

So today when I started my box, I clicked On for the first time and it worked, then I clicked off and back On, the second time nothing appeared after 45 seconds, then I clicked 'Rescan' and got a popup saying;

We received a DBus reply message indicating an error while trying to scan technologies.
Error Name:net.connman.Error.NoCarrier
Error Message: NoCarrier

We Recieved LOL, who's the WE in all this? :)

Maybe better to rename all your popups that might start this way as We instead to something like this;

This is a DBus reply message indicating an error while trying to scan technologies.

@andrew-bibb
Copy link
Owner

For the configure options this is an extract from the recent thread:

1 - When compiling wpa_supplicant, in the config file disable the options:
CONFIG_AUTOSCAN_EXPONENTIAL
CONFIG_AUTOSCAN_PERIODIC
CONFIG_BGSCAN_SIMPLE

I'm not suggesting you do any of this, mainly because I haven't a clue what these options do. I'm just pointing out some of the wpa_supplicant compile options (until I read that message I had never once though about a compile option of wpa_supplicant),

For the error message you are receiving, are you using one of the 2014.12.07 releases? That message did come up before then if a rescan was started and there were no wifi services. It was casued because we were trying to do a scan on an ethernet connection. The API docs don't say that you can't, but I found that by accident when I was working on this, and it is one of the things I fixed yesterday. If you are using a more or less current version then the error means Connman, through wpa_supplicant can't find your wifi.

I take it you are not a consulting engineer in private practice? It is beaten into you - never write "I", you get sued (personally) by writing "I", always use "we". Seeing as how my liability policy dosen't cover anything I'm doing here I take your point. We've got some translations now, so string changes will need to be announced, by me, and done at one time. Speaking of day jobs, I've got a 6 hour online course about the most recent building code I need to complete tonight so that I can renew several licenses by the end of the year. Won't be around these parts much longer this evening.

@ghost
Copy link
Author

ghost commented Dec 9, 2014

I'm using your latest release...

Slackware has an official package for wpa_supplicant, so I didn't compile it;

http://mirrors.slackware.com/slackware/slackware64-14.1/source/n/wpa_supplicant/

If interested to see what Slack does, have a look at the; wpa_supplicant.SlackBuild

Ahhh so that's the I & We story, but you or me doesn't have anything to do with the Popup, is the way I look at it, so it should be a Thing that happened, that is why I said you should just make the message like this;

This is a DBus reply message indicating an error while trying to scan technologies

Because; This is a message telling us something, hence the way I worded it... :)

Have fun reading :)

@andrew-bibb
Copy link
Owner

Similar here, I'm using the stock wpa-supplicant as compiled by the Arch Linux maintainers. No idea what compile time options are used, just throwing it out there in case you wanted to look.

@ghost
Copy link
Author

ghost commented Dec 13, 2014

Sorry I'm clueless here... :(

@ghost
Copy link
Author

ghost commented Dec 18, 2014

Hi Andrew,

I just compiled and installed connman 1.27 and still the same issue.

I'm not sure if this will help, but can you please contact the developer, or make a comment also on that bug report.

I'd really like to know since I filed that report if there's been any investigation into this...

thanks

@andrew-bibb
Copy link
Owner

Been thinking about this on and off today. Thinking I'll post a question to the developer mailing list. Don't hold your breath though, I'm basically a gnat to those guys, but I'll give it a shot.

@ghost
Copy link
Author

ghost commented Dec 19, 2014

Gnat, LOL...

I wish the developer(s) would reply to that post and give a heads up to anything going on...

THANKS GnatMan! WoOt

Go get'em Buzz Buzz

@andrew-bibb
Copy link
Owner

I described the problem and asked where do we go from here? Response:

Check that wifi technology is enabled and wpa_supplicant started via
ConnMan or with 'wpa_supplicant -u'

Your wifi technology is enabled, we've seen that with the connmanctl output. In trying to digest the response it occured to me, I don't even know how wpa_supplicant is started on my own system. I've never thought about it, it is just there. Something to ask on the Slackware forums?

As an aside, is that bug tracker even used? I didn't look through any of the other entries to see if they were ever crosssed off. That was the first I'd heard that there was a real bug tracker for Connman which is why I'm asking.

Anyway it has been my experience lurking on the developer mailing list that people with questions get one bite at the apple. That was ours.

@ghost
Copy link
Author

ghost commented Dec 23, 2014

Hi Andrew,

I might be wrong here, but my understanding is wpa_supplicant is used pretty much the same way across distros, so I don't think Slackware does anything different than any other distro using it.

I'm not sure what you mean by my wifi technology enabled? Because when I run connmanctl;

connmanctl scan wifi 
Error /net/connman/technology/wifi: No carrier

connmanctl services
*AO Wired                ethernet_10bf482ff3d3_cable

That's the common output I see when I click the Wifi on, nothing appearing or happening, so this is not much of what I'd call enabled... Hmm

Yep they have a bug tracker, at least it's my understanding...

@andrew-bibb
Copy link
Owner

Enabled would be way up above when you ran "connmanctl technologies" and it returned "wifi powered".

@ghost
Copy link
Author

ghost commented Dec 24, 2014

Yes 'Enabled' this is what I'm saying, it's not showing 'wifi powered'

Again this is random, I can click it one minute and it's working, come back and try it again, and it's not, it's just not consistent for whatever reasons...

With wpa_supplicant I had a look, it's just DBUS servces, being run as...

/usr/share/dbus-1/system-services/fi.epitest.hostap.WPASupplicant.service
/usr/share/dbus-1/system-services/fi.w1.wpa_supplicant1.service

Contents of fi.epitest.hostap.WPASupplicant.service

[D-BUS Service]
Name=fi.epitest.hostap.WPASupplicant
Exec=/usr/sbin/wpa_supplicant -B -u -f /var/log/wpa_supplicant.log -P /var/run/wpa_supplicant.pid
User=root
SystemdService=wpa_supplicant.service

Contents of fi.w1.wpa_supplicant1.service

[D-BUS Service]
Name=fi.w1.wpa_supplicant1
Exec=/usr/sbin/wpa_supplicant -B -u -f /var/log/wpa_supplicant.log -P /var/run/wpa_supplicant.pid
User=root
SystemdService=wpa_supplicant.service

@ghost
Copy link
Author

ghost commented Dec 24, 2014

Forgot to mention in my /etc/wpa_supplicant.conf

ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=root

@andrew-bibb
Copy link
Owner

Up in the third entry in this thread, under wifi, it is showing Powered = true. Has that changed? In connmanspeak an enabled technology = powered. To find the enabled (powered) state you need to run "connmanctl technologies"

@ghost
Copy link
Author

ghost commented Dec 24, 2014

Yes, now I've clicked On after several hours have passed and it's working.

connmanctl technologies

/net/connman/technology/p2p
  Name = P2P
  Type = p2p
  Powered = False
  Connected = False
  Tethering = False
/net/connman/technology/ethernet
  Name = Wired
  Type = ethernet
  Powered = True
  Connected = True
  Tethering = False
/net/connman/technology/wifi
  Name = WiFi
  Type = wifi
  Powered = True
  Connected = False
  Tethering = False

But as I mentioned before it's not consistent, I still have to play with it...

@ghost
Copy link
Author

ghost commented Dec 24, 2014

By the way I shut it off, then waited a couple of seconds and clicked On and nothing again... :(

@ghost
Copy link
Author

ghost commented Jan 7, 2015

I don't know if this happened in older versions, right now I have the latest git...

I just noticed when I turn wifi on and I leave it sit for a few minutes and I haven't connected to any wifi networks, on the Status - Services and under the Wireless tab, they will all disappear...

Hmm odd...

P.S. After posting this I saw after a few mins they returned back, this is odd, they disappear and then reappear after a while too...

@ghost
Copy link
Author

ghost commented Jan 8, 2015

Hi Andrew,

I finally got a hold of the developer and he replied to the report, so I hope you can please jump on that report too and give some input.

https://01.org/jira/browse/CM-670

THANKS

@andrew-bibb
Copy link
Owner

Really don't think there is anything else I can help with so I'm closing this for now.

@andrew-bibb
Copy link
Owner

Abusing my owner privileges here - no update but an observation.

I've got Connman/CMST installed on a system on a bootable USB. Tried it in three different machines and in 2 of them WiFI comes right up immediately after toggling power. On the third the behavior as described above. Takes forever and sometimes you need to toggle several times.

The only variable changed is the actual computer the USB is plugged into so this looks to be a hardware issue. This is going to stay closed here as there is absolutely nothing I can do about it.

@NTohan
Copy link

NTohan commented Jun 5, 2016

Hey Guys,

I'm also facing the same issue! D0 you guys know already any fix or workaround for the same ?

I'm using ubuntu16.04 LTS. I did install last stable connman version (1.21) listed in apt-get. It of course replaced network-manager and after a restart I am trying to connect to wifi but then I am facing the same issue where I am not able to see available networks after

tohan@tohan:$ connmanctl enable wifi
Enabled wifi
tohan@tohan:
$ connmanctl scan wifi
Error /net/connman/technology/wifi: No carrier

Things I have tried so far

  1. restarting connmand.service
  2. Installing latest connman(connman-1.32)
  3. wpa_supplicant -u
  4. Installing connman on an another machine to check if it is a hardware issue

Nothing has worked out so far. It does work with luck sometimes when you keep playing with enable, scan and disable sequence. But I need to develop a software using connman and after trying it for the first time. I am not sure if its a good idea to use connman big_smile

Few people are also facing the same issue but I couldn't find any official bug reported though.

Please let me know if you known how to make it work.

Thanks in advance.

Cheers,
NTohan

@andrew-bibb
Copy link
Owner

I'm afraid not, and to be honest I was really only interested in the CMST end of it all, and this appears to an issue somewhere else.

Between you and me, I'm not sure how often the ConnMan bug tracker is checked or even used. My suggestion would be to post a question on the ConnMan developer mailing list. I'm subscribed to that and the devs seem to answer questions along these lines very promply. The output as you posted above I'm sure they will want to see, and they'll probably ask for some log files. Based on observations of the ML I'm pretty sure the devs only check, or at least respond, Monday through Friday.

@dragon788
Copy link

I believe some of this may be related to dbus/policykit issues. If you would install the gnome desktop environment and use connman from within it I'd imagine it works pretty consistently but if you set up i3/awesome/etc that aren't a standard desktop environment and you don't launch it from gdm or similar then they don't always trigger/open a system-wide dbus session which is how many apps need to communicate. I'm running into the same on 16.04 starting from a server install on my laptop with i3, I'm going to see about adding gdm and registering i3 via a dbus session and will see if that helps.

@andrew-bibb
Copy link
Owner

Thank you for taking an interest in this issue. I would very much appreciate it if you were able to spend some time tracking this down. Want to say though that I run a bare bones i3 setup with no DM and the system bus always starts up. That is on an Arch Linux installation. Also CMST should throw an error and pop up a dialog when it starts if it cannot make a connection to the system bus. I don't want to dissuade you from investigating, but just pointing out what does and should happen.

I'm going to reopen this issue so others can see it on the main page.

Thanks again,
A-

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants
@dragon788 @andrew-bibb @NTohan and others