Driver for tp-link Archer T2U Nano

Borgensgaard2

New Member
Joined
Nov 13, 2020
Messages
14
Reaction score
2
Credits
167
Hi,
I've just bought this amazing new computer and had a wizard put Linux on it, so I can liberate myself from this Windows 10 hell..
I receive internet through a tp-link, have downloaded the driver for windows 10 and It works.. But I am having trouble finding and downloading a driver for Linux..

I found this guide, and wanted to walk through it.. https://suraj.dev/blog/configuring-wireless-usb-adapter-archer-t2u-nano-on-linux

When I go to the link (jeremyb31 on GitHub) for the driver I can´t figure out to locate the driver and download it..

Can somebody point my in the direction of a driver that will work, and give a newbie a few clues on how to activate it, so I can be up an running to discover Linux asap?

Thank you for you time and your help!
Kind regards Jonas
 


KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,729
Reaction score
5,871
Credits
54,190
We need to know what distro you're using, but I'm going to assume it's a Debian derivative.

You don't need to point your browser there to install it. The author tells you how to install it.

It's probably CTRL ALT T, but open your terminal - your command line interface.

Code:
sudo apt install git dkms
git clone https://github.com/jeremyb31/rtl8812au-1.git
cd rtl8812au-1
sudo ./dkms-install.sh

Copy/paste each of those, one line at a time, and press enter between each of them. You will be asked for your password. Type it out. Nothing will appear on the screen as you type it (for many distros). This is perfectly normal. Just type it and press enter.

Repeat that for each line. Each line will not always ask you to type your password.

What does it do?

1. It installs git and dkms. You'll need the first to interact with GitHub and the latter to write kernel changes.
2. This clones the git - moving the data on their site to your computer.
3. That changes directory to the directory you just created in the above step.
4. The 'sudo' elevates your permissions to be able to use the script you downloaded and then it runs the script with those elevated permissions.
 
OP
B

Borgensgaard2

New Member
Joined
Nov 13, 2020
Messages
14
Reaction score
2
Credits
167
Hi, thank you for your response!

My distro is Mint 20 Ulyana..

I copy/pasted all four lines, but on the last one it responded with the following:

Kernel preparation unnecessary for this kernel. Skipping...

Building module:
cleaning build area...
'make' -j6 KVER=5.4.0-53-generic KSRC=/lib/modules/5.4.0-53-generic/build....(bad exit status: 2)
Error! Bad return status for module build on kernel: 5.4.0-53-generic (x86_64)
Consult /var/lib/dkms/rtl8812au/5.3.4/build/make.log for more information.
Finished running dkms install steps.

- What could be my next move?

Again, thank you!
 

f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,900
Reaction score
3,527
Credits
35,667
What does the log say: /var/lib/dkms/rtl8812au/5.3.4/build/make.log? Could be something like the kernel-headers not being installed?
 

f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,900
Reaction score
3,527
Credits
35,667
OP
B

Borgensgaard2

New Member
Joined
Nov 13, 2020
Messages
14
Reaction score
2
Credits
167
Ah, yes of course.. I'm an idiot... ;)
IT brings up a long text!

DKMS make.log for rtl8812au-5.3.4 for kernel 5.4.0-53-generic (x86_64)
lør 14 nov 13:45:38 CET 2020
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/5.4.0-53-generic/build M=/var/lib/dkms/rtl8812au/5.3.4/build O="" modules
make[1]: Entering directory '/usr/src/linux-headers-5.4.0-53-generic'
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_cmd.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_security.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_debug.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_io.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_ioctl_query.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_ioctl_set.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_ieee80211.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_mlme.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_mlme_ext.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_mi.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_wlan_util.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_vht.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_pwrctrl.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_rf.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_recv.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_sta_mgt.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_ap.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/mesh/rtw_mesh.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/mesh/rtw_mesh_pathtbl.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/mesh/rtw_mesh_hwmp.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_xmit.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_p2p.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_rson.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_tdls.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_br_ext.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_iol.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_sreset.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_btcoex_wifionly.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_btcoex.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_beamforming.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_odm.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_rm.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/rtw_rm_fsm.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/core/efuse/rtw_efuse.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/osdep_service.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/os_intfs.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/usb_intf.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/usb_ops_linux.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/ioctl_linux.o
/var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/os_intfs.c:1415:22: error: initialization of ‘u16 (*)(struct net_device *, struct sk_buff *, struct net_device *)’ {aka ‘short unsigned int (*)(struct net_device *, struct sk_buff *, struct net_device *)’} from incompatible pointer type ‘u16 (*)(struct net_device *, struct sk_buff *, struct net_device *, u16 (*)(struct net_device *, struct sk_buff *, struct net_device *))’ {aka ‘short unsigned int (*)(struct net_device *, struct sk_buff *, struct net_device *, short unsigned int (*)(struct net_device *, struct sk_buff *, struct net_device *))’} [-Werror=incompatible-pointer-types]
1415 | .ndo_select_queue = rtw_select_queue,
| ^~~~~~~~~~~~~~~~
/var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/os_intfs.c:1415:22: note: (near initialization for ‘rtw_netdev_ops.ndo_select_queue’)
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/xmit_linux.o
CC [M] /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/mlme_linux.o
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:275: /var/lib/dkms/rtl8812au/5.3.4/build/os_dep/linux/os_intfs.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [Makefile:1757: /var/lib/dkms/rtl8812au/5.3.4/build] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.4.0-53-generic'
make: *** [Makefile:1711: modules] Error 2
 

