7

I know this question has been asked here before, but the answers haven't helped me. I have a Lenovo Ideapad on which I've installed via UNetbootin 18.04. Everything else with the install went smoothly, but like others my wifi is not working. In particular, I've gotten the no wi-fi adapter found message.

Many of the fixes relied on gaining access to the internet via an ethernet connection, but my machine doesn't have a connection for that.

I haven't used Ubuntu in several years so my Linux foo is very rusty. I'm essentially a newbie.

03:00.0 Network controller [0280]:  Realtek Semiconductor Co., Ltd. RTL8821CE 802.11ac PCIe Wireless Network Adapter [10ec:c821]
          Subsystem: Lenovo RTL8821CE 802.11ac PCIe Wireless Network Adapter [17aa:co24]

Let me emphasize newbie again. I don't know how else to post this. Here's the feedback now that I attempt to run make after updating and upgrading again:

/bin/sh: 1: cc: not found
(standard_in) 1: syntax error
make ARCH=x86_64 CROSS_COMPILE= -C /lib/modules/4.18.0-15-generic/build M=/home/john/Downloads/rtl8821ce  modules
make[1]: Entering directory '/usr/src/linux-headers-4.18.0-15-generic'
arch/x86/Makefile:155: CONFIG_X86_X32 enabled but no binutils support
./scripts/gcc-version.sh: line 26: gcc: command not found
./scripts/gcc-version.sh: line 27: gcc: command not found
Makefile:970: "Cannot use CONFIG_STACK_VALIDATION=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel"
make[1]: gcc: Command not found
make[1]: gcc: Command not found
make[1]: gcc: Command not found
make[1]: gcc: Command not found
/bin/sh: 1: gcc: not found
(standard_in) 1: syntax error
/home/john/Downloads/rtl8821ce/Makefile:2157: home/john/Downloads/rtl8821ce/hal/phydm/phydm.mk: No such file or directory
/home/john/Downloads/rtl8821ce/Makefile:2166: home/john/Downloads/rtl8821ce/rtl8821c.mk: No such file or directory
make[2]: *** No rule to make target 'home/john/Downloads/rtl8821ce/rtl8821c.mk'.  Stop.
Makefile:1534: recipe for target '_module_/home/john/Downloads/rtl8821ce' failed
make[1]: *** [_module_/home/john/Downloads/rtl8821ce] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.18.0-15-generic'
Makefile:2237: recipe for target 'modules' failed
make: *** [modules] Error 2
john@john-Lenovo-ideapad-130S-11IGM:~/Downloads/rtl8821ce$ sudo make install
/bin/sh: 1: cc: not found
(standard_in) 1: syntax error
install -p -m 644 8821ce.ko  /lib/modules/4.18.0-15-generic/kernel/drivers/net/wireless/
install: cannot stat '8821ce.ko': No such file or directory
Makefile:2243: recipe for target 'install' failed
make: *** [install] Error 1

Ran the commands and got these errors:

E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?
john@john-Lenovo-ideapad-130S-11IGM:~$ sudo apt-get install libelf-dev
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?
karel
  • 114,770
user81112
  • 173
  • 1
    Let's start by identifying your exact wireless device. Please open a terminal Ctrl+Alt+t and run the command: lspci -nnk | grep 0280 -A3 Next, edit your question to show the result. Welcome to Ask Ubuntu. – chili555 Jul 30 '19 at 21:23
  • Thank you. See above. Also, since I posted this, I re-installed 18.04 this time I ticked the box choosing 3rd party and propietary software, which didn't fix the problem. Thank you! – user81112 Jul 30 '19 at 22:48
  • Here is the method to install the driver with a temporary internet connection by, for instance, tethering from your phone. https://askubuntu.com/questions/990378/wi-fi-not-working-on-lenovo-thinkpad-e570-realtek-rtl8821ce If this is an impossibility, I will write a lengthy answer as to the procedure without an internet connection. Do you still have the USB or DVD from which you installed Ubuntu? Many of the prerequisites are on it. – chili555 Jul 30 '19 at 23:24
  • I do still have the usb drive I used. I'll try to tether to my phone first – user81112 Jul 30 '19 at 23:27
  • Rats. Tethering is not working. I'm still not connected. – user81112 Jul 30 '19 at 23:35
  • It will take me some minutes to write the answer. I will post the first part so you can get started then I will edit to add more. – chili555 Jul 30 '19 at 23:37
  • Oh! I got it to connect via bluetooth somehow. Sorry for the premature post – user81112 Jul 30 '19 at 23:41
  • If you are connected, then I will have to edit my answer severely. Please stand by... – chili555 Jul 30 '19 at 23:48
  • OK. I was following directions you gave in the above linked answer. It's still downloading, though. So, I'll wait – user81112 Jul 30 '19 at 23:49
  • I think I'm done! Please double-check that you've taken the most recent steps in my answer below. Post any errors. – chili555 Jul 30 '19 at 23:56
  • Will do. My little computer is working – user81112 Jul 31 '19 at 00:13

