Merge "Update installed state before creating data dirs." into main