After installing Ubuntu 20.04.1 for some reason, the Ralink RT3290 driver of WiFi adapter was not installed.
On the web, I found three methods to solve this problem, but none of them worked for me
Here you can see the configuration of my hardware and operating system
==========================================
-=First method=- I tried to compile and install the driver from sourse code but after downloading and unpacking the archive into the /usr/src folder, I tried to start compiling using the "make" command and got an error.
make -C /lib/modules/5.4.0-51-generic/build SUBDIRS = /home/hp/Downloads/rt3290sta/os/linux modules
make [1]: Entering directory '/usr/src/linux-headers-5.4.0-51-generic'
mkdir: cannot create directory ‘.tmp_3584’: Permission denied
mkdir: cannot create directory ‘.tmp_3586’: Permission denied
mkdir: cannot create directory '.tmp_3588 ’: Permission denied
.......
.......
.......
.......
.......
.......
Then I tried to do sudo make and got the following error
make [1]: Entering directory '/usr/src/linux-headers-5.4.0-51-generic'
LEX scripts/kconfig/lexer.lex.c
/bin/ sh: 1: flex: not found
================================================
<=<=<=
PLease Download the Updated Driver (Big Thanks to Jim Colaco) From Here or Here. This was tested on Ubuntu 16.04 and 16.10.
sudo tar -xvf rt3290sta-2.6.0.0.dkms.tar -C /usr/src sudo dkms install -m rt3290sta -v 2.6.0.0 --force sudo reboot
=>=>=>=>
But after running this command sudo dkms install -m rt3290sta -v 2.6.0.0 --force I get an error which says to look at the log. In the log it says
DKMS make.log for rt3290sta-2.6.0.0 for kernel 5.4.0-51-generic (x86_64)
Mon 19 Oct 2020 05:00:34 PM CEST
make: Entering directory '/var/lib/dkms/rt3290sta/2.6.0.0/build/src'
make -C tools
cp -f os/linux/Makefile.6 /var/lib/dkms/rt3290sta/2.6.0.0/build/src/os/linux/Makefile
make[1]: Entering directory '/var/lib/dkms/rt3290sta/2.6.0.0/build/src/tools'
gcc -g bin2h.c -o bin2h
make -C /lib/modules/5.4.0-51-generic/build SUBDIRS=/var/lib/dkms/rt3290sta/2.6.0.0/build/src/os/linux modules
make[1]: Entering directory '/usr/src/linux-headers-5.4.0-51-generic'
chmod +x bin2h
make[1]: Leaving directory '/var/lib/dkms/rt3290sta/2.6.0.0/build/src/tools'
/var/lib/dkms/rt3290sta/2.6.0.0/build/src/tools/bin2h
LEX scripts/kconfig/lexer.lex.c
/bin/sh: 1: flex: not found
YACC scripts/kconfig/parser.tab.[ch]
/bin/sh: 1: bison: not found
make[3]: *** [scripts/Makefile.host:9: scripts/kconfig/lexer.lex.c] Error 127
make[3]: *** Waiting for unfinished jobs....
make[3]: *** [scripts/Makefile.host:17: scripts/kconfig/parser.tab.h] Error 127
make[2]: *** [Makefile:617: syncconfig] Error 2
make[1]: *** [Makefile:723: include/config/auto.conf.cmd] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-5.4.0-51-generic'
make: *** [Makefile:381: LINUX] Error 2
make: Leaving directory '/var/lib/dkms/rt3290sta/2.6.0.0/build/src'
=====================================================
and it says that you need to download and install the kernel version 3.19 of Ubuntu but and gives a link https://kernel.ubuntu.com/~kernel-ppa/mainline/v3.19-vivid/ to the official Ubuntu website where all versions of the Ubuntu kernel are located, but there is not exactly the version that is proposed to install.
==================================================
So I tried three options for installing the required driver and each of these options turned out to be ineffective for me. I will be glad for any of your help or correction of my mistake
sudo apt install flex
– laugeo Oct 19 '20 at 11:54sudo apt install flex bison
and try again. – Akib Azmain Turja Jan 09 '21 at 13:23