2 Answers2

14

Please open a terminal and do:

sudo apt-get update && sudo apt-get install build-essential git dkms
git clone https://github.com/tomaspinho/rtl8821ce
cd rtl8821ce
chmod +x dkms-install.sh
chmod +x dkms-remove.sh
sudo ./dkms-install.sh   
sudo modprobe 8821ce

Your wireless should now be working.

Revision 31 July, 2019 9:40 am EDT

chili555
  • 60,188
  • Working through it. Thank you! – user81112 Jul 31 '19 at 00:11
  • Everything went great until I typed 'make' after editing the file. I got the message

    Command 'make' not found, but can be installed with:

    sudo apt install make sudo apt install make-guile

    I tried each of those commands and was told that those could not be located.

    – user81112 Jul 31 '19 at 01:11
  • Just realized I'm no longer tethered. – user81112 Jul 31 '19 at 01:13
  • connected again, but same problem. – user81112 Jul 31 '19 at 01:16
  • Re-tethered. Did another apt-get update and upgrade. Now getting this: – user81112 Jul 31 '19 at 01:37
  • See above in my original post. I can't get make to work stil – user81112 Jul 31 '19 at 01:57
  • You must install make, gcc, etc. using: sudo apt-get update && sudo apt-get install build-essential Please do so and try again. You will also need: sudo apt-get install libelf-dev – chili555 Jul 31 '19 at 12:35
  • OK. Did the first two, but not the third. Will do all 3. Thank you! – user81112 Jul 31 '19 at 12:47
  • Errors are copied above in my original post. Thank you for sticking with me. – user81112 Jul 31 '19 at 13:14
  • Unable to get dpkg lock simply means that another process, typically Update Manager is active. Please wait 5-10 minutes and try again. Update Manager runs in the background and pops up a window to say that updates are available and asks if you'd like to install them. The only way it can do this is to start the process in the background. – chili555 Jul 31 '19 at 13:35
  • I believe that the steps I outlined above will not work at all. I have found another process that I've tested on an 18.04.1 VM and I will edit the answer above to outline it. – chili555 Jul 31 '19 at 13:36
  • OK. Yeah. I tried what you added this morning and it didn't work. It was unable to locate the package(s) at tomaspino. I'll wait and try again and also wait for your next suggestion. Again, thank you so much for helping me! – user81112 Jul 31 '19 at 15:45
  • Make sure you are connected to the internet. Once you are connected, git clone should work well. – chili555 Jul 31 '19 at 15:57
  • So, I upgraded successfully to 19.04 yesterday and tried the above with the same result. The error message read E: Unsupported file ./dkms-install.sh given on commandline – user81112 Aug 02 '19 at 17:15
  • Please confirm that dkms is installed: sudo dpkg -s dkms Also, is the file executable? ls -al dkms-install.sh It ought to report -rwxr-xr-x where 'x' means 'executable.' – chili555 Aug 02 '19 at 20:03
  • dkms is not installed. – user81112 Aug 03 '19 at 01:01
  • Please retrace the steps above. All of the prerequisites are required. After you install them all, including dkms, try again. – chili555 Aug 03 '19 at 01:39
  • Success! I don't know why it worked this time or why it didn't before, but...THANK YOU SO MUCH!!!!!!! – user81112 Aug 04 '19 at 17:06
  • Awesome! If my answer has been helpful, please accept it: https://askubuntu.com/tour The searchers will appreciate it. – chili555 Aug 04 '19 at 18:34
  • Done. Thank you, again, chili! – user81112 Aug 04 '19 at 19:43
  • 1
    Its really really helpful – Nikhil Gyan Jan 17 '20 at 07:31
0

Pre-requisites:

  1. The command 'lspci' shows the wireless card as RTL8821CE

  2. You have a successful internet connection through USB thetering

I had a similar problem with my newly purchased Lenovo-V145-15AST, as Ubuntu did not find an active WiFi adapter after installing Ubuntu 18.04.3 LTS.

As the wireless card was not found during Ubuntu installation, updates and upgrades were not performed during the installation. It seems that this prevented the successful installation of the driver for the RTL8821CE wireless card when I followed the advice of various posts on this issue.

What worked for me, provided that the command lspci does indeed list the wireless card, and that one has managed to theter via smartphone-USB, was the following:

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install git

as suggested in the second answer to this question: https://stackoverflow.com/questions/56901922/error-showing-in-the-installation-of-git-in-ubuntu-18-04-2lts

Then followed this to the letter: https://github.com/tomaspinho/rtl8821ce

After rebooting, the wireless card was up and connecting to my WiFi.