Bug 1439120 - heketi: failed to start heketi.service
Summary: heketi: failed to start heketi.service
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: heketi
Version: cns-3.5
Hardware: x86_64
OS: Linux
unspecified
urgent
Target Milestone: ---
: CNS 3.5
Assignee: Raghavendra Talur
QA Contact: Tejas Chaphekar
URL:
Whiteboard:
Depends On:
Blocks: 1415600
TreeView+ depends on / blocked
 
Reported: 2017-04-05 09:35 UTC by Tejas Chaphekar
Modified: 2019-01-02 05:53 UTC (History)
9 users (show)

Fixed In Version: heketi-4.0.0-6.el7rhgs
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-04-20 18:38:43 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2017:1111 0 normal SHIPPED_LIVE heketi bug fix and enhancement update 2017-04-20 22:37:02 UTC

Description Tejas Chaphekar 2017-04-05 09:35:28 UTC
Description of problem:

root@dhcp47-56 ~]# systemctl status heketi
● heketi.service - Heketi Server
   Loaded: loaded (/usr/lib/systemd/system/heketi.service; disabled; vendor preset: disabled)
   Active: failed (Result: start-limit) since Wed 2017-04-05 14:46:36 IST; 11s ago
  Process: 6088 ExecStart=/usr/bin/heketi -config=/etc/heketi/heketi.json (code=exited, status=255)
 Main PID: 6088 (code=exited, status=255)

Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: Unit heketi.service entered failed state.
Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: heketi.service failed.
Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: heketi.service holdoff time over, scheduling restart.
Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: start request repeated too quickly for heketi.service
Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: Failed to start Heketi Server.
Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: Unit heketi.service entered failed state.
Apr 05 14:46:36 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: heketi.service failed.

[root@dhcp47-56 ~]# cat /usr/lib/systemd/system/heketi.service
[Unit]
Description=Heketi Server

[Service]
Type=simple
WorkingDirectory=/var/lib/heketi
EnvironmentFile=-/etc/heketi/heketi.json
User=heketi
ExecStart=/usr/bin/heketi -config=/etc/heketi/heketi.json
Restart=on-failure
StandardOutput=syslog
StandardError=syslog

[Install]


Version-Release number of selected component (if applicable):

heketi-client-4.0.0-5.el7rhgs.x86_64

How reproducible:
 
Always

Steps to Reproduce:
1. Install heketi heketi-cli
2. Start heketi service


Actual results:

Heketi Service fails to start

Expected results:

Heketi should start successfully

Additional info:

Apr 05 10:08:52 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: Starting Heketi Server...
Apr 05 10:08:52 dhcp47-56.lab.eng.blr.redhat.com heketi[4021]: Error: unknown shorthand flag: 'c' in -config=/etc/heketi/heketi.json
Apr 05 10:08:52 dhcp47-56.lab.eng.blr.redhat.com heketi[4021]: unknown shorthand flag: 'c' in -config=/etc/heketi/heketi.json
Apr 05 10:08:52 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: heketi.service: main process exited, code=exited, status=255/n/a
Apr 05 10:08:52 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: Unit heketi.service entered failed state.
Apr 05 10:08:52 dhcp47-56.lab.eng.blr.redhat.com systemd[1]: heketi.service failed.

Comment 2 Daniel Messer 2017-04-05 09:45:08 UTC
Since heketi v4.0.0.0 the syntax for switch is with double dashes, that is --config instead of -config.

Comment 3 Humble Chirammal 2017-04-05 09:55:46 UTC
Upstream is correct to specify this:

https://github.com/heketi/heketi/blob/14686c02d98609290ef1d388eb33839c2c3637e2/extras/systemd/heketi.service

[Unit]
Description=Heketi Server

[Service]
Type=simple
WorkingDirectory=/var/lib/heketi
EnvironmentFile=-/etc/heketi/heketi.env
User=heketi
ExecStart=/usr/bin/heketi --config=/etc/heketi/heketi.json
Restart=on-failure
StandardOutput=syslog
StandardError=syslog

[Install]
WantedBy=multi-user.target

Comment 9 Tejas Chaphekar 2017-04-10 09:28:44 UTC
The bug has been resolved, please find the results as follows

[root@dhcp35-176 ~]# rpm -qa | grep heketi
heketi-client-4.0.0-6.el7rhgs.x86_64
heketi-4.0.0-6.el7rhgs.x86_64

[root@dhcp35-176 ~]# systemctl status heketi
● heketi.service - Heketi Server
   Loaded: loaded (/usr/lib/systemd/system/heketi.service; disabled; vendor preset: disabled)
   Active: inactive (dead)
[root@dhcp35-176 ~]# systemctl start heketi
[root@dhcp35-176 ~]# systemctl status heketi
● heketi.service - Heketi Server
   Loaded: loaded (/usr/lib/systemd/system/heketi.service; disabled; vendor preset: disabled)
   Active: active (running) since Mon 2017-04-10 05:11:02 EDT; 1s ago
 Main PID: 10339 (heketi)
   CGroup: /system.slice/heketi.service
           └─10339 /usr/bin/heketi --config=/etc/heketi/heketi.json

Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com systemd[1]: Started Heketi Server.
Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com systemd[1]: Starting Heketi Server...
Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com heketi[10339]: Heketi 4.0.0
Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com heketi[10339]: [heketi] INFO 2017/04/10 05:11:02 Loaded mock executor
Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com heketi[10339]: [heketi] INFO 2017/04/10 05:11:02 Loaded simple allocator
Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com heketi[10339]: [heketi] INFO 2017/04/10 05:11:02 GlusterFS Application Loaded
Apr 10 05:11:02 dhcp35-176.lab.eng.blr.redhat.com heketi[10339]: Listening on port 8080


[root@dhcp35-176 ~]# curl http://localhost:8080/hello
Hello from Heketi

Comment 10 errata-xmlrpc 2017-04-20 18:38:43 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2017:1111


Note You need to log in before you can comment on or make changes to this bug.