Managing tape drives and robotic libraries