0

I am currently using Ubuntu and am 100% new to Unix. I have installed Ubuntu to program in C and will be using the "Learn C the Hard Way" online textbook (http://c.learncodethehardway.org/book/ex0.html). I attempted the section in the textbook meant for setting up your computer and the second command is causing me some problems.

The first command in the link above executes without issue but when I try and run the second command:

$ su -c yum groupinstall development-tools

it prompts me for my password and when I enter it, it says

su: Authentication Failure

How do I fix this?

4

Look again at the web page. You are trying, wrongly, to run a command for an RPM based Linux like Fedora. Instead, run the command that says:

For Debian based systems, like Ubuntu you should just have to install a few things using these commands:

$ sudo apt-get install build-essential
2

Ubuntu is Debian based, use the first command and leave the second which is for Redhat based like Fedora.

Linux

On most Linux systems you just have to install a few packages. For Debian based systems, like Ubuntu you should just have to install a few things using these commands:

$ sudo apt-get install build-essential

The above is an example of a command line prompt, so to get to where you can run that, find your "Terminal" program and run it first. Then you'll get a shell prompt similar to the $ above and can type that command into it. Do not type the $, just the stuff after it.

Here's how you would install the same setup on an RPM based Linux like Fedora:

$ su -c "yum groupinstall development-tools"

Once you've run that, you should be able to do the first Exercise in this book and it'll work. If not then let me know.

Anyway, that error message from su because you need to enter the root password. It is not the same as sudo which you use your own user password.

  • 2
    Man that guy is right, I have no reading comprehension. Thank you. – Kai B Sep 8 '15 at 17:41
  • the terminal program is run by entering: <ctr;l><alt><T> – user3629249 Sep 8 '15 at 18:26

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.