Hello Tomasz & Patrik,
Thanks for your reply.
Here is my configuration of connman:
/etc/connman/main.conf
DefaultAutoConnectTechnologies = ethernet,wifi
PreferredTechnologies = wifi,ethernet,Bluetooth
1) Test 1:
Assumption:
Considering my Preferred Technologies (wifi > ethernet), WiFi discovered first
and preferred over Ethernet, the Ethernet service will never be considered as
default gateway till WiFi disconnected.
Basic steps:
Step 1) First connect target device with WiFi mobile phone (portable host spot
enabled in Access point mode: data usage off)
# connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
Step 2) Connect Ethernet device/phone (data usage on) with target
Actual Service ordering:
#connmanctl services
List of all services:
*AO Wired { ethernet_22d3f9d281a8_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
Expected Service ordering:
#connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
*AR Wired { ethernet_22d3f9d281a8_cable }
2) Test 2:
Assumption:
Considering my Preferred Technologies (wifi > ethernet), WiFi discovered second
but preferred over Ethernet. But ethernet can still have default route if it
goes to state 'online' while the WiFi one stays in 'ready'.
Basic steps:
Step 1) Connect Ethernet device/phone (data usage on) with target
~# connmanctl services
List of all services:
*AO Wired { ethernet_4afaf413be54_cable }
Step 2) First connect target device with WiFi mobile phone (portable host spot
enabled in Access point mode: data usage off)
Actual Service ordering:
~# connmanctl services
List of all services:
*AR Wired { ethernet_4afaf413be54_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
Expected Service ordering:
~# connmanctl services
List of all services:
*AO Wired { ethernet_4afaf413be54_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
There is a statement given in the documentation:
"After that the autoconnected service is continuously used and ConnMan won't
select a new one until the network goes out of range.
When the service goes out of range or gets disconnected from the network
infrastructure side, autoconnect is re-run and another favorite and
autoconnectable service is selected.
The order in which services are considered can be modified by the
PreferredTechnologies configuration in main.conf. "
As we have specified PreferredTechnologies, hence ordering should be modified.
2) Test 3:
Assumption:
Considering my Preferred Technologies (wifi > ethernet), WiFi discovered first
and preferred over Ethernet
Basic steps:
Step 1) First connect target device with WiFi mobile phone (portable host spot
enabled in Access point mode: data usage off)
# connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
Step 2) Connect Ethernet device/phone (data usage off) with target
Actual Service ordering:
# connmanctl services
List of all services:
*AR Wired { ethernet_d2a3d4d7d613_cable }
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
Expected Service ordering:
#connmanctl services
List of all services:
*AR uttejSir { wifi_001cc1a25dff_757474656a536972_managed_none }
*AR Wired { ethernet_22d3f9d281a8_cable }
Note: Service ordering is as expected (WiFi default & top: *AO uttejSir
followed by ethernet) when
WiFi mobile phone (portable host spot enabled in Access point mode: data usage
on)
Ethernet device/phone (data usage on)
Yes, we will have to use Service.MoveAfter() or Service.MoveBefore() to make
ordering user defined. But are these use cases a candidate for explicit service
ordering?
Please correct my understanding if my assumptions are wrong.
Best Regards,
PriyarannjanS
-----Original Message-----
From: connman [mailto:[email protected]] On Behalf Of Tomasz Bursztyka
Sent: Thursday, January 29, 2015 6:45 PM
To: [email protected]
Subject: Re: Issue found in service connman ordering
Hi,
You are assuming the ordering based on the online state taking over the ready
state.
However that's flawed, because there is no way you can guaranty for a service
to get such online state all the time. There is quite a lot of logic behind the
internet connectivity check, and it's not 100% bullet proof. (if you dns
servers fails, if the distant connectivity check website is down, etc etc...)
After all, being ready does not mean you cannot access the internet.
If you want to order service, you will have to order them by yourself through
Service.MoveAfetr() or Service.MoveBefore() methods.
And, anyway, as pointed previously, switching to the latest and greatest
version of ConnMan (1.27 now) is always a good idea!
Tomasz
_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman
This message contains information that may be privileged or confidential and is
the property of the KPIT Technologies Ltd. It is intended only for the person
to whom it is addressed. If you are not the intended recipient, you are not
authorized to read, print, retain copy, disseminate, distribute, or use this
message or any part thereof. If you receive this message in error, please
notify the sender immediately and delete all copies of this message. KPIT
Technologies Ltd. does not accept any liability for virus infected mails.
_______________________________________________
connman mailing list
[email protected]
https://lists.connman.net/mailman/listinfo/connman