Rpi3 and OSMC dont use a wifi dongle TL-WN821N

Hi, with my Rpi2 I used this dongle in openelec and work well, but in the 3 its imposible, I explain this.

In the wifi setting I can see wlan0 and wlan1, with the command lsusb I can see the dongle is connected, but if I want to connect to the internet with the dongle I can not because in the status appeared internet not connected, anybody know what happend?

You probably should disable the onboard wifi first. A search of this forum will yield instructions on doing so in several threads where it’s been covered before.

Create the file ‘/etc/modprobe.d/raspi3-blacklist.conf’ the file should read as below.

#wifi
blacklist brcmfmac
blacklist brcmutil

This will disable the onboard wifi nic.

I make that and the dongle connect but there are not internet I have a ip but not internet

How have you determined you have “no internet”? If only from the connection screen in MyOSMC this is not reliable.

Please login via SSH and post here the output of the following command:

ping -c5 google.com

I make the ping and work well, but at 20 seconds I lose the connection

Please provide logs.

grab-logs -a

RcBRrsRs : APT term.log
B8sj7DO8 : APT history.log
ZZz2wrJ1 : APT sources.list
fFsk1x85 : APT apt.conf.d
vSKj25Lq : APT preferences.d

====================== APT term.log =================== RcBRrsRs

