sudoers is owned by uid 48, should be 0

May 1, 2017 206 views
Apache Ubuntu

For the second time while attempting to modify my php.ini file in a new Drupal 7 setup through Putty I managed to lose sudoers privileges with the error message "sudoers is owned by uid 48, should be 0"

Using AWS EC2 Linux instance running on Apache 2. This happened after sudo chown -R apache /etc/php.ini

Have tried various suggested appoaches, but do not have password for su since AWS uses ppk attachments for Putty and SSH

Is there possibly an easy command string fix? Doubt it, but thought I would check

3 Answers
hansen May 1, 2017
Accepted Answer
  • Thanks much. I saw that yesterday, and tried the pkexec command line. It returns that the command pkexec is not recognized. And, any suggestion to add a package that starts with sudo gets back to the problem of sudo not working!

    Any other ideas?

    • Are you logged in as root? Which version of Ubuntu are you using?

Thanks again, Well, perhaps I spoke inelegantly ... I am using Amazon Linux which in my experience has worked with ordinary Ubunto commands.

Amazon Linux AMI 2017.03.0 (HVM)

I am logged in as ec2-user, the AWS standard, with ppk file security

Thanks once again. After posting my question in this forum, I opened a support ticket with AWS tech. When this occurred the first time since I was working on a new installation, rather than solving on the terminal side, I just reinstalled the application. Now, with it happening a second time, I would like to figure out what is going on if for no other reason than I still have not been able to modify the file upload size in the php.ini. But, that is another matter… I have read those postings as well, but each installation is a bit different.

Have another answer? Share your knowledge.