I mounted a partition on /usr accidentally. Hence, I have lost access to sudo command and can't unmount the partion. I am using AWS EC2 instance and don't have password for root user set.

What are my options? Will reboot unmount the newly mounted partition and will I get access to content of /usr again? Or else, how can I get root access? Are there any threat of data loss or system going to unusable state after reboot?

Any help would be appreciated.

share|improve this question
    
If you have the root account (password) enabled, you can do su and then umount the partition.. – heemayl Apr 10 '16 at 3:31
1  
@heemayl I didn't had root account enabled. So, was out of this option. Reboot resolved the issue. – Rumit Parakhiya Apr 10 '16 at 5:42
    
A reboot will help you (as told above). This is not a weird thing. System administrators do this to save their time (by actually not creating a new mount point). Source: A Flickr DevOps. – Avineshwar Apr 10 '16 at 11:05
up vote 17 down vote accepted

Yes; a reboot will get rid of the mount.

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.