start-all.cmd 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  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. setlocal enabledelayedexpansion
  17. @rem Start all hadoop daemons. Run this on master node.
  18. echo This script is Deprecated. Instead use start-dfs.cmd and start-yarn.cmd
  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%\hadoop-config.cmd %*
  30. if "%1" == "--config" (
  31. shift
  32. shift
  33. )
  34. @rem start hdfs daemons if hdfs is present
  35. if exist %HADOOP_HDFS_HOME%\sbin\start-dfs.cmd (
  36. call %HADOOP_HDFS_HOME%\sbin\start-dfs.cmd --config %HADOOP_CONF_DIR%
  37. )
  38. @rem start yarn daemons if yarn is present
  39. if exist %HADOOP_YARN_HOME%\sbin\start-yarn.cmd (
  40. call %HADOOP_YARN_HOME%\sbin\start-yarn.cmd --config %HADOOP_CONF_DIR%
  41. )
  42. endlocal