2

I've accidently run chmod -R 600 / on ubuntu AWS Server. Tried stopping it but didn't happen. Is there a way by which I can atleast backup my data present in the server. Thanks.

Akshay R.
  • 23
  • 6

1 Answers1

3
  • Spin up another instance.
  • Mount the disk from the damaged instance on to a non root mount point (e.g. /mnt).
  • Backup your data
  • Recover to a new instance
user9517
  • 115,471
  • 20
  • 215
  • 297
  • Are you sure that's going to work? As the permissions are infected right now – Akshay R. Oct 06 '16 at 08:45
  • 2
    Yes it will work, mounting the `broken` volume on a non root mount point will not affect the clean newly setup instance. You can then back it up and/or try to fix the permissions. I'd start with something like `find /broken_mount_point -type d -exec chmod u+x {} \;` and work from there. – Unbeliever Oct 06 '16 at 09:00
  • Still unable to access any file. Says permission denied on every command even cd – Akshay R. Oct 06 '16 at 12:46
  • Got it working by following some directions from other questions. Thanks guys @Unbeliever and hangin-on-in-quiet-desperation. Specially for the confidence in such a crazy situation. – Akshay R. Oct 06 '16 at 12:57