NixOS rebuild causing SSD and boot errors

I was running NixOS with windows 11 dual boot unstable for a month now, I tried to update my system using nix flake update and then nixos-rebuild switch. I have done this many a times before, but this time my laptop froze ( it freezes before too due to CPU/ram being overheated). I force shut it down and to my surprise, when I rebooted, I couldn’t boot into windows either, after some troubleshooting in bios (turing on/off quiet mode) I was able to boot into windows, but not into Nix.
I decided to reinstall nix, but still whenever I try to build using my config from before the flake update, I get the following errors, at random parts of the installation phase and then again I am not able to boot into windows too, until i toggle quiet mode on/off and shutdown my laptop.
Laptop - MSI GP76 11UG (I7 11800H RTX 3070)
I have tried reinstalling nix 4 times, once with Plasma and 3 times with no desktop, and got the same issue everytime.

NamitBhutani/nixos-config ( This is my config
Please help me, with pointers if any. TIA :smiley:

Modern hardware doesn’t really freeze from overheating. It throttles and becomes kinda slow, but it doesn’t crash. Nor would overheating kill a windows install.

Your hardware is dead, most likely the drive. All those I/O error messages are telling you the drive is not functioning anymore. This probably had nothing to do with nixos-rebuild or anything like that; drives have limited lifespan, and sometimes they just die.

1 Like