Update shared.h

Added nid to the struct to hold the numerical id of machines.
Removed unnecessary variables.