[Bug 1546702] Re: init-checkconf incorrectly passes an upstart script as valid

Janek Bogucki janekdb at gmail.com
Wed Feb 17 19:17:21 UTC 2016


The following does not solve the problem of init-checkconf incorrectly
reporting an invalid script as valid when an unknown option is included
but it does solve the problem of the script being invalid.

This is invalid,

script
exec $KAFKA_HOME/bin/kafka-server-start.sh $CONFIG_HOME/server.properties
end script

This is valid,

script
  exec $KAFKA_HOME/bin/kafka-server-start.sh $CONFIG_HOME/server.properties
end script

When the whitespacing is incorrect a more useful error message would be
useful.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to upstart in Ubuntu.
https://bugs.launchpad.net/bugs/1546702

Title:
  init-checkconf incorrectly passes an upstart script as valid

Status in upstart package in Ubuntu:
  New

Bug description:
  When I validate my upstart script with -v (an unknown option) the
  script is reported as valid.

  Without -v the script is reported as invalid but no information is
  provided about the cause of the fault.

    $ init-checkconf ../packages/kafka/kafka-broker.upstart.conf
    ERROR: File ../packages/kafka/kafka-broker.upstart.conf: syntax invalid:

    $ init-checkconf -v ../packages/kafka/kafka-broker.upstart.conf
    init-checkconf: unrecognised option '-v'
    File ../packages/kafka/kafka-broker.upstart.conf: syntax ok

  This is my upstart script,

  # Ubuntu upstart file at /etc/init/kafka-broker.conf

  description "Kafka Broker"

  limit nofile 32768 32768

  start on runlevel [2345]
  stop on [!12345]

  respawn
  respawn limit 2 5

  env CONFIG_HOME=/var/lib/kafka/config
  env KAFKA_HOME=/var/lib/kafka
  umask 007

  kill timeout 300

  setuid kafka
  setgid kafka

  script
    exec $KAFKA_HOME/bin/kafka-server-start.sh $CONFIG_HOME/server.properties
  end script

  ProblemType: Bug
  DistroRelease: Ubuntu 14.04
  Package: upstart 1.12.1-0ubuntu4.2
  ProcVersionSignature: Ubuntu 3.19.0-47.53~14.04.1-generic 3.19.8-ckt10
  Uname: Linux 3.19.0-47-generic x86_64
  ApportVersion: 2.14.1-0ubuntu3.19
  Architecture: amd64
  CurrentDesktop: Unity
  Date: Wed Feb 17 19:08:28 2016
  InstallationDate: Installed on 2015-10-21 (119 days ago)
  InstallationMedia: Ubuntu 14.04.3 LTS "Trusty Tahr" - Beta amd64 (20150805)
  SourcePackage: upstart
  UpgradeStatus: No upgrade log present (probably fresh install)
  UpstartBugCategory: Session
  UpstartRunningSessionCount: 1
  UpstartRunningSessionVersion: init (upstart 1.12.1)
  UpstartRunningSystemVersion: init (upstart 1.12.1)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/1546702/+subscriptions



More information about the foundations-bugs mailing list