0

this command fails when it is being run by a user that is different from myuser and having sudo rights:

sudo su - -c "export KAFKA_OPTS=-Djava.security.auth.login.config=/etc/kafka/conf/kafka_jaas.conf;/usr/hdp/current/kafka-broker/bin/kafka-configs.sh --zookeeper hostname1:2181,hostname2:2181,hostname3:2181 --alter --entity-type topics --entity-name topicname1 --add-config max.message.bytes=5" kafka

when logged in as kafka, this succeeds:

export KAFKA_OPTS=-Djava.security.auth.login.config=/etc/kafka/conf/kafka_jaas.conf;/usr/hdp/current/kafka-broker/bin/kafka-configs.sh --zookeeper hostname1:2181,hostname2:2181,hostname3:2181 --alter --entity-type topics --entity-name topicname1 --add-config max.message.bytes=5

Usually the su wrapped command works as well, I have a special case where it does not work. How can this be possible?

bpgergo
  • 177

0 Answers0