ambari-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Stadtler <a...@phdata.io>
Subject Re: Unable to stop ambari server
Date Thu, 09 Jun 2016 13:49:11 GMT
Looks like you have another ambari-server process running and the pid doesn’t match the one
in /var/run/ambari-server.pid. Which is the error when it fails to stop.

The error messages when you try and start are because the port is in use by  another process.

Can you post the output of the pids before and after the kill command and what command you
are using to kill it.

# ps ef | grep -i ambari-server

# kill command

# ps ef | grep -i ambari-server

> On Jun 9, 2016, at 8:40 AM, Lukáš Drbal <lukas.drbal@gmail.com> wrote:
> 
> Hi,
> 
> i am trying to stop sever and there is still one java process running. When i kill it
by kill command, its spawned again. Did i something wrong? Thanks
> 
> My environment:
> root@ambarisrv-01:~# cat /etc/lsb-release
> DISTRIB_ID=Ubuntu
> DISTRIB_RELEASE=14.04
> DISTRIB_CODENAME=trusty
> DISTRIB_DESCRIPTION="Ubuntu 14.04.4 LTS"
> root@ambarisrv-01:~# dpkg -l "ambari-*"
> Desired=Unknown/Install/Remove/Purge/Hold
> | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
> |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
> ||/ Name                                    Version                  Architecture   
         Description
> +++-=======================================-========================-========================-===================================================================================
> ii  ambari-agent                            2.2.2.0-460              amd64          
         Ambari Agent
> ii  ambari-metrics-assembly                 2.2.2.0-460              amd64          
         Ambari Metrics Assembly
> ii  ambari-server                           2.2.2.0-460              amd64          
         Ambari Server
> root@ambarisrv-01:~#
> 
> 
> What i try:
> 
> root@ambarisrv-01:~# /etc/init.d/ambari-server stop
> Using python  /usr/bin/python
> Stopping ambari-server
> Ambari Server stopped
> root@ambarisrv-01:~# /etc/init.d/ambari-server status
> Using python  /usr/bin/python
> Ambari-server status
> Ambari Server not running. Stale PID File at: /var/run/ambari-server/ambari-server.pid
> root@ambarisrv-01:~# ps aux | grep -i ambari-server
> root     23717  0.0  0.0  17988  1516 ?        Ss   13:28   0:00 bash /etc/init.d/ambari-server
start
> root     23728  0.5  0.0  55204 15168 ?        S    13:28   0:00 /usr/bin/python /usr/sbin/ambari-server.py
start
> root     23764  0.0  0.0   4440   648 ?        S    13:28   0:00 /bin/sh -c ulimit -n
10000 ; /usr/jdk64/jdk1.8.0_60/bin/java -server -XX:NewRatio=3 -XX:+UseConcMarkSweepGC -XX:-UseGCOverheadLimit
-XX:CMSInitiatingOccupancyFraction=60 -Dsun.zip.disableMemoryMapping=true   -Xms512m -Xmx2048m
-Djava.security.auth.login.config=/etc/ambari-server/conf/krb5JAASLogin.conf -Djava.security.krb5.conf=/etc/krb5.conf
-Djavax.security.auth.useSubjectCredsOnly=false -cp '/etc/ambari-server/conf:/usr/lib/ambari-server/*:/usr/share/java/postgresql-jdbc.jar'
org.apache.ambari.server.controller.AmbariServer > /var/log/ambari-server/ambari-server.out
2>&1 || echo $? > /var/run/ambari-server/ambari-server.exitcode
> root     23765  221  3.6 5746264 565880 ?      Sl   13:28   1:17 /usr/jdk64/jdk1.8.0_60/bin/java
-server -XX:NewRatio=3 -XX:+UseConcMarkSweepGC -XX:-UseGCOverheadLimit -XX:CMSInitiatingOccupancyFraction=60
-Dsun.zip.disableMemoryMapping=true -Xms512m -Xmx2048m -Djava.security.auth.login.config=/etc/ambari-server/conf/krb5JAASLogin.conf
-Djava.security.krb5.conf=/etc/krb5.conf -Djavax.security.auth.useSubjectCredsOnly=false -cp
/etc/ambari-server/conf:/usr/lib/ambari-server/*:/usr/share/java/postgresql-jdbc.jar org.apache.ambari.server.controller.AmbariServer
> root     23908  0.0  0.0  10460   960 pts/0    S+   13:28   0:00 grep --color=auto -i
ambari-server
> 
> root@ambarisrv-01:~# ambari-server stop
> Using python  /usr/bin/python
> Stopping ambari-server
> Ambari Server is not running
> 
> But webface still respond
> root@ambarisrv-01:~# nc localhost 8080
> GET /
> <!--
> * Licensed to the Apache Software Foundation (ASF) under one <TRUNCATED>
> 
> When i start it again, logs is full of messages like:
> 09 Jun 2016 13:00:24,512 ERROR [main] AmbariServer:844 - Failed to run the Ambari Server
> java.net.BindException: Address already in use
>         at sun.nio.ch.Net.bind0(Native Method)
>         at sun.nio.ch.Net.bind(Net.java:433)
>         at sun.nio.ch.Net.bind(Net.java:425)
>         at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
>         at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
>         at org.eclipse.jetty.server.nio.SelectChannelConnector.open(SelectChannelConnector.java:187)
>         at org.eclipse.jetty.server.AbstractConnector.doStart(AbstractConnector.java:316)
>         at org.eclipse.jetty.server.nio.SelectChannelConnector.doStart(SelectChannelConnector.java:265)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
>         at org.eclipse.jetty.server.Server.doStart(Server.java:293)
>         at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
>         at org.apache.ambari.server.controller.AmbariServer.run(AmbariServer.java:555)
>         at org.apache.ambari.server.controller.AmbariServer.main(AmbariServer.java:842)
> 
> -- 
> Save The World - http://www.worldcommunitygrid.org/ <http://www.worldcommunitygrid.org/>
> http://www.worldcommunitygrid.org/stat/viewMemberInfo.do?userName=LesTR <http://www.worldcommunitygrid.org/stat/viewMemberInfo.do?userName=LesTR>
> 
> LesTR


Mime
View raw message