fixed problem in syslog and conserver
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1486 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
		| @@ -136,16 +136,27 @@ sub setup_CONS | ||||
|         } elsif (! -e $ca_file2) { | ||||
| 	    print "conserver cannot be started because the file $ca_file2 cannot be found\n"; | ||||
|         } else { | ||||
|           my $cmd = "/etc/rc.d/init.d/conserver restart"; | ||||
|           my $cmd = "/etc/rc.d/init.d/conserver stop"; | ||||
|           my @out = xCAT::Utils->runcmd($cmd, 0); | ||||
|           if ($::RUNCMD_RC != 0) | ||||
|           {    # error | ||||
|             xCAT::MsgUtils->message("S", "Error starting Conserver"); | ||||
|             return 1; | ||||
|             xCAT::MsgUtils->message("S", "Error stopping conserver:".join("\n", @out)); | ||||
|           } else {	# Zero rc, but with the service cmds that does not mean they succeeded | ||||
|           	my $output = join("\n", @out); | ||||
|           	if (length($output)) { print "\n$output\n"; } | ||||
| 	    	else { print "\nconserver started\n"; } | ||||
| 	    	else { print "\nconserver stopped\n"; } | ||||
|           } | ||||
|         | ||||
|           $cmd = "/etc/rc.d/init.d/conserver start"; | ||||
|           @out = xCAT::Utils->runcmd($cmd, 0); | ||||
|           if ($::RUNCMD_RC != 0) | ||||
|           {    # error | ||||
|             xCAT::MsgUtils->message("S", "Error starting conserver:".join("\n", @out)); | ||||
|             return 1; | ||||
|           } else {      # Zero rc, but with the service cmds that does not mean they succeeded | ||||
|                 my $output = join("\n", @out); | ||||
|                 if (length($output)) { print "\n$output\n"; } | ||||
|                 else { print "\nconserver started\n"; } | ||||
|           } | ||||
|        } | ||||
|     } | ||||
|   | ||||
| @@ -36,7 +36,7 @@ if [[ $OSTYPE = linux* ]]; then | ||||
|       init="/etc/init.d/rsyslog" | ||||
|     fi | ||||
|   else  | ||||
|     if [[ $$OSVER = sles* ]] || [[ $$OSVER = suse* ]] || [[ -f /etc/SuSE-release ]]; then | ||||
|     if [[ $OSVER = sles* ]] || [[ $OSVER = suse* ]] || [[ -f /etc/SuSE-release ]]; then | ||||
|       #find out which syslog is used for SLES, syslog or syslog-ng | ||||
|       result=`grep "^SYSLOG_DAEMON=" $sysconfig 2>&1` | ||||
|       if [[ $result = *syslog-ng* ]]; then | ||||
|   | ||||
		Reference in New Issue
	
	Block a user