private boolean startElections() {
    try {
      System.out.println(father.getId() + ": Starting election process");

      msg = new Message(father.getId(), EnumMessageType.ELECTION_S);
      bout = new ByteArrayOutputStream();
      oos = new ObjectOutputStream(bout);
      oos.writeObject(msg);
      bSend = bout.toByteArray();
      pack = new DatagramPacket(bSend, bSend.length, InetAddress.getByName("255.0.0.5"), 10602);

      if (resp != null && !resp.isClosed()) {
        resp.close();
      }
      resp = new ServerSocket(11149);
      resp.setSoTimeout(5000);
      elections.send(pack);
      respSock = null;
      try {
        respSock = resp.accept();
      } catch (IOException ioe) {
        try {
          System.out.println(father.getId() + ": No one responded, I'm coordinator");
          /*
           * I'm the new coordinator, notify all
           */

          msg = new Message(father.getId(), EnumMessageType.COORDINATOR);
          bout = new ByteArrayOutputStream();
          oos = new ObjectOutputStream(bout);
          oos.writeObject(msg);
          bSend = bout.toByteArray();
          pack = new DatagramPacket(bSend, bSend.length, InetAddress.getByName("255.0.0.5"), 10602);
          elections.send(pack);
          father.setCoordId(father.getId());
          CoordinatorFunctions cf = new CoordinatorFunctions(father);
          cf.start();
          return true;
        } catch (IOException ex) {
          System.out.println(ex.getMessage());
        }
      }


      /*
       * If here, a response was received, wait for coordinator
       */
      System.out.println(father.getId() + ": A response was received, waiting "
              + "for coordinator");
      int mcRet = listenMulticast();
      while ((mcRet == 1) || (mcRet == -1)) {
        mcRet = listenMulticast();
      }

      if (mcRet == 0) {
        System.out.println(father.getId() + ": Socket timed out, restarting "
                + "elections");
        return startElections();
      } else {
        System.out.println(father.getId() + ": Coordinator elected and saved");
        return false;
      }
    } catch (SocketException se) {
      System.out.println("Error Socket1: " + se.getMessage());
    } catch (IOException ioe) {
      System.out.println("Error Socket2: " + ioe.getMessage());
    }
    return false;
  }