[OT] How to fix a stupid chmod mistake without rebooting
Derek Broughton
derek at pointerstop.ca
Sat Mar 28 12:39:07 UTC 2009
Matthew Flaschen wrote:
> So by this point I am rather unhappy, and wondering if I'm going to
> break out a rescue CD. But of course, I had root enabled on this
> machine, so I finally remembered the virtual terminal (already running
> login) could save me:
>
> Login as root. Enter:
>
> sudo chmod a+rx /
"sudo" would be a bit of overkill here :-)
>
> Save the day.
>
> Lessons (pick any two)
>
> 1. Keep root enabled
> 2. sudo will not stop you from making stupid decisions.
> 3. Don't run sudo chmod a-rwx /
I'm not sure those are the right lessons.
Lesson 1: You don't need a rescue CD to rescue yourself in this situation
(or a root account). Simply reboot into single user mode.
Lesson 2: It probably should be at least mildly difficult to fix such
errors, to discourage you from doing it again :)
--
derek
More information about the ubuntu-users
mailing list