FAQ
Hello,
   I am new to CDH4, my zookeeper worked fine but now is in bad health.
I can not start and I'll get this error
ERROR org.apache.zookeeper.server.ZooKeeperServerMain

Unexpected exception, exiting abnormally
java.net.BindException: Address already in use
  at sun.nio.ch.Net.bind(Native Method)
  at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
  at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
  at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
  at org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:100)
  at org.apache.zookeeper.server.ZooKeeperServerMain.runFromConfig(ZooKeeperServerMain.java:115)
  at org.apache.zookeeper.server.ZooKeeperServerMain.initializeAndRun(ZooKeeperServerMain.java:91)
  at org.apache.zookeeper.server.ZooKeeperServerMain.main(ZooKeeperServerMain.java:53)
  at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:121)
  at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)

Search Discussions

  • Harsh J at Oct 12, 2012 at 5:13 pm
    Hi David,

    Seems to me like ZK somehow is already running (maybe this happened after a
    reboot?)

    Here's how I'd troubleshoot this on *nix:

    $ netstat -anp | egrep "2181|2888|3888" # To find the process ID(s) already
    binding on these ports
    $ kill <Identified Process IDs>
    # Now restart via CM, should work

    Also I'd check if the package "zookeeper-server" is installed on the
    machine and remove it, as it is a service script package not needed in
    environments of Cloudera Manager. Presence of this may cause ZK to start up
    on its own when a machine is rebooted, and then later when CM tries to
    start its managed instance of ZK, it runs into a port-bound conflict as we
    witness here.

    Let us know if this helps.
    On Fri, Oct 12, 2012 at 7:15 PM, David Shapourian wrote:

    Hello,
    I am new to CDH4, my zookeeper worked fine but now is in bad health.
    I can not start and I'll get this error
    ERROR org.apache.zookeeper.server.ZooKeeperServerMain

    Unexpected exception, exiting abnormally
    java.net.BindException: Address already in use
    at sun.nio.ch.Net.bind(Native Method)
    at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:100)
    at org.apache.zookeeper.server.ZooKeeperServerMain.runFromConfig(ZooKeeperServerMain.java:115)
    at org.apache.zookeeper.server.ZooKeeperServerMain.initializeAndRun(ZooKeeperServerMain.java:91)
    at org.apache.zookeeper.server.ZooKeeperServerMain.main(ZooKeeperServerMain.java:53)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:121)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)


    --
    Harsh J
  • Ashok Polapragada at Feb 1, 2014 at 12:46 pm

    On Friday, October 12, 2012 7:15:57 PM UTC+5:30, David Shapourian wrote:
    Hello,
    I am new to CDH4, my zookeeper worked fine but now is in bad health.
    I can not start and I'll get this error
    ERROR org.apache.zookeeper.server.ZooKeeperServerMain

    Unexpected exception, exiting abnormally
    java.net.BindException: Address already in use
    at sun.nio.ch.Net.bind(Native Method)
    at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:100)
    at org.apache.zookeeper.server.ZooKeeperServerMain.runFromConfig(ZooKeeperServerMain.java:115)
    at org.apache.zookeeper.server.ZooKeeperServerMain.initializeAndRun(ZooKeeperServerMain.java:91)
    at org.apache.zookeeper.server.ZooKeeperServerMain.main(ZooKeeperServerMain.java:53)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:121)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)

    To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
  • Darren Lo at Feb 1, 2014 at 8:09 pm
    Hi Ashok,

    It looks like something else is using that port. This is very likely to be
    a zookeeper process that is not managed by Cloudera Manager, usually
    because you accidentally installed the zookeeper-server package, which only
    contains init scripts and should not be installed when using Cloudera
    Manager.

    To check for these kinds of issues, click on the Hosts tab in Cloudera
    Manager, then click on Host Inspector. It will report all potentially
    conflicting init scripts. You should disable all of these by uninstalling
    the problematic package or configuring them to not start. You will probably
    need to kill any such rogue processes also.

    Thanks,
    Darren

    On Sat, Feb 1, 2014 at 4:46 AM, Ashok Polapragada wrote:


    On Friday, October 12, 2012 7:15:57 PM UTC+5:30, David Shapourian wrote:

    Hello,
    I am new to CDH4, my zookeeper worked fine but now is in bad health.
    I can not start and I'll get this error
    ERROR org.apache.zookeeper.server.ZooKeeperServerMain

    Unexpected exception, exiting abnormally
    java.net.BindException: Address already in use
    at sun.nio.ch.Net.bind(Native Method)
    at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:100)
    at org.apache.zookeeper.server.ZooKeeperServerMain.runFromConfig(ZooKeeperServerMain.java:115)
    at org.apache.zookeeper.server.ZooKeeperServerMain.initializeAndRun(ZooKeeperServerMain.java:91)
    at org.apache.zookeeper.server.ZooKeeperServerMain.main(ZooKeeperServerMain.java:53)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:121)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)


    To unsubscribe from this group and stop receiving emails from it, send
    an email to [email protected].


    --
    Thanks,
    Darren

    To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
  • Darren Lo at Feb 3, 2014 at 4:29 pm
    Glad you fixed the problem! Including thread to let others know this worked.

    On Sat, Feb 1, 2014 at 8:50 PM, Ashok Polapragada wrote:

    Hi Darren,

    In most of the cases, I found its rogue processes that are causing the
    problem. Thanks for the insight.

    Regards,
    --
    Ashok Polapragada
    Principal Consultant
    ZettaMine Technologies



    On Sun, Feb 2, 2014 at 1:39 AM, Darren Lo wrote:

    Hi Ashok,

    It looks like something else is using that port. This is very likely to
    be a zookeeper process that is not managed by Cloudera Manager, usually
    because you accidentally installed the zookeeper-server package, which only
    contains init scripts and should not be installed when using Cloudera
    Manager.

    To check for these kinds of issues, click on the Hosts tab in Cloudera
    Manager, then click on Host Inspector. It will report all potentially
    conflicting init scripts. You should disable all of these by uninstalling
    the problematic package or configuring them to not start. You will probably
    need to kill any such rogue processes also.

    Thanks,
    Darren


    On Sat, Feb 1, 2014 at 4:46 AM, Ashok Polapragada <
    [email protected]> wrote:
    On Friday, October 12, 2012 7:15:57 PM UTC+5:30, David Shapourian wrote:

    Hello,
    I am new to CDH4, my zookeeper worked fine but now is in bad health.
    I can not start and I'll get this error
    ERROR org.apache.zookeeper.server.ZooKeeperServerMain

    Unexpected exception, exiting abnormally
    java.net.BindException: Address already in use
    at sun.nio.ch.Net.bind(Native Method)
    at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
    at org.apache.zookeeper.server.NIOServerCnxnFactory.configure(NIOServerCnxnFactory.java:100)
    at org.apache.zookeeper.server.ZooKeeperServerMain.runFromConfig(ZooKeeperServerMain.java:115)
    at org.apache.zookeeper.server.ZooKeeperServerMain.initializeAndRun(ZooKeeperServerMain.java:91)
    at org.apache.zookeeper.server.ZooKeeperServerMain.main(ZooKeeperServerMain.java:53)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(QuorumPeerMain.java:121)
    at org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.java:79)


    To unsubscribe from this group and stop receiving emails from it, send
    an email to [email protected].


    --
    Thanks,
    Darren

    --
    Thanks,
    Darren

    To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupscm-users @
categorieshadoop
postedOct 12, '12 at 2:08p
activeFeb 3, '14 at 4:29p
posts5
users4
websitecloudera.com
irc#hadoop

People

Translate

site design / logo © 2023 Grokbase