I refered below link to understand how the subagents work.
But I could not get it working on confd-6.2.1. I have kept both dhcpd.fxs and hst.fxs in etc/confd/ folder and ran master confd.conf first.
I used two diffrent confd.conf files for the master and subagent. But when I tried to run master - which had the subagent section in confd.conf file, I got the error:
"Bad configuration: ../etc/confd/confd.conf:0: /confdConfig/datastores/candidate/implementation must not be 'confd' when subagents are used\n"
So I changed the candidate to "external", but then I got the error:
17-May-2018::12:41:12.305 ucc1 confd: - Bad configuration: ../etc/confd/confd.conf:0: bad mount node: hosts in http://tail-f.com/ns/example/hst
"Bad configuration: ../etc/confd/confd.conf:0: bad mount node: hosts in http://tail-f.com/ns/example/hst\n"