LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 03-23-2021, 06:43 PM   #1
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 22.04
Posts: 2,151

Rep: Reputation: 73
What exactly is DKMS?


I installed Ubuntu 20.04 on a new HP laptop. HP uses Realtek rtl8821ce wifi card.

That does not work out of the box in Linux.

I bought a usb wifi, got the new laptop connected to the net.

I installed gcc.

I read I need to install DKMS.

During the installation, I got a purple bash type window.

It asked me for a password. 2 times. Said, I would need it on boot or the 3rd party modules would not work.

Then I installed the Ubuntu deb package for the Realtek rtl8821ce wifi card

On reboot, the first time, I did see a screen mentioning manage MOK, but I went with the first option, which was .... I can't remember.

I was not asked for a password.

The Realtek wifi still does not work.

But, subsequent boots do not show any mention of MOK manager, it just goes to grub straight away.

I will try to reinstall from scatch.

Should I disable "Secure boot" in the BIOS?
 
Old 03-23-2021, 08:04 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,361

Rep: Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692Reputation: 3692
I wouldn't disable secure boot on modern supported distro's. There does seem to be a few posts that suggest it is the issue. Can't really hurt to disable it though.

DKMS is dynamic Kernel module support or something. For loading modules.https://docs.01.org/clearlinux/lates...ules-dkms.html

https://askubuntu.com/questions/1071...n-ubuntu-18-04
 
1 members found this post helpful.
Old 03-23-2021, 08:08 PM   #3
computersavvy
Senior Member
 
Registered: Aug 2016
Posts: 3,345

Rep: Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486
A search engine is your friend. It finds many answers much faster than a post in a forum.

The password request while installing dkms was asking for the users password. To install software you need root priviledges and many packages and installation tools now prompt you for that password so they can use sudo to complete the install.

dkms is the tool that builds kernel modules during install as explained here.

There should have been no need to install dkms from a thirdparty source since almost all distros that use it include it in the initial install. I know that Ubuntu 20.04 has it so your install may have damaged the original version in the distro.

You need to search for the rtl8821 driver fixes. The one included as a deb may not be up to date with the latest chipsets used and there are several posts on how to fix that. Several on this linuxquestions site.


I searched for "rtl8821ce driver" in these forums (search link at the top) and found 25 threads on the subject.

Last edited by computersavvy; 03-23-2021 at 08:13 PM.
 
1 members found this post helpful.
Old 03-23-2021, 11:06 PM   #4
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Rep: Reputation: 153Reputation: 153
From your description you appear to be missing all of the steps to create your own keys and then sign your newly compiled Realtek kernel module with them.

Quote:
On reboot, the first time, I did see a screen mentioning manage MOK, but I went with the first option, which was .... I can't remember.
Adding your own keys to the MOK list only makes sense if you have first generated your own keys with openssl tools.

The following guide explains how to do this for Ubuntu.

https://ubuntu.com/blog/how-to-sign-...or-secure-boot

Quote:
During the installation, I got a purple bash type window.
It asked me for a password. 2 times. Said, I would need it on boot or the 3rd party modules would not work.
This was likely part of the MOK enrolment phase. If you first didn't generate a key pair you don't have anything to enroll. The "3rd party modules" refer to kernel modules from external sources such as the Realtek module you are trying to compile.

Quote:
The Realtek wifi still does not work.
This is to be expected as you didn't generate a key pair, sign your module with it and then add it to the MOK list.

Quote:
I searched for "rtl8821ce driver" in these forums (search link at the top) and found 25 threads on the subject.
The OP needs help in how to sign their own kernel modules and add their own keys to UEFI. You didn't mention this at all in your post or perhaps even realize their problem.

Last edited by tofino_surfer; 03-23-2021 at 11:08 PM.
 
Old 03-23-2021, 11:22 PM   #5
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 22.04
Posts: 2,151

Original Poster
Rep: Reputation: 73
@computersavvy: You were right:

Quote:
You need to search for the rtl8821 driver fixes
I found what looks like a promising solution on GeeksforGeeks.org (I get a lot of tips there for Python, they are good!)

I'll try it when I get home tonight. They recommend

Quote:
Clone the Realtek RTL8821CE Driver using the following command.

git clone https://github.com/tomaspinho/rtl8821ce
The password I was talking about above was not my sudo password, just a password that DKMS asked for on install.

I think I got that step wrong on reboot, I was never asked again for that password, and the Realtek wifi won't work, like they said.

Anyway, I will start from scratch, reinstall everything.
 
Old 03-24-2021, 05:09 AM   #6
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,843

