Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Following the wiki's advice, I installed ubuntu-zfs. However, once everything installed correctly, and I tried installing another application via apt-get, I get a weird issue with my sudoers file:

max@host:~$ sudo apt-get install deluge deluge-web
sudo: /etc/sudoers.d/zfs is mode 0644, should be 0440
>>> /etc/sudoers.d/README: /etc/sudoers.d/zfs near line 18 <<<
sudo: parse error in /etc/sudoers.d/README near line 18
sudo: no valid sudoers sources found, quitting
*** glibc detected *** sudo: double free or corruption (!prev): 0x08909d08 ***
======= Backtrace: =========
....

Why has zfs messed with the sudoers file? I can post the backtrace if needed.

share|improve this question

2 Answers 2

up vote 1 down vote accepted

I just had the same problem, I guess there must be a recent change to that package. To fix it: (Taken from here: "no valid sudoers sources found, quitting" error, how to fix it?)

Enter recovery mode (reboot, hold down the SHIFT key after your bios post has finished until the ubuntu menu shows, and select recovery with network). At the prompt, type these commands:

chown -R root:root /etc/sudoers.d
chmod u=rwx,g=rx,o=rx /etc/sudoers.d/
chmod u=r,g=r,o= /etc/sudoers.d/*

As to your actual question (why does zfs need sudo rights) - I dont know!

share|improve this answer
    
Thanks for making an account to answer my question :) And yeah, I tried that and got some weird boot errors. I ended up reinstalling Ubuntu and not zfs works. Glad I'm not the only one confused by this. –  MaxMackie Jun 17 '12 at 20:23
1  
In the future, on a desktop Ubuntu system, you don't have to boot into recovery mode to run commands as root to fix a broken sudo. Ubuntu provides two mechanisms for administrators to run programs as root while logged in to their non-root accounts: sudo, and PolicyKit. You can use pkexec to run a command as root in much the same way as you'd use sudo. See this question for more information. –  Eliah Kagan Jun 18 '12 at 0:44

This worked for me:

pkexec chmod 440 /etc/sudoers.d/zfs
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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