Log started: 2016-12-07 19:19:40
Selecting previously unselected package fonts-dejavu-core.
Preparing to unpack …/fonts-dejavu-core_2.34-1_all.deb …
Unpacking fonts-dejavu-core (2.34-1) …
Selecting previously unselected package fontconfig-config.
Preparing to unpack …/fontconfig-config_2.11.0-6.3+deb8u1_all.deb …
Unpacking fontconfig-config (2.11.0-6.3+deb8u1) …
Selecting previously unselected package libfontconfig1:armhf.
Preparing to unpack …/libfontconfig1_2.11.0-6.3+deb8u1_armhf.deb …
Unpacking libfontconfig1:armhf (2.11.0-6.3+deb8u1) …
Selecting previously unselected package fontconfig.
Preparing to unpack …/fontconfig_2.11.0-6.3+deb8u1_armhf.deb …
Unpacking fontconfig (2.11.0-6.3+deb8u1) …
Selecting previously unselected package libxau6:armhf.
Preparing to unpack …/libxau6_1%3a1.0.8-1_armhf.deb …
Unpacking libxau6:armhf (1:1.0.8-1) …
Selecting previously unselected package x11-common.
Preparing to unpack …/x11-common_1%3a7.7+7_all.deb …
Unpacking x11-common (1:7.7+7) …
Selecting previously unselected package libice6:armhf.
Preparing to unpack …/libice6_2%3a1.0.9-1+b1_armhf.deb …
Unpacking libice6:armhf (2:1.0.9-1+b1) …
Selecting previously unselected package libsm6:armhf.
Preparing to unpack …/libsm6_2%3a1.2.2-1+b1_armhf.deb …
Unpacking libsm6:armhf (2:1.2.2-1+b1) …
Selecting previously unselected package libxdmcp6:armhf.
Preparing to unpack …/libxdmcp6_1%3a1.1.1-1+b1_armhf.deb …
Unpacking libxdmcp6:armhf (1:1.1.1-1+b1) …
Selecting previously unselected package libxcb1:armhf.
Preparing to unpack …/libxcb1_1.10-3+b1_armhf.deb …
Unpacking libxcb1:armhf (1.10-3+b1) …
Selecting previously unselected package libx11-data.
Preparing to unpack …/libx11-data_2%3a1.6.2-3_all.deb …
Unpacking libx11-data (2:1.6.2-3) …
Selecting previously unselected package libx11-6:armhf.
Preparing to unpack …/libx11-6_2%3a1.6.2-3_armhf.deb …
Unpacking libx11-6:armhf (2:1.6.2-3) …
Selecting previously unselected package libxt6:armhf.
Preparing to unpack …/libxt6_1%3a1.1.4-1+b1_armhf.deb …
Unpacking libxt6:armhf (1:1.1.4-1+b1) …
Selecting previously unselected package libaudio2:armhf.
Preparing to unpack …/libaudio2_1.9.4-3_armhf.deb …
Unpacking libaudio2:armhf (1.9.4-3) …
Selecting previously unselected package libmng1:armhf.
Preparing to unpack …/libmng1_1.0.10+dfsg-3.1+b3_armhf.deb …
Unpacking libmng1:armhf (1.0.10+dfsg-3.1+b3) …
Selecting previously unselected package qtcore4-l10n.
Preparing to unpack …/qtcore4-l10n_4%3a4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1_all.deb …
Unpacking qtcore4-l10n (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Selecting previously unselected package libqtcore4:armhf.
Preparing to unpack …/libqtcore4_4%3a4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1_armhf.deb …
Unpacking libqtcore4:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Selecting previously unselected package libqt4-xml:armhf.
Preparing to unpack …/libqt4-xml_4%3a4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1_armhf.deb …
Unpacking libqt4-xml:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Selecting previously unselected package libqtdbus4:armhf.
Preparing to unpack …/libqtdbus4_4%3a4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1_armhf.deb …
Unpacking libqtdbus4:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Selecting previously unselected package libqt4-network:armhf.
Preparing to unpack …/libqt4-network_4%3a4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1_armhf.deb …
Unpacking libqt4-network:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Selecting previously unselected package libxext6:armhf.
Preparing to unpack …/libxext6_2%3a1.3.3-1_armhf.deb …
Unpacking libxext6:armhf (2:1.3.3-1) …
Selecting previously unselected package libxrender1:armhf.
Preparing to unpack …/libxrender1_1%3a0.9.8-1+b1_armhf.deb …
Unpacking libxrender1:armhf (1:0.9.8-1+b1) …
Selecting previously unselected package libqtgui4:armhf.
Preparing to unpack …/libqtgui4_4%3a4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1_armhf.deb …
Unpacking libqtgui4:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Selecting previously unselected package libusb-1.0-0:armhf.
Preparing to unpack …/libusb-1.0-0_2%3a1.0.19-1_armhf.deb …
Unpacking libusb-1.0-0:armhf (2:1.0.19-1) …
Processing triggers for systemd (215-17+deb8u5) …
Setting up fonts-dejavu-core (2.34-1) …
Setting up fontconfig-config (2.11.0-6.3+deb8u1) …
debconf: unable to initialize frontend: Dialog
debconf: (Dialog frontend will not work on a dumb terminal, an emacs shell buffer, or without a controlling terminal.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can’t locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.20.2 /usr/local/share/perl/5.20.2 /usr/lib/arm-linux-gnueabihf/perl5/5.20 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl/5.20 /usr/share/perl/5.20 /usr/local/lib/site_perl .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
Setting up libfontconfig1:armhf (2.11.0-6.3+deb8u1) …
Setting up fontconfig (2.11.0-6.3+deb8u1) …
Regenerating fonts cache… done.
Setting up libxau6:armhf (1:1.0.8-1) …
Setting up x11-common (1:7.7+7) …
debconf: unable to initialize frontend: Dialog
debconf: (Dialog frontend will not work on a dumb terminal, an emacs shell buffer, or without a controlling terminal.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can’t locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.20.2 /usr/local/share/perl/5.20.2 /usr/lib/arm-linux-gnueabihf/perl5/5.20 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl/5.20 /usr/share/perl/5.20 /usr/local/lib/site_perl .) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
/var/lib/dpkg/info/x11-common.postinst: 697: /var/lib/dpkg/info/x11-common.postinst: update-rc.d: not found
dpkg: error processing package x11-common (–configure):
subprocess installed post-installation script returned error exit status 127
dpkg: dependency problems prevent configuration of libice6:armhf:
libice6:armhf depends on x11-common; however:
Package x11-common is not configured yet.

dpkg: error processing package libice6:armhf (–configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libsm6:armhf:
libsm6:armhf depends on libice6 (>= 1:1.0.0); however:
Package libice6:armhf is not configured yet.

dpkg: error processing package libsm6:armhf (–configure):
dependency problems - leaving unconfigured
Setting up libxdmcp6:armhf (1:1.1.1-1+b1) …
Setting up libxcb1:armhf (1.10-3+b1) …
Setting up libx11-data (2:1.6.2-3) …
Setting up libx11-6:armhf (2:1.6.2-3) …
dpkg: dependency problems prevent configuration of libxt6:armhf:
libxt6:armhf depends on libice6 (>= 1:1.0.0); however:
Package libice6:armhf is not configured yet.
libxt6:armhf depends on libsm6; however:
Package libsm6:armhf is not configured yet.

dpkg: error processing package libxt6:armhf (–configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libaudio2:armhf:
libaudio2:armhf depends on libxt6; however:
Package libxt6:armhf is not configured yet.

dpkg: error processing package libaudio2:armhf (–configure):
dependency problems - leaving unconfigured
Setting up libmng1:armhf (1.0.10+dfsg-3.1+b3) …
Setting up qtcore4-l10n (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Setting up libqtcore4:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Setting up libqt4-xml:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Setting up libqtdbus4:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Setting up libqt4-network:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Setting up libxext6:armhf (2:1.3.3-1) …
Setting up libxrender1:armhf (1:0.9.8-1+b1) …
dpkg: dependency problems prevent configuration of libqtgui4:armhf:
libqtgui4:armhf depends on libaudio2; however:
Package libaudio2:armhf is not configured yet.
libqtgui4:armhf depends on libice6 (>= 1:1.0.0); however:
Package libice6:armhf is not configured yet.
libqtgui4:armhf depends on libsm6; however:
Package libsm6:armhf is not configured yet.

dpkg: error processing package libqtgui4:armhf (–configure):
dependency problems - leaving unconfigured
Setting up libusb-1.0-0:armhf (2:1.0.19-1) …
Processing triggers for libc-bin (2.19-18+deb8u6) …
Processing triggers for systemd (215-17+deb8u5) …
Errors were encountered while processing:
x11-common
libice6:armhf
libsm6:armhf
libxt6:armhf
libaudio2:armhf
libqtgui4:armhf
Log ended: 2016-12-07 19:20:33

Log started: 2016-12-10 18:09:18
Selecting previously unselected package usbutils.
Preparing to unpack …/usbutils_1%3a007-2_armhf.deb …
Unpacking usbutils (1:007-2) …
Setting up x11-common (1:7.7+7) …
update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
Setting up libice6:armhf (2:1.0.9-1+b1) …
Setting up libsm6:armhf (2:1.2.2-1+b1) …
Setting up libxt6:armhf (1:1.1.4-1+b1) …
Setting up libaudio2:armhf (1.9.4-3) …
Setting up libqtgui4:armhf (4:4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1) …
Setting up usbutils (1:007-2) …
Processing triggers for libc-bin (2.19-18+deb8u6) …
Log ended: 2016-12-10 18:09:24

Log started: 2016-12-11 08:09:05
Selecting previously unselected package firmware-realtek.
Preparing to unpack …/firmware-realtek_0.43_all.deb …
Unpacking firmware-realtek (0.43) …
dpkg: error processing archive /var/cache/apt/archives/firmware-realtek_0.43_all.deb (–unpack):
trying to overwrite ‘/lib/firmware/RTL8192SU/rtl8192sfw.bin’, which is also in package wireless-firmware-osmc 1.1.2
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/firmware-realtek_0.43_all.deb
Log ended: 2016-12-11 08:09:06

Log started: 2016-12-11 08:43:52
Selecting previously unselected package dnsutils.
Preparing to unpack …/dnsutils_1%3a9.9.5.dfsg-9+deb8u8_armhf.deb …
Unpacking dnsutils (1:9.9.5.dfsg-9+deb8u8) …
Selecting previously unselected package shishi-common.
Preparing to unpack …/shishi-common_1.0.2-5_all.deb …
Unpacking shishi-common (1.0.2-5) …
Selecting previously unselected package libshishi0.
Preparing to unpack …/libshishi0_1.0.2-5_armhf.deb …
Unpacking libshishi0 (1.0.2-5) …
Selecting previously unselected package inetutils-telnet.
Preparing to unpack …/inetutils-telnet_2%3a1.9.2.39.3a460-3_armhf.deb …
Unpacking inetutils-telnet (2:1.9.2.39.3a460-3) …
Setting up dnsutils (1:9.9.5.dfsg-9+deb8u8) …
Setting up shishi-common (1.0.2-5) …
Setting up libshishi0 (1.0.2-5) …
Setting up inetutils-telnet (2:1.9.2.39.3a460-3) …
update-alternatives: using /usr/bin/inetutils-telnet to provide /usr/bin/telnet (telnet) in auto mode
Processing triggers for libc-bin (2.19-18+deb8u6) …
Log ended: 2016-12-11 08:43:59

Log started: 2016-12-11 08:47:04
Preparing to unpack …/tar_1.27.1-2+deb8u1_armhf.deb …
Unpacking tar (1.27.1-2+deb8u1) over (1.27.1-2+b1) …
Processing triggers for mime-support (3.58) …
Setting up tar (1.27.1-2+deb8u1) …
update-alternatives: warning: forcing reinstallation of alternative /usr/sbin/rmt-tar because link group rmt is broken
Preparing to unpack …/tzdata_2016j-0+deb8u1_all.deb …
Unpacking tzdata (2016j-0+deb8u1) over (2016f-0+deb8u1) …
Setting up tzdata (2016j-0+deb8u1) …

Current default time zone: ‘Europe/Madrid’
Local time is now: Sun Dec 11 08:47:19 CET 2016.
Universal Time is now: Sun Dec 11 07:47:19 UTC 2016.
Run ‘dpkg-reconfigure tzdata’ if you wish to change it.

Log ended: 2016-12-11 08:47:20

---------------------- APT term.log END --------------- RcBRrsRs

====================== APT history.log =================== B8sj7DO8

Start-Date: 2016-12-07 19:19:40
Commandline: /usr/bin/apt-get-real -qq --yes install libqtcore4 libqtgui4 libqt4-network libusb-1.0-0 ca-certificates
Install: libfontconfig1:armhf (2.11.0-6.3+deb8u1, automatic), libqtcore4:armhf (4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1), libsm6:armhf (1.2.2-1+b1, automatic), qtcore4-l10n:armhf (4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1, automatic), libmng1:armhf (1.0.10+dfsg-3.1+b3, automatic), libxrender1:armhf (0.9.8-1+b1, automatic), libx11-data:armhf (1.6.2-3, automatic), libxt6:armhf (1.1.4-1+b1, automatic), fontconfig:armhf (2.11.0-6.3+deb8u1, automatic), libxdmcp6:armhf (1.1.1-1+b1, automatic), libqtdbus4:armhf (4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1, automatic), libx11-6:armhf (1.6.2-3, automatic), x11-common:armhf (7.7+7, automatic), fontconfig-config:armhf (2.11.0-6.3+deb8u1, automatic), libqt4-network:armhf (4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1), libxext6:armhf (1.3.3-1, automatic), libxau6:armhf (1.0.8-1, automatic), libusb-1.0-0:armhf (1.0.19-1), libice6:armhf (1.0.9-1+b1, automatic), libqtgui4:armhf (4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1), libaudio2:armhf (1.9.4-3, automatic), libqt4-xml:armhf (4.8.6+git64-g5dc8b2b+dfsg-3+deb8u1, automatic), libxcb1:armhf (1.10-3+b1, automatic), fonts-dejavu-core:armhf (2.34-1, automatic)
Error: Sub-process /usr/bin/dpkg returned an error code (1)
End-Date: 2016-12-07 19:20:33

Start-Date: 2016-12-10 18:09:18
Commandline: /usr/bin/apt-get-real install usbutils
Install: usbutils:armhf (007-2)
End-Date: 2016-12-10 18:09:24

Start-Date: 2016-12-11 08:09:05
Commandline: /usr/bin/apt-get-real install firmware-realtek
Install: firmware-realtek:armhf (0.43)
Error: Sub-process /usr/bin/dpkg returned an error code (1)
End-Date: 2016-12-11 08:09:06

Start-Date: 2016-12-11 08:43:52
Commandline: /usr/bin/apt-get-real install bind9-host dnsutils inetutils-telnet
Install: shishi-common:armhf (1.0.2-5, automatic), inetutils-telnet:armhf (1.9.2.39.3a460-3), dnsutils:armhf (9.9.5.dfsg-9+deb8u8), libshishi0:armhf (1.0.2-5, automatic)
End-Date: 2016-12-11 08:43:59

Start-Date: 2016-12-11 08:47:04
Commandline: /usr/bin/apt-get-real dist-upgrade
Upgrade: tzdata:armhf (2016f-0+deb8u1, 2016j-0+deb8u1), tar:armhf (1.27.1-2+b1, 1.27.1-2+deb8u1)
End-Date: 2016-12-11 08:47:20

---------------------- APT history.log END --------------- B8sj7DO8

====================== APT sources.list =================== ZZz2wrJ1
deb Index of /debian jessie main contrib non-free

deb Index of /debian jessie-updates main contrib non-free

deb http://security.debian.org/ jessie/updates main contrib non-free

deb http://apt.osmc.tv jessie main

---------------------- APT sources.list END --------------- ZZz2wrJ1

====================== APT apt.conf.d =================== fFsk1x85
total 36
drwxr-xr-x 2 root root 4096 Jan 1 1970 .
drwxr-xr-x 6 root root 4096 Jan 1 1970 …
-rw-r–r-- 1 root root 26 Nov 22 01:10 00-osmc-fancy-progressbar
-rw-r–r-- 1 root root 62 Nov 22 01:10 00-osmc-no-prompt-conffiles
-rw-r–r-- 1 root root 56 Nov 22 01:10 00-osmc-no-recommends-or-suggests
-rw-r–r-- 1 root root 38 Nov 22 01:10 00-osmc-user-agent
-rw-r–r-- 1 root root 643 Mar 13 2016 01autoremove
-rw-r–r-- 1 root root 981 Nov 28 01:38 01autoremove-kernels
-rw-r–r-- 1 root root 182 Mar 19 2015 70debconf

---------------------- APT apt.conf.d END --------------- fFsk1x85

====================== APT preferences.d =================== vSKj25Lq
total 12
drwxr-xr-x 2 root root 4096 Jan 1 1970 .
drwxr-xr-x 6 root root 4096 Jan 1 1970 …
-rw-r–r-- 1 root root 56 Nov 22 01:10 kernel-common

---------------------- APT preferences.d END --------------- vSKj25Lq

Please upload your logs to http://paste.osmc.tv/ amd post the link here. That way we can see everything.

@ActionA made a typo command should be grab-logs -A with capital A

1 Like

Yes, my bad on the typo. And yes, simply provide the resulting link. DO NOT paste long runs of code here please.

As you most likely only can produce the log after you loose Internet connectivity just write it to a file with grab-logs -C -A and then after reboot you can upload with paste-log <filename> hopefully the time you have network is long enough

http://paste.osmc.io/yefoqavahi

Sorry for the reply but I have been busy

Your logs show a lot of failed or partially failed package installations and that you have installed X11 and an X11 network manager, this will only complicate matters. They also show a lot of “Operation not permitted” errors relating to your wifi.

  1. Have you tried this dongle on any other machine? Does it work?

  2. Does any other dongle work on your RPi?

If you have a spare sd card I would suggest doing a clean install of OSMC and trying the dongle with no modifications as if it is a Realtek 8192 chip as the system detects it should work out of the box.

I have used other dongle and work well, with slow speed but well, and I have used this dongle in a raspberry pi 2 with openelec and work but very very slow

Can you recomend me a cheap 5GHz dongle for BDRemux? thanks very much

https://osmc.tv/store/product/802-11ac-wifi-dongle/