f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,900
Reaction score
3,527
Credits
35,667
Seems that driver doesn't have support for your kernel or something like that,
Try this rtl8812au driver instead since it's had recent updates:
1. git clone https://github.com/aircrack-ng/rtl8812au
2. cd rtl8812au
3. sudo make dkms_install
4. Then reboot
5. Check if your wifi is working.
 
OP
B

Borgensgaard2

New Member
Joined
Nov 13, 2020
Messages
14
Reaction score
2
Credits
167
YEEEES!!! - Followed your instructions, and sure enough, after my reboot the Archer started blinking and the wireless connection is up and running! Thank you a trillion!

The task of getting to understand and communicate with the terminal and grasping how Linux is woven together honestly feels a bit overwhelming.. But I already feel extremely thankful and energized, learning that people are generous and willing to help - also when it comes to a newbie like me, who is dealing with just understanding the basics of this world....

Thank you for taking time to help me solve my issue, and look forward to my next hurdle! It probably won't be long before I ask a silly question again.. ;)
 

f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,900
Reaction score
3,527
Credits
35,667
Be sure to check out this topic.
 

f33dm3bits

Gold Member
Gold Supporter
Joined
Dec 11, 2019
Messages
4,900
Reaction score
3,527
Credits
35,667
Also most of the wireless drivers are part of the kernel unless you have some card/chip that's not very common. Seems I forgot to check the default repositories, looks like that same driver should be in the Mint/Ubuntu repos since I found the package here. Which would mean all you had to do: sudo apt-get install rtl8812au-dkms. It's actually better to install the driver from the repos if it's available, I should have checked there first.
 
Last edited:

jglen490

Well-Known Member
Joined
Mar 10, 2020
Messages
736
Reaction score
505
Credits
4,106
Yep, sometimes you just need to have a Sherlock Holmes hat nearby and follow the clues. By checking a few other forum links from Google, others find that the chip is an rtl8812au. The dkms tool is also referenced. Sometimes, you can take that info and just look in your distro's repositories, or in the software manager in your distro. So I looked in Synaptic (which is available in the *buntu variants, Mint, and other Debian derived distros) and did a search on "rtl", and a list came back identifying a package named "rtl8812au-dkms. Installing that package should provide the driver, even though TP-Link does not officially support this particular adapter - someone does!
 

jc43

New Member
Joined
Dec 9, 2020
Messages
1
Reaction score
0
Credits
6
Many thanks for your help with building and installing a driver for the above - for an older raspberry pi 2 which did not have wifi on board.
 

Roland Deepson

New Member
Joined
May 10, 2021
Messages
5
Reaction score
0
Credits
59
We need to know what distro you're using, but I'm going to assume it's a Debian derivative.

You don't need to point your browser there to install it. The author tells you how to install it.

It's probably CTRL ALT T, but open your terminal - your command line interface.

Code:
sudo apt install git dkms
git clone https://github.com/jeremyb31/rtl8812au-1.git
cd rtl8812au-1
sudo ./dkms-install.sh

Copy/paste each of those, one line at a time, and press enter between each of them. You will be asked for your password. Type it out. Nothing will appear on the screen as you type it (for many distros). This is perfectly normal. Just type it and press enter.

Repeat that for each line. Each line will not always ask you to type your password.

What does it do?

1. It installs git and dkms. You'll need the first to interact with GitHub and the latter to write kernel changes.
2. This clones the git - moving the data on their site to your computer.
3. That changes directory to the directory you just created in the above step.
4. The 'sudo' elevates your permissions to be able to use the script you downloaded and then it runs the script with those elevated permissions.

