LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-21-2019, 05:47 PM   #1
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Rep: Reputation: Disabled
USB Wifi Won't Make on Debian 4.19


Good Evening,

I am still somewhat new to linux, though I have played with Raspberry Pis a bit over the last few years I am now trying to learn Linux better by using it on my travel laptop which is an x230.

I purchased a new USB wifi dongle and it seems I need the 8822bu drivers but I can not get them to make without errors. Here is what I found my device to be:


T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 3 Spd=480 MxCh= 0
D: Ver= 2.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
P: Vendor=0bda ProdID=b812 Rev=02.10
S: Manufacturer=Realtek
S: Product=802.11ac NIC
S: SerialNumber=123456
C: #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=500mA
I: If#=0x0 Alt= 0 #EPs= 5 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)


The output on the first attempt was much longer but here is the second attempt output:

https://pastebin.com/6TGkAG8a


Any help is appreciated. I did not see a log file indicated and am quite inexperienced in knowing what to look for and how to read it.

Thank you
 
Old 11-21-2019, 07:10 PM   #2
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,363
Blog Entries: 28

Rep: Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148Reputation: 6148
A web search for "Realtek 802.11ac NIC" turns up a number of links, including some YouTube videos. This one looks promising.

https://askubuntu.com/questions/1026...wifi-rtl8811au

In my experience at LQ, I have come to the conclusion that manufacturers of USB wireless cards often offer spotty support of Linux.
 
1 members found this post helpful.
Old 11-21-2019, 07:18 PM   #3
flshope
Member
 
Registered: Jul 2009
Location: Tennessee (United States)
Distribution: Debian 11.6, Ubuntu 22.04.2, 18.04.6, Android 11
Posts: 236
Blog Entries: 44

Rep: Reputation: 80
Perhaps you have already tried this, but the Debian 10 repository package 'firmware-realtek' has several firmware files for RTL8822b_'. I didn't see one ending in 'bu'. You can see the contents with

Code:
apt -a show firmware-realtek
I can't say if any of the included firmware files will work with your device, but the package is easy to install, and I think your system will auto-select one that would work (if any) from /lib/firmware.
 
1 members found this post helpful.
Old 11-21-2019, 07:22 PM   #4
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Original Poster
Rep: Reputation: Disabled
Thank you for the response. I've tried a few installations and it seems this one is for a different chipset. Are you saying to just follow the instructions for the correct driver's or that these drivers will work?

The other part of this that confuses me is many of these articles are older and ran I to the following:

While ifconfig worked on my slackeare installation before (it was a bit too much so switched to Debian since I was more familiar with raspbian) it doesn't seem to work on this Debian distro. I saw comments stating it was no longer a relevant command. I will try again to be sure.

The other is that I attempted to install the Linux headers-generic before a d it could not find then to install. I do have headers-common installed by default. Could not having the generic header package cause this issue?

Thank you for responding.
 
Old 11-21-2019, 07:23 PM   #5
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian sid
Posts: 2,683

Rep: Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783
Code:
Downloads/rtl8822bu-master
you downloaded a zip from github

if you want people to debug code it is often helpful to give them code to debug

link the source
 
1 members found this post helpful.
Old 11-21-2019, 07:26 PM   #6
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian sid
Posts: 2,683

Rep: Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783
Quote:
Originally Posted by kn4thx View Post
Thank you for the response. I've tried a few installations and it seems this one is for a different chipset. Are you saying to just follow the instructions for the correct driver's or that these drivers will work?

The other part of this that confuses me is many of these articles are older and ran I to the following:

While ifconfig worked on my slackeare installation before (it was a bit too much so switched to Debian since I was more familiar with raspbian) it doesn't seem to work on this Debian distro. I saw comments stating it was no longer a relevant command. I will try again to be sure.

The other is that I attempted to install the Linux headers-generic before a d it could not find then to install. I do have headers-common installed by default. Could not having the generic header package cause this issue?

Thank you for responding.

ifconfig is depreciated

