sudon’t

sudo is a Linux command that gives one administrative privileges for the following command. There wouldn’t be much point in it if just anyone could use it, willy-nilly, so there is a list of users allowed stored in /etc/sudoers. One must “sudo” edit this file or, again, there would be no point in it.

Installing some new software, it created a new user and then tried to “sudo” from it. This failed and the installation crashed and burned.

The obvious solution: Add that new user to sudoers, run the installer again, then remove the user from the file.

The problem: I made a “cannot parse the file” typo when editing the file.

This prevented the sudo command from working because it couldn’t figure out whether or not I was authorized to sudo because it couldn’t read the file with the list of users.

The obvious solution: su to the root user and edit the file without “sudo”ing.

The problem: It computer is a Raspberry Pi, which comes without a root user password – it’s more secure, donchya know. su doesn’t work in that case.

There is a possible way around this: The Raspberry Pi doesn’t have a disk. It uses an SD card. One can mount this card on another computer, dig into the filesystem, edit the file, write it back to the SD card, then put the card back into the Pi.

Since this was only the second piece of software I installed, I decided it would be easier to start from scratch. So I did. It’s all better, now.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: