Bug 1121316 - User defined services aren't being read
Summary: User defined services aren't being read
Alias: None
Product: Fedora
Classification: Fedora
Component: firewalld
Version: 20
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Thomas Woerner
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2014-07-19 04:22 UTC by Dan Mossor [danofsatx]
Modified: 2015-06-17 17:06 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2015-06-17 17:06:35 UTC

Attachments (Terms of Use)
rsync service file for firewalld (237 bytes, text/plain)
2014-07-25 14:01 UTC, Dan Mossor [danofsatx]
no flags Details

Description Dan Mossor [danofsatx] 2014-07-19 04:22:45 UTC
Description of problem:
User defined service.xml files in /etc/firewalld/services are not being read. 

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

How reproducible:

Steps to Reproduce:
1. Create a custom service file in /etc/firewalld/services/custom.xml
2. systemctl restart firewalld
3. firewall-cmd --get-services

Actual results:
<custom> service is not listed in the available services, making it impossible to add it to a zone.

Expected results:
<custom> service is listed as an available service and is able to be added to any zone.

Additional info:
When the custom.xml file is moved to /usr/lib/firewalld/services (and selinux context updated) the service is finally read by firewall-cmd and is available for adding to a zone.

Comment 1 Jiri Popelka 2014-07-22 12:34:05 UTC
It works for me with firewalld-0.3.10-1.fc20

Can you attach the custom.xml file ?

Comment 2 Dan Mossor [danofsatx] 2014-07-25 13:58:16 UTC
I'm sorry, I thought I had done this already, but noticed the tab was still open waiting for the upload.

This is a simple service file to add rsync to the firewall.

Comment 3 Dan Mossor [danofsatx] 2014-07-25 14:01:02 UTC
Created attachment 920994 [details]
rsync service file for firewalld

Comment 4 Jiri Popelka 2014-07-25 14:37:40 UTC
Thanks. I don't see any problems even with your service file.
- update to firewalld-0.3.10-1.fc20,
- put 'FIREWALLD_ARGS=--debug' into /etc/sysconfig/firewalld
- systemctl restart firewalld
- firewall-cmd --get-services
- attach /var/log/firewalld

Comment 5 Jiri Popelka 2014-11-03 11:18:45 UTC
I added the rsyncd service upstream

It'll be part of next release, i.e. 0.3.13.

Comment 6 Fedora End Of Life 2015-05-29 12:24:45 UTC
This message is a reminder that Fedora 20 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 20. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '20'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 20 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 7 Thomas Woerner 2015-06-17 16:38:25 UTC
I am not able to verify this. The use of the custom service is working for me using the file name rsyncd.xml and also after renaming to custom.xml as custom.

Comment 8 Dan Mossor [danofsatx] 2015-06-17 17:06:35 UTC
This issue was cleared up somewhere along the way. I tested this with a Fedora 20 KDE Live image that has firewalld-0.3.10-1.fc20.noarch and on a CentOS 7.1 system with firewalld-0.3.9-11.el7.noarch and could not replicate the error.

Steps followed:
# firewall-cmd --get-services
# cat <<EOF >> rsyncd.xml
 <?xml version="1.0" encoding="utf-8"?>
   <description>rsynce is an efficient file synchronization utility.</description>
   <port protocol="tcp" port="873"/>
   <port protocol="udp" port="873"/>
# firewall-cmd --reload
# firewall-cmd --get-services

After the reload, rsyncd is displayed as an available service.

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