0

I used to have fingerprint authentication support in my /etc/pam.d/sudo file by following this article; however, I made a typo in the file, spelling pam_tid.so as pam.tid.so and so now when I run sudo from the terminal, I get the following error:

sudo: unable to initialize PAM: No such file or directory

How can I recover from this? I have tried to go into recovery mode into the command line, but the /etc/pam.d/sudo file doesn't even exist from there.

6
  • 1
    you do not have root access?
    – binarysta
    May 18 '20 at 15:30
  • @binarysta yes I do. in recovery mode but the file doesn't exist. in the terminal I'm just logged in as my user and can't use sudo because I messed up the file May 18 '20 at 15:31
  • 1
    why not using su - and change the file name with root privileges ?
    – binarysta
    May 18 '20 at 15:33
  • Thanks @binarysta. That did the trick. I couldn't do it at first but it turns out it's because the root user was disabled. May 18 '20 at 16:09
  • Good! so you enabled root in rescue mode and then renamed the file?
    – binarysta
    May 18 '20 at 16:16
0

You can also reveal the file in the folder and change the permissions there.

open /etc/pam.d/

Permission change

Make sure to reset the permissions afterwards again.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.