Hi there! I've dabbled in Ubuntu a few years ago, and my usage case for that kinda died on the vine so I migrated fully back to Windows 10. Now, I'm attempting to install this same wifi dongle in Kali. (... I'm not entirely sure how to verify my current kernel version...)

Running git clone https://github.com/jeremyb31/rtl8812au-1.git seems to end in some sort of auto-abort scenario. Full disclosure, pending full installation and usage of the wifi adaptor, I'm currently restricted to ~500kpbs in bandwidth via USB-tether to my android smartphone.

The resulting output, after several minutes of ostensibly performing a large majority of the ultimate download:

Code:
Cloning into 'rtl8812au-1'...
remote: Enumerating objects: 7008, done.
error: RPC failed; curl 56 GnuTLS recv error (-9): Error decoding the received TLS packet.
error: 1233 bytes of body are still expected
fetch-pack: unexpected disconnect while reading sideband packet
fatal: early EOF
fatal: index-pack failed

Other googlage such as here suggest the possible variations of:
Code:
┌──(kali㉿kali)-[~]
└─$ git clone -b v5.6.4.2 https://github.com/aircrack-ng/rtl8812au.git
Cloning into 'rtl8812au'...
remote: Enumerating objects: 11062, done.
remote: Counting objects: 100% (100/100), done.
remote: Compressing objects: 100% (68/68), done.
error: RPC failed; curl 56 GnuTLS recv error (-110): The TLS connection was non-properly terminated.
error: 2896 bytes of body are still expected
fetch-pack: unexpected disconnect while reading sideband packet
fatal: early EOF
fatal: index-pack failed

... or ...

Code:
──(kali㉿kali)-[~]
└─$ git clone https://github.com/aircrack-ng/rtl8812au                                                        100 ⨯
Cloning into 'rtl8812au'...
remote: Enumerating objects: 11062, done.
remote: Counting objects: 100% (100/100), done.
remote: Compressing objects: 100% (68/68), done.
error: 2876 bytes of body are still expectedMiB | 67.00 KiB/s
fetch-pack: unexpected disconnect while reading sideband packet
fatal: early EOF
fatal: index-pack failed

... seems to lead to my vague impression that either my throttled connection is structurally insufficient to begin with, or that I'm somehow missing a prerequisite step.

I'll continue fiddling after posting this, but I'd still benefit from any input or other assistance. Is it necessary for me to pin down my exact kernel info before proceeding? Since I can install this adaptor and run it successfully in Windows 10, should I opt toward running Kali in a Windows-side vm?

Full context is that I need to perform some light pen-testing of a handful of wifi SSIDs, including my own hotspot and also my roommate's personal hotspot. For the moment, I'm blind as to whether this wifi adaptor is even sufficient for that task (something about packet injector ability...?)

Also, I am intrigued by this advice:
Yep, sometimes you just need to have a Sherlock Holmes hat nearby and follow the clues. By checking a few other forum links from Google, others find that the chip is an rtl8812au. The dkms tool is also referenced. Sometimes, you can take that info and just look in your distro's repositories, or in the software manager in your distro. So I looked in Synaptic (which is available in the *buntu variants, Mint, and other Debian derived distros) and did a search on "rtl", and a list came back identifying a package named "rtl8812au-dkms. Installing that package should provide the driver, even though TP-Link does not officially support this particular adapter - someone does!

My fiddling will also include trying to find out how to use this suggestion as well.

Thanks in advance!
 

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,729
Reaction score
5,871
Credits
54,190
Now, I'm attempting to install this same wifi dongle in Kali.

I'd ask in the Kali sub-forum AFTER reading the stickied post in that section of the sub-forum. Kali isn't for new Linux users and most of us aren't going to invest much time helping new users try Kali. Learn Linux, then try Kali. Using Kali doesn't turn you into a penetration tester or hacker. Understanding how things work turns you into a pen tester or hacker. Understand Linux, then try Kali.
 

Roland Deepson

New Member
Joined
May 10, 2021
Messages
5
Reaction score
0
Credits
59
So the fact that my particular question happens to be literally and verbatim the same peripheral wifi adaptor, on a distro with the same Debian core, still means that my reply here was inappropriate? I'm asking this as a new user to the forum, more than as a new user to Kali.
 

KGIII

Super Moderator
Staff member
Gold Supporter
Joined
Jul 23, 2020
Messages
6,729
Reaction score
5,871
Credits
54,190
You definitely want to ask in the Kali forum, yes. There are a ton of differences between Debian and Ubuntu, and then a ton more between Ubuntu and Kali. So, yes, that's the most appropriate place to ask.

And, if you're having issues with a wifi adapter, and 'dabbled' in Ubuntu but quit, you're really not ready for Kali.

That's not an insult. It's just reality. We have years of experience with dealing with Kali questions. There's a reason why there's a stickied post in that sub-forum and a reason why we suggest reading it.
 
$100 Digital Ocean Credit
Get a free VM to test out Linux!

Linux.org Hosting Donations
Consider making a donation

Staff online

Members online


Top