stop-yarn.cmd 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. @echo off
  2. @rem Licensed to the Apache Software Foundation (ASF) under one or more
  3. @rem contributor license agreements. See the NOTICE file distributed with
  4. @rem this work for additional information regarding copyright ownership.
  5. @rem The ASF licenses this file to You under the Apache License, Version 2.0
  6. @rem (the "License"); you may not use this file except in compliance with
  7. @rem the License. You may obtain a copy of the License at
  8. @rem
  9. @rem http://www.apache.org/licenses/LICENSE-2.0
  10. @rem
  11. @rem Unless required by applicable law or agreed to in writing, software
  12. @rem distributed under the License is distributed on an "AS IS" BASIS,
  13. @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. @rem See the License for the specific language governing permissions and
  15. @rem limitations under the License.
  16. @rem
  17. setlocal enabledelayedexpansion
  18. echo stopping yarn daemons
  19. if not defined HADOOP_BIN_PATH (
  20. set HADOOP_BIN_PATH=%~dp0
  21. )
  22. if "%HADOOP_BIN_PATH:~-1%" == "\" (
  23. set HADOOP_BIN_PATH=%HADOOP_BIN_PATH:~0,-1%
  24. )
  25. set DEFAULT_LIBEXEC_DIR=%HADOOP_BIN_PATH%\..\libexec
  26. if not defined HADOOP_LIBEXEC_DIR (
  27. set HADOOP_LIBEXEC_DIR=%DEFAULT_LIBEXEC_DIR%
  28. )
  29. call %HADOOP_LIBEXEC_DIR%\yarn-config.cmd %*
  30. if "%1" == "--config" (
  31. shift
  32. shift
  33. )
  34. @rem stop resourceManager
  35. Taskkill /FI "WINDOWTITLE eq Apache Hadoop Distribution - yarn resourcemanager"
  36. @rem stop nodeManager
  37. Taskkill /FI "WINDOWTITLE eq Apache Hadoop Distribution - yarn nodemanager"
  38. @rem stop proxy server
  39. Taskkill /FI "WINDOWTITLE eq Apache Hadoop Distribution - yarn proxyserver"
  40. endlocal