This can be mostly handled in the planning. Plan for server failures, but datacenters will also offer 'remote hands'. You can store a bunch of spare parts in one of your racks (see rack-mount-drawers), then call up the DC, and ask them to swap component A in server B with spare C in drawer D.