you are probably looking for

Code:
ip address
it can be shortened to "ip a"

Code:
man ip
 
1 members found this post helpful.
Old 11-21-2019, 07:41 PM   #7
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by flshope View Post
Perhaps you have already tried this, but the Debian 10 repository package 'firmware-realtek' has several firmware files for RTL8822b_'. I didn't see one ending in 'bu'. You can see the contents with

Code:
apt -a show firmware-realtek
I can't say if any of the included firmware files will work with your device, but the package is easy to install, and I think your system will auto-select one that would work (if any) from /lib/firmware.
I am pretty sure I installed that yesterday with no luck but I can definitely try again.
 
Old 11-21-2019, 07:42 PM   #8
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Firerat View Post
Code:
Downloads/rtl8822bu-master
you downloaded a zip from github

if you want people to debug code it is often helpful to give them code to debug

link the source
My apologies while I tried multiple Github versions of 8822bu, this is the latest:

https://github.com/EntropicEffect/rtl8822bu
 
Old 11-21-2019, 08:01 PM   #9
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian sid
Posts: 2,683

Rep: Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783
Quote:
Originally Posted by kn4thx View Post
My apologies while I tried multiple Github versions of 8822bu, this is the latest:

https://github.com/EntropicEffect/rtl8822bu
compiles fine here,
but I'm using a 5.3 kernel


what is the output of this
Code:
apt list --installed linux*
please post the output in between code tags

[code]
like this
[/code]
 
1 members found this post helpful.
Old 11-21-2019, 08:38 PM   #10
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Firerat View Post
compiles fine here,
but I'm using a 5.3 kernel


what is the output of this
Code:
apt list --installed linux*
Code:
kn4thx@debian-l-inux:~/Downloads/rtl8822bu-master$ apt list --installed linux*
Listing... Done
linux-base/stable,stable,now 4.6 all [installed,automatic]
linux-compiler-gcc-8-x86/stable,now 4.19.67-2+deb10u2 amd64 [installed,automatic]
linux-cpupower/stable,now 4.19.67-2+deb10u2 amd64 [installed,automatic]
linux-headers-4.19.0-6-amd64/stable,now 4.19.67-2+deb10u2 amd64 [installed]
linux-headers-4.19.0-6-common/stable,stable,now 4.19.67-2+deb10u2 all [installed,automatic]
linux-headers-amd64/stable,now 4.19+105+deb10u1 amd64 [installed,automatic]
linux-image-4.19.0-5-amd64/now 4.19.37-5+deb10u2 amd64 [installed,local]
linux-image-4.19.0-6-amd64/stable,now 4.19.67-2+deb10u2 amd64 [installed,automatic]
linux-image-amd64/stable,now 4.19+105+deb10u1 amd64 [installed]
linux-kbuild-4.19/stable,now 4.19.67-2+deb10u2 amd64 [installed,automatic]
linux-libc-dev/stable,now 4.19.67-2+deb10u2 amd64 [installed,automatic]
 
Old 11-21-2019, 10:04 PM   #11
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian sid
Posts: 2,683

Rep: Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783
patch attached


in the rtl8822bu-master
Code:
patch -p1 -i /path/to/rtl8822bu-profile-patch.txt
make clean
make

it compiles, but I have no idea if it works


[Edit]
actually, now I look at it again
this is easier than patch


this assumes you did a git clone ( not a zip download )
Code:
make clean
git checkout dea3bb8e631191ded1839c53fb266d80ef7e8ad3
make
it turns out I just "removed" the most recent commit

Edit2

this sed is probably even easier.

Code:
sed -i -E '{ s/(^[[:blank:]]+[.]doit = rtw_cfgvendor_.+),/\1/
              /^[[:blank:]]+[.]policy = VENDOR_CMD_RAW_DATA,/d
}' os_dep/linux/rtw_cfgvendor.c


#
Attached Files
File Type: txt rtl8822bu-profile-patch.txt (1.8 KB, 13 views)

