String lastId = null;
try{
tailServer = (Address) Network.getAddress(Benchmark.getServerId(TAIL));
tail = (INode)LocateRegistry.getRegistry(tailServer.inetAddress.getHostAddress(), tailServer.port).lookup(TAIL);
Network.linkDelay(true, tailServer);
tail.lock();
Network.linkDelay(true, tailServer);
lastId = tail.getNext(); //Got Id for last node in queue
lastServer = (Address) Network.getAddress(Benchmark.getServerId(lastId));
last = (INode)LocateRegistry.getRegistry(lastServer.inetAddress.getHostAddress(), lastServer.port).lookup(lastId);