Bug 1309331
Summary: | Hotspot start fails silently with long hostname | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Vladimir Benes <vbenes> |
Component: | control-center | Assignee: | Bastien Nocera <bnocera> |
Status: | CLOSED ERRATA | QA Contact: | Desktop QE <desktop-qa-list> |
Severity: | low | Docs Contact: | |
Priority: | unspecified | ||
Version: | 7.3 | CC: | bnocera, pgeorgie |
Target Milestone: | rc | Keywords: | Regression |
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2017-08-01 22:38:29 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Attachments: |
Description
Vladimir Benes
2016-02-17 13:38:52 UTC
Fixed upstream for GNOME 3.22. Will need more testing as it requires libnm 1.2. Fixed in control-center-3.22.1-2.el7 Actually fixed in 3.22.2, as the upstream fix was broken/incomplete in 3.22.1 I cannot confirm that function Hotspot is working. I used hostname with length 36 chars. See attached diagnostic files. How can I know if hotspot function is working? What is the command used? Created attachment 1267862 [details]
Extract from journal log
Created attachment 1267863 [details]
Diagnostic info
(In reply to Pavlin Georgiev from comment #5) > I cannot confirm that function Hotspot is working. > > I used hostname with length 36 chars. > See attached diagnostic files. > > How can I know if hotspot function is working? > What is the command used? What about trying on your laptop with phone connecting to it if not with two machines in our lab? Setting hostname (via control-center) to krakonosovo_policko_v_krkonosskem_udoli and enabling Hotspot in control-center leads to krakonosovo_policko_v_krkonosskem_udoli Hotspot that can be connected from a phone (it does use WPA encryption). You can see nmcli con show --active if Hotspot was activated, you can see it in Top Panel in GS and you can obviously see it in control-center with credentials needed to connect to it. Created attachment 1268663 [details]
Diagnostic files and logs
Extract from the journal, kernel's ring, list of network and multimedia controllers, capabilities of the available wireless controller.
The function "Hotspot" cannot be activated on RHEL 7.4 after it's has been installed from distro RHEL-7.4-20170403. Created attachment 1268670 [details]
Activating function "Hotspot" on RHEL 7.3
Activate hotspot on notebook Lenovo W541. It is working and the computer acts like an access point.
Created attachment 1268672 [details]
Failing to activate "Hotspot" under RHEL 7.4
Trying to use function "Hotspot" on notebook Dell Precision M4700.
Created attachment 1268674 [details]
Connecting to a notebook with activated "Hotspot" under RHEL 7.3
I used mobile phone Xiaomi Redme Note with Android 4.4.4
to connect to the access point (notebook).
Created attachment 1268710 [details]
Behaviour of hotspot function under RHEL 7.4
The hotspot function depends on the hostname
which is specified in control-panel, in section "Details".
When the hostname is missing, the command "hostnamectl" return localhost.
Then hotspot cannot be activated.
After a new name is specified in "Detail", let's say "new-hostname" then
the hotspot works properly. In this case "hostnamectl" return "new-hostname"
as static hostname.
Created attachment 1268711 [details]
Log from NetworkManager
Hotspot function worked in RHEL 7.3 but has issues in RHEL 7.4. What's the output of: gnome-control-center -v network and: gdbus introspect --system --dest org.freedesktop.hostname1 --object-path /org/freedesktop/hostname1 when reproducing the failure? Created attachment 1274881 [details]
Logs from reproducing the bug
I ran the commands described before and now I attach the results.
Can you please make sure not to separate the error output from the standard output? Otherwise we don't know when the errors happened, and what for.
> When the hostname is missing, the command "hostnamectl" return localhost.
It returns a lot more than just "localhost", did you mean "hostname"?
I can't reproduce the problem locally, at all. Can you please gather the backtrace from the crash after running:
G_DEBUG=fatal_warnings gnome-control-center -v network
Please make sure to capture both the stdout and stderr at the same time.
Created attachment 1275632 [details]
Logs from reproducing the bug
I ran the new commands without separating standart output from standart error in the log.
What's this? There are no logs related to the hotspot failure: May 02 05:07:55 wlan-r2s18.wlan.rhts.eng.bos.redhat.com abrt-hook-ccpp[26729]: Process 26655 (gnome-control-center) of user 1000 killed by SIGTRAP - dumping core May 02 05:07:56 wlan-r2s18.wlan.rhts.eng.bos.redhat.com abrt-server[26737]: Duplicate: core backtrace May 02 05:07:57 wlan-r2s18.wlan.rhts.eng.bos.redhat.com abrt-applet.desktop[20997]: abrt-applet: repeated problem in control-center-3.22.2-2.el7, not showing the notification The gnome-control-center log is truncated. I think it's pretty easy to reproduce it. 0. delete Device name under Details in Control-center 1. go to Network in c-c and click Use as Hotspot (Click Turn On if needed) 2. nothing happens (as ssid is missing due to empty device name) running: G_DEBUG=fatal_warnings gdb --args gnome-control-center -v network gives: (gdb) bt full #0 0x00007ffff08f4f41 in _g_log_abort (breakpoint=breakpoint@entry=1) at gmessages.c:509 debugger_present = 1 #1 0x00007ffff08f6312 in g_logv (log_domain=0x562019 "network-cc-panel", log_level=G_LOG_LEVEL_WARNING, format=<optimized out>, args=args@entry=0x7fffffffd9e0) at gmessages.c:1318 domain = 0x0 data = 0x0 depth = 1 log_func = 0x7ffff08f5ea0 <g_log_default_handler> domain_fatal_mask = <optimized out> masquerade_fatal = <optimized out> test_level = <optimized out> was_fatal = <optimized out> was_recursion = <optimized out> msg = 0x11591f0 "Failed to save hotspot's settings to disk: 802-11-wireless.ssid: property is missing" msg_alloc = 0x11591f0 "Failed to save hotspot's settings to disk: 802-11-wireless.ssid: property is missing" i = 4 #2 0x00007ffff08f647f in g_log (log_domain=log_domain@entry=0x562019 "network-cc-panel", log_level=log_level@entry=G_LOG_LEVEL_WARNING, format=format@entry=0x564600 "Failed to save hotspot's settings to disk: %s") at gmessages.c:1359 args = {{gp_offset = 32, fp_offset = 48, overflow_arg_area = 0x7fffffffdac0, reg_save_area = 0x7fffffffda00}} #3 0x0000000000520353 in overwrite_ssid_cb (source_object=0x125c630 [NMRemoteConnection], res=0x1509ed0, user_data=0x1310370) at net-device-wifi.c:1060 error = 0x1531760 connection = <optimized out> #4 0x00007ffff1a31727 in g_simple_async_result_complete (simple=0x1509ed0 [GSimpleAsyncResult]) at gsimpleasyncresult.c:801 current_source = 0x7fffb803b390 current_context = <optimized out> __FUNCTION__ = "g_simple_async_result_complete" #5 0x00007ffff3096fb7 in update_cb (proxy=0x12421f0 [NMDBusSettingsConnectionProxy], result=0x12eead0, user_data=0x1509ed0) at libnm/nm-remote-connection.c:126 simple = 0x1509ed0 [GSimpleAsyncResult] finish_func = 0x7ffff30f0990 <nmdbus_settings_connection_call_update_finish> error = 0x1531760 #6 0x00007ffff1a42f64 in g_task_return_now (task=0x12eead0 [GTask]) at gtask.c:1121 #7 0x00007ffff1a4360e in g_task_return (task=0x12eead0 [GTask], type=<optimized out>) at gtask.c:1179 source = 0x7fffb803b390 #8 0x00007ffff1a81eb9 in reply_cb (connection=<optimized out>, res=<optimized out>, user_data=0x12eead0) at gdbusproxy.c:2573 task = 0x12eead0 [GTask] value = 0x7fffb803b390 error = 0x1531760 fd_list = 0x0 #9 0x00007ffff1a42f64 in g_task_return_now (task=0x12eeba0 [GTask]) at gtask.c:1121 #10 0x00007ffff1a4360e in g_task_return (task=0x12eeba0 [GTask], type=<optimized out>) at gtask.c:1179 source = 0x7fffb803b390 #11 0x00007ffff1a769df in g_dbus_connection_call_done (source=<optimized out>, result=0x12eec70, user_data=0x12eeba0) at gdbusconnection.c:5706 connection = <optimized out> task = 0x12eeba0 [GTask] state = 0xbd8600 error = 0x1531760 reply = 0x7fffb80684a0 [GDBusMessage] value = <optimized out> #12 0x00007ffff1a42f64 in g_task_return_now (task=0x12eec70 [GTask]) at gtask.c:1121 #13 0x00007ffff1a42f99 in complete_in_idle_cb (task=task@entry=0x12eec70) at gtask.c:1135 #14 0x00007ffff08ec0d7 in g_idle_dispatch (source=0x7fffb803b390, callback=0x7ffff1a42f90 <complete_in_idle_cb>, user_data=0x12eec70) at gmain.c:5543 again = <optimized out> #15 0x00007ffff08ef4c9 in g_main_context_dispatch (context=0xa01ec0) at gmain.c:3201 dispatch = 0x7ffff08ec0c0 <g_idle_dispatch> ---Type <return> to continue, or q <return> to quit--- prev_source = 0x0 was_in_call = 0 user_data = 0x12eec70 callback = 0x7ffff1a42f90 <complete_in_idle_cb> cb_funcs = 0x7ffff0bb5920 <g_source_callback_funcs> cb_data = 0x7fffb801cdb0 need_destroy = <optimized out> source = 0x7fffb803b390 current = 0xa32f90 i = 0 #16 0x00007ffff08ef4c9 in g_main_context_dispatch (context=context@entry=0xa01ec0) at gmain.c:3854 #17 0x00007ffff08ef818 in g_main_context_iterate (context=context@entry=0xa01ec0, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at gmain.c:3927 max_priority = 2147483647 timeout = 17 some_ready = 1 nfds = <optimized out> allocated_nfds = 3 fds = 0x1155150 #18 0x00007ffff08ef8cc in g_main_context_iteration (context=context@entry=0xa01ec0, may_block=may_block@entry=1) at gmain.c:3988 retval = <optimized out> #19 0x00007ffff1a587c5 in g_application_run (application=0xc0c330 [CcApplication], argc=argc@entry=3, argv=argv@entry=0x7fffffffdf08) at gapplication.c:2381 arguments = 0xf69250 status = 0 context = 0xa01ec0 acquired_context = <optimized out> __FUNCTION__ = "g_application_run" #20 0x000000000044d227 in main (argc=3, argv=0x7fffffffdf08) at main.c:57 application = 0xc0c330 [CcApplication] status = <optimized out> and debug log is here: (gnome-control-center:20088): network-cc-panel-DEBUG: add vpn/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: add vpn/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: add vpn/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: add 802-11-wireless/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/7 (gnome-control-center:20088): network-cc-panel-DEBUG: add 802-3-ethernet/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/4 (gnome-control-center:20088): network-cc-panel-DEBUG: add tun/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/73 (gnome-control-center:20088): network-cc-panel-DEBUG: add vpn/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: add 802-11-wireless/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/36 (gnome-control-center:20088): network-cc-panel-DEBUG: add 802-3-ethernet/NMRemoteConnection remote connection: /org/freedesktop/NetworkManager/Settings/30 (gnome-control-center:20088): network-cc-panel-DEBUG: Calling handle_argv() after cold-plugging connections [New Thread 0x7fffbe6d2700 (LWP 20126)] (gnome-control-center:20088): network-cc-panel-DEBUG: Invoked with operation (null) (gnome-control-center:20088): network-cc-panel-DEBUG: Calling handle_argv() after setting property (gnome-control-center:20088): network-cc-panel-DEBUG: coldplugging devices (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: device /org/bluez/hci0/dev_E0_2C_B2_D1_0C_4D type 5 path /org/freedesktop/NetworkManager/Devices/51 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_E0_2C_B2_D1_0C_4D (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: device /org/bluez/hci0/dev_78_47_1D_26_45_A9 type 5 path /org/freedesktop/NetworkManager/Devices/50 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_E0_2C_B2_D1_0C_4D (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_78_47_1D_26_45_A9 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_E0_2C_B2_D1_0C_4D (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_78_47_1D_26_45_A9 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: device /sys/devices/pci0000:00/0000:00:1c.2/0000:04:00.0/net/wlp4s0 type 2 path /org/freedesktop/NetworkManager/Devices/3 (gnome-control-center:20088): network-cc-panel-DEBUG: adding ICON17 (gnome-control-center:20088): network-cc-panel-DEBUG: adding F53ICON (gnome-control-center:20088): network-cc-panel-DEBUG: got /sys/devices/pci0000:00/0000:00:1c.2/0000:04:00.0/net/wlp4s0 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_E0_2C_B2_D1_0C_4D (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/bluez/hci0/dev_78_47_1D_26_45_A9 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/41 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/42 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/40 (gnome-control-center:20088): network-cc-panel-DEBUG: got /org/freedesktop/NetworkManager/Settings/39 (gnome-control-center:20088): network-cc-panel-DEBUG: got proxy (gnome-control-center:20088): network-cc-panel-DEBUG: device /sys/devices/pci0000:00/0000:00:1f.6/net/enp0s31f6 type 1 path /org/freedesktop/NetworkManager/Devices/2 (gnome-control-center:20088): network-cc-panel-DEBUG: Calling handle_argv() after cold-plugging devices (gnome-control-center:20088): network-cc-panel-DEBUG: overwriting ssid to (gnome-control-center:20088): network-cc-panel-WARNING **: Failed to save hotspot's settings to disk: 802-11-wireless.ssid: property is missing hope this helps :-) control-center-3.22.2-2.el7.x86_64 NetworkManager-1.8.0-0.4.rc3.el7.x86_64 This was fixed quite some time ago, but never got to the stable 3.22 branch, so I spent some time recreating the exact same fixes :/ Anyway, we'll want those 3 fixes in for that particular problem: commit 1f5267050e60f0902596810d97c16a4f5d5304c4 Author: Lubomir Rintel <lkundrak> Date: Wed Nov 2 17:58:15 2016 +0100 hostname-helper: use SSID_MAX_LEN It looks a bit weird to define it and still use the numeric literal. commit a80bb954e0f4809be57c95041051bb359bc98085 Author: Lubomir Rintel <lkundrak> Date: Wed Nov 2 17:15:20 2016 +0100 hostname-helper: fall back to kernel hostname when the pretty one is an empty string The empty string is not too useful as an SSID, an attempt to create a hotspot fails: (gnome-control-center:19371): network-cc-panel-WARNING **: Failed to add new connection: (2) A 'wireless' setting with a valid SSID is required if no AP path was given. commit 96976105f3dc50bdc75cd23b5d163373a6c4d02f Author: Mohammed Sadiq <sadiq> Date: Fri May 5 17:40:33 2017 +0530 hostname-helper: don't read past '\0' g_utf8_find_next_char() doesn't do checks whether the char is '\0' or not. We have to take care of that ourself. This commit fixes heap-buffer-overflow found by test-hostname ERROR: AddressSanitizer: heap-buffer-overflow on address READ of size 1 at 0x60200000cd76 thread T0 #0 0x7f8b26920d08 in g_utf8_find_next_char glib/glib/gutf8.c:179 #1 0x55c2b8eacaee in pretty_hostname_to_ssid gnome-control-center/shell/hostname-helper.c:199 https://bugzilla.gnome.org/show_bug.cgi?id=782216 That code is now in control-center-3.22.2-3.el7, and will be in the updated errata shortly. TEST SETUP on laptop Dell Precision M4700 running under RHEL 7.4 Workstation x86_64 with GNOME 3 desktop environment Component version: control-center-3.22.2-3.el7 TEST PROCEDURE Log in to a GNOME session. 1. Start control center. 2. Open section Details. 3. Set long hostname: krakonosovo_policko_v_krakonosskem_udoli 4. Open section Network. 5. Click on Wi-Fi. 6. Start Hotspot mode. 7. Connect from another notebook (Lenovo W541) to that hotspot. 9. Test ping on the hotspot (10.42.0.1). The connection between the 2 laptops is established via hotspot mode. RESULTS Upgrading the component: control-center from version: 3.14.5-8.el7 to version: 3.22.2-3.el7 has fixed the bug. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2017:2096 |