Rep: Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682
Quote:
Should I disable "Secure boot" in the BIOS?
Unless you won't to go through the steps of signing the driver to work with secure boot as tofino_surfer has suggested then yes you want to disable secure boot for the wifi module to work.
 
Old 03-24-2021, 06:47 AM   #7
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 22.04
Posts: 2,151

Original Poster
Rep: Reputation: 73
I have some pics to show you, perhaps you will better understand the password I am talking about.

I did a complete reinstall, this time with a usb wifi dongle plugged in. Please see the first pic.

The first pic is the Ubuntu 20.04 installer. I clicked, "Install third party software for graphics and wifi hardware ...."

If you click that, you need a password.

After the installation completes, on reboot, I got a "Perform MOK management" screen.

I tried the second choice "enroll MOK"

The Realtek rtl28821ce on the HP laptop still does not work!

Any tips please?
Attached Thumbnails
Click image for larger version

Name:	1616585374305.jpg
Views:	38
Size:	84.2 KB
ID:	35908   Click image for larger version

Name:	1616585344941.jpg
Views:	30
Size:	56.2 KB
ID:	35909  
 
Old 03-24-2021, 01:50 PM   #8
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Rep: Reputation: 153Reputation: 153
You obviously didn't read the guide I linked.

Quote:
After the installation completes, on reboot, I got a "Perform MOK management" screen.
I tried the second choice "enroll MOK"
This only makes sense if you actually generated a public/private key pair using an x.509 certificate with openssl. Did you do this first ?

Quote:
The Realtek rtl28821ce on the HP laptop still does not work!
No kidding. No need for screaming. You obviously didn't do any of the steps in the guide I linked.

Quote:
Any tips please?
Tips ? The guide I linked https://ubuntu.com/blog/how-to-sign-...or-secure-boot
explains exactly what you need to do. If you had even read it you wouldn't have made this post. You were told what the problem was and given a guide on how to solve it and you are simply repeating the complaining in your first post.

By the way there is no need to use the installer to do this. All of the steps can be performed manually on a regular installation as the guide shows. Except for the wifi not working there is probably nothing else wrong with your installation.

Last edited by tofino_surfer; 03-24-2021 at 01:56 PM.
 
1 members found this post helpful.
Old 03-24-2021, 02:33 PM   #9
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,843

Rep: Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682Reputation: 1682
Why not disable secure boot and be done with it?
 
Old 03-24-2021, 02:53 PM   #10
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Rep: Reputation: 153Reputation: 153
Quote:
Why not disable secure boot and be done with it?
This assumes that they are able to disable secure boot. Unfortunately there are many Windows 10 laptops that are installed either with Secure Boot locked down or where Windows won't run if Secure Boot is disabled. Since many new Ubuntu users will want to dual boot with Windows this would cause a problem. Ubuntu along with Fedora and several others are the few Linux distros that can handle SB. It is a valuable skill to be able to sign your own modules and add your own MOK to the accepted key list.
 
1 members found this post helpful.
Old 03-24-2021, 03:08 PM   #11
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 22.04
Posts: 2,151

Original Poster
Rep: Reputation: 73
Thank you all for your advice! I appreciate it, as I really am not so savvy as far as this stuff is concerned.

This morning, around 4am (I'm an early riser) I fixed it.

If you have this trouble you can try this:

1. Get the computer with the wifi problem connected to the net somehow. I bought a usb wifi dongle, 75 Yuan, about US$11.

2. Go to here

3. Follow the instructions, then reboot

Done, solved, thank you to geeksforgeeks.org
 
Old 03-24-2021, 04:31 PM   #12
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Rep: Reputation: 153Reputation: 153
Quote:
1. Get the computer with the wifi problem connected to the net somehow. I bought a usb wifi dongle, 75 Yuan, about US$11.
You were lucky that this worked. Most usb wifi dongles use Realtek chips. It could have failed to run the same way the built-in one failed.

The standard advice given in this guide is to use an ethernet cable and plug your computer directly into the modem.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
dkms-nvidia-current dkms install fails X86_64 Blackhawkckc Mandriva 5 03-21-2009 04:57 PM
mandriva 2005 - dkms ati High-gain Mandriva 2 01-21-2006 01:50 AM
nvidia dkms service boot chil326 Linux - Hardware 6 08-10-2005 09:26 AM
tinkering with dkms: make error no targets. Makefile issue? Emmanuel_uk Linux - Newbie 1 06-03-2005 01:26 AM
DKMS in Slackware laboyae Linux - Hardware 2 03-31-2005 10:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 07:51 PM.

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