Bug 720065

Summary: Provide native systemd unit file
Product: [Fedora] Fedora Reporter: Jóhann B. Guðmundsson <johannbg>
Component: zabbixAssignee: Dan Horák <dan>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: dan, jeff, nelsonab, nerijus, orion
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-04-03 14:57:55 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On:    
Bug Blocks: 713562    
Attachments:
Description Flags
Native systemd service file for zabbix agent
none
Native systemd service file for zabbix server mysql
none
Native systemd service file for zabbix server pgsql
none
Native systemd service file for zabbix server sqlite3
none
Native systemd service file for zabbix proxy mysql
none
Native systemd service file for zabbix proxy pgsql
none
Native systemd service file for zabbix proxy sqlite3 none

Description Jóhann B. Guðmundsson 2011-07-08 19:14:51 EDT
Description of problem:

https://fedoraproject.org/wiki/Features/SysVtoSystemd

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


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:
Comment 1 Jóhann B. Guðmundsson 2011-07-08 19:17:24 EDT
Created attachment 512004 [details]
Native systemd service file for zabbix agent
Comment 2 Jóhann B. Guðmundsson 2011-07-08 19:18:07 EDT
Created attachment 512005 [details]
Native systemd service file for zabbix server mysql
Comment 3 Jóhann B. Guðmundsson 2011-07-08 19:18:52 EDT
Created attachment 512006 [details]
Native systemd service file for zabbix server pgsql
Comment 4 Jóhann B. Guðmundsson 2011-07-08 19:19:48 EDT
Created attachment 512007 [details]
Native systemd service file for zabbix server sqlite3
Comment 5 Jóhann B. Guðmundsson 2011-07-08 19:20:49 EDT
Created attachment 512009 [details]
Native systemd service file for zabbix proxy mysql
Comment 6 Jóhann B. Guðmundsson 2011-07-08 19:21:47 EDT
Created attachment 512010 [details]
Native systemd service file for zabbix proxy pgsql
Comment 7 Jóhann B. Guðmundsson 2011-07-08 19:23:17 EDT
Created attachment 512011 [details]
Native systemd service file for zabbix proxy sqlite3
Comment 8 Jóhann B. Guðmundsson 2011-07-08 19:38:30 EDT
I would like to recommend that the proxy and server conf be split into spesific settings conf file to their relevant type for example .

zabbix server sqlite3 would be started with...

ExecStart=/usr/sbin/zabbix_server_sqlite3 -c /etc/zabbix/zabbix_server_sqlite3.conf 

and the configuration file tailored in the above example to sqlite3 server only

Same goes for the proxy agents

To keep the backwards compatability ( service zabbix-server start ) with the proxy and server agent you will need to create a symbolic link at their install time like so..

Continuing with sqlite3 example

For zabbit server sqlite3 it would be

ln -s /lib/systemd/system/zabbix-server-sqlite3.service /lib/systemd/system/zabbix-server.service 

For zabbit proxy sqlite3 it would be

ln -s /lib/systemd/system/zabbix-proxy-sqlite3.service /lib/systemd/system/zabbix-proxy.service

https://fedoraproject.org/wiki/Packaging:Guidelines:Systemd
https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd
https://fedoraproject.org/wiki/Packaging:Tmpfiles.d
Comment 9 Orion Poplawski 2011-11-21 14:17:05 EST
We really need to get this stuff in place ASAP.  Currently on F16 this causes zabbix-server to fail to start because it gets started before the database.
Comment 10 Jóhann B. Guðmundsson 2011-11-21 14:56:03 EST
Note that in F16 the window to provide native systemd unit files has passed thus requiring an exception from fesco should it be introduced to the distribution via update anyway regarding your problem just add the relevant dbfoo.service to the After= line in the relevant unit file and that unit will be started after the relevant db has started...
Comment 11 Orion Poplawski 2011-11-21 15:11:42 EST
As a workaround, I copied /lib/systemd/system/mysqld.service to /etc/systemd/system/ and added:

Before=zabbix-server.service