Last edited by Firerat; 11-21-2019 at 10:48 PM.
 
1 members found this post helpful.
Old 11-22-2019, 08:47 AM   #12
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Original Poster
Rep: Reputation: Disabled
Make ran without a hitch, thank you! I do not have the adapter with me at work so I will have to test later.


Quote:

it turns out I just "removed" the most recent commit
May I ask, in newbie terms, what was hanging it up?
 
Old 11-22-2019, 09:34 AM   #13
kn4thx
LQ Newbie
 
Registered: Nov 2019
Distribution: Debian
Posts: 20

Original Poster
Rep: Reputation: Disabled
Update: Snuck by the house and grabbed the USB dongle, rebooted, but it is not working.

All I know to check on reported this:

Code:
kn4thx@debian-l-inux:~$ sudo modinfo 8822
[sudo] password for kn4thx: 
modinfo: ERROR: Module 8822 not found.
It looks like the driver isn't loading.

I double checked the device info here :

Code:
kn4thx@debian-l-inux:~$ lsusb
Bus 004 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 006: ID 5986:02d2 Acer, Inc 
Bus 001 Device 005: ID 0a5c:21e6 Broadcom Corp. BCM20702 Bluetooth 4.0 [ThinkPad]
Bus 001 Device 004: ID 147e:2020 Upek TouchChip Fingerprint Coprocessor (WBF advanced mode)
Bus 001 Device 003: ID 25a7:fa23  
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 002 Device 002: ID 0bda:b812 Realtek Semiconductor Corp. 
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
It shows
Code:
b812
which by all research says it should be an 8822bu driver.

I did find a newer dated post here:

https://askubuntu.com/questions/1049...g-wifi-adapter

I uninstalled the driver i originally posted here, and attempted to use
Code:
 https://github.com/jeremyb31/rtl8822bu.git
as listed in the other post, it makes, and it doesn't fail, but it does show warnings before seeming to complete successfully. Modinfo does not find that driver loaded either.




Is

Last edited by kn4thx; 11-22-2019 at 09:35 AM.
 
Old 11-22-2019, 09:36 AM   #14
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian sid
Posts: 2,683

Rep: Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783
This commit
https://github.com/EntropicEffect/rt...ae7e17df204263

added feature not supported the the 4.19 kernels
I just removed that new bit


This one appears to be a proper fix
https://github.com/EntropicEffect/rtl8822bu/pull/9

it adds conditional like this
Code:
#define KERNEL_HAS_CFG80211_WIPHY_VENDOR_COMMAND_POLICY \
    (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 3, 0))
...
...
#if KERNEL_HAS_CFG80211_WIPHY_VENDOR_COMMAND_POLICY
		.policy = VENDOR_CMD_RAW_DATA,
#endif /* KERNEL_HAS_CFG80211_WIPHY_VENDOR_COMMAND_POLICY */
...
...

//

Note, they "look" like comments
but # is not a comment in c
 
1 members found this post helpful.
Old 11-22-2019, 09:44 AM   #15
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian sid
Posts: 2,683

Rep: Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783Reputation: 783
the kernel module is

88x2bu.ko



Code:
make && sudo make install
sudo modprobe 88x2bu


#
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Wifi option is there but no wifi scanning or wifi not working Aakash447 Linux - Newbie 3 06-28-2018 11:48 PM
[SOLVED] Problem connecting to WIFI with usb WIFI adapter on debian stretch beric Linux - Hardware 0 09-19-2017 07:44 AM
Want to share my wifi by creating a wifi hotspot ( While staying connected to wifi)? shadyXV Linux - Desktop 4 07-20-2015 05:37 PM
How to make my linux laptop a deticated wifi "adapter" (send all lan to wifi) Master_CAPS Linux - Laptop and Netbook 4 03-19-2012 04:17 PM
dual wifi and wired connection: how to make a specific website use only wifi? shinji2001xyz Linux - Networking 2 04-08-2010 10:13 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:42 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration