소스 검색

AMBARI-9322. Installation of HDP stack fails on CentOS5 due to sudo and missing tty (aonishuk)

Andrew Onishuk 10 년 전
부모
커밋
c101ddfea9
1개의 변경된 파일5개의 추가작업 그리고 0개의 파일을 삭제
  1. 5 0
      ambari-agent/conf/unix/install-helper.sh

+ 5 - 0
ambari-agent/conf/unix/install-helper.sh

@@ -51,6 +51,11 @@ do_install(){
   fi
   
   chmod 440 "$SUDOERS_FILE"
+  
+  grep '^#includedir /etc/sudoers.d$' /etc/sudoers
+  if [ $? -ne 0 ] ; then
+    echo '#includedir /etc/sudoers.d' >> /etc/sudoers
+  fi
 }
 
 do_remove(){