The last resort is, I mean, if you have tried everything else still no luck, then if it’s a DEV box, you can refresh the box from another DEV box. Since you are AX 2012 R2, once the transaction database and modelstore database are restored, do the full system compile, sync data, full CIL. If you use version control, sync your code with depot as well. You should be good to go.