Commit cb617131 authored by Jeremy C. Reed's avatar Jeremy C. Reed
Browse files

Have msgq and its manpage be installed as "b10-msgq".

For ticket #25.


git-svn-id: svn://bind10.isc.org/svn/bind10/trunk@1747 e5f2f494-b856-4b98-b285-d166d9295462
parent 5448dea9
......@@ -104,9 +104,8 @@
<para>
At first, running many different processes may seem confusing. However,
these processes are started, stopped, and maintained by a single command,
<command>bind10</command>. Additionally, most processes started by
the <command>bind10</command> command have names starting with "b10-",
with one exception, <command>msgq</command>.
<command>bind10</command>. Additionally, the processes started by
the <command>bind10</command> command have names starting with "b10-".
</para>
<para>
......@@ -122,7 +121,7 @@
<itemizedlist>
<listitem>
<simpara>
<command>msgq</command> &mdash;
<command>b10-msgq</command> &mdash;
message bus daemon.
This process coordinates communication between all of the other
BIND 10 processes.
......@@ -636,15 +635,15 @@ implementation in BIND 10.
</para>
<para>
After starting the <command>msgq</command> communications channel,
After starting the <command>b10-msgq</command> communications channel,
<command>bind10</command> connects to it,
runs the configuration manager, and reads its own configuration.
Then it starts the other modules.
</para>
<para>
The <command>msgq</command> and <command>b10-cfgmgr</command>
services make up the core. The <command>msgq</command> daemon
The <command>b10-msgq</command> and <command>b10-cfgmgr</command>
services make up the core. The <command>b10-msgq</command> daemon
provides the communication channel between every part of the system.
The <command>b10-cfgmgr</command> daemon is always needed by every
module, if only to send information about themselves somewhere,
......@@ -672,9 +671,9 @@ implementation in BIND 10.
<title>Command channel</title>
<para>
The BIND 10 components use the <command>msgq</command>
The BIND 10 components use the <command>b10-msgq</command>
message routing daemon to communicate with other BIND 10 components.
The <command>msgq</command> implements what is called the
The <command>b10-msgq</command> implements what is called the
<quote>Command Channel</quote>.
Processes intercommunicate by sending messages on the command
channel.
......@@ -686,14 +685,14 @@ implementation in BIND 10.
<para>
Administrators do not communicate directly with the
<command>msgq</command> daemon.
<command>b10-msgq</command> daemon.
By default, BIND 10 uses port 9912 for the
<command>msgq</command> service.
<command>b10-msgq</command> service.
It listens on 127.0.0.1.
</para>
<para>
To select an alternate port for the <command>msgq</command> to
To select an alternate port for the <command>b10-msgq</command> to
use, run <command>bind10</command> specifying the option:
<screen> $ <userinput>bind10 --msgq-port 9912</userinput></screen>
</para>
......@@ -717,7 +716,7 @@ Unix domain sockets
<para>
The <command>b10-auth</command> and <command>b10-xfrin</command>
daemons and other components receive their configurations
from the configuration manager over the <command>msgq</command>
from the configuration manager over the <command>b10-msgq</command>
command channel.
</para>
......@@ -826,7 +825,7 @@ options for that module
When <command>b10-cmdctl</command> starts, it firsts
asks <command>b10-cfgmgr</command> about what modules are
running and what their configuration is (over the
<command>msgq</command> channel). Then it will start listening
<command>b10-msgq</command> channel). Then it will start listening
on HTTPS for clients &mdash; the user interface &mdash; such
as <command>bindctl</command>.
</para>
......@@ -979,9 +978,9 @@ TODO
<command>b10-cfgmgr</command>. So when <command>bindctl</command>
sends a configuration, it is sent to <command>b10-cmdctl</command>
(over a HTTPS connection); then <command>b10-cmdctl</command>
sends the command (over a <command>msgq</command> command
sends the command (over a <command>b10-msgq</command> command
channel) to <command>b10-cfgmgr</command> which then stores
the details and relays (over a <command>msgq</command> command
the details and relays (over a <command>b10-msgq</command> command
channel) the configuration on to the specified module.
</para>
......
......@@ -63,7 +63,7 @@
<para>
This daemon communicates with other BIND 10 components over a
<citerefentry><refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
<citerefentry><refentrytitle>b10-msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
C-Channel connection. If this connection is not established,
<command>b10-auth</command> will exit.
<!-- TODO what if msgq connection closes later, will b10-auth exit? -->
......@@ -71,10 +71,7 @@
<para>
It also receives its configurations from
<citerefentry><refentrytitle>b10-cfgmgr</refentrytitle><manvolnum>8</manvolnum></citerefentry>
(via the
<citerefentry><refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
command channel).
<citerefentry><refentrytitle>b10-cfgmgr</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
It will honor the <emphasis>database_file</emphasis> configuration
to point to the SQLite3 zone file.
......@@ -158,10 +155,10 @@
<refentrytitle>b10-loadzone</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>bind10</refentrytitle><manvolnum>8</manvolnum>
<refentrytitle>b10-msgq</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum>
<refentrytitle>bind10</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citetitle>BIND 10 Guide</citetitle>.
</para>
......
......@@ -207,26 +207,26 @@ class BoB:
# to see if it is already running
c_channel_env = { "ISC_MSGQ_PORT": str(self.c_channel_port), }
if self.verbose:
sys.stdout.write("Checking for already running msgq\n")
sys.stdout.write("Checking for already running b10-msgq\n")
# try to connect, and if we can't wait a short while
try:
self.cc_session = isc.cc.Session(self.c_channel_port)
return "msgq already running, cannot start"
return "b10-msgq already running, cannot start"
except isc.cc.session.SessionError:
pass
# start the c-channel daemon
if self.verbose:
sys.stdout.write("Starting msgq using port %d\n" %
sys.stdout.write("Starting b10-msgq using port %d\n" %
self.c_channel_port)
try:
c_channel = ProcessInfo("msgq", ["msgq"], c_channel_env, True,
not self.verbose)
c_channel = ProcessInfo("b10-msgq", ["b10-msgq"], c_channel_env,
True, not self.verbose)
except Exception as e:
return "Unable to start msgq; " + str(e)
return "Unable to start b10-msgq; " + str(e)
self.processes[c_channel.pid] = c_channel
if self.verbose:
sys.stdout.write("Started msgq (PID %d)\n" % c_channel.pid)
sys.stdout.write("Started b10-msgq (PID %d)\n" % c_channel.pid)
# now connect to the c-channel
cc_connect_start = time.time()
......@@ -415,10 +415,10 @@ class BoB:
if self.verbose:
sys.stdout.write("Process %s (PID %d) died.\n" %
(proc_info.name, proc_info.pid))
if proc_info.name == "msgq":
if proc_info.name == "b10-msgq":
if self.verbose and self.runnable:
sys.stdout.write(
"The msgq process died, shutting down.\n")
"The b10-msgq process died, shutting down.\n")
self.runnable = False
else:
sys.stdout.write("Unknown child pid %d exited.\n" % pid)
......@@ -567,7 +567,7 @@ def main():
help="port the b10-auth daemon will use (default 5300)")
parser.add_option("-m", "--msgq-port", dest="msgq_port", type="string",
action="callback", callback=check_port, default="9912",
help="port the msgq daemon will use (default 9912)")
help="port the b10-msgq daemon will use (default 9912)")
(options, args) = parser.parse_args()
# Announce startup.
......
......@@ -21,7 +21,7 @@
<refentry>
<refentryinfo>
<date>March 18, 2010</date>
<date>April 19, 2010</date>
</refentryinfo>
<refmeta>
......@@ -84,7 +84,7 @@
<listitem>
<para>The port number for the
<citerefentry><refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
<citerefentry><refentrytitle>b10-msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
daemon to listen on.
The default is 9912.</para>
</listitem>
......@@ -139,10 +139,10 @@
<refentrytitle>b10-cmdctl</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>b10-xfrin</refentrytitle><manvolnum>8</manvolnum>
<refentrytitle>b10-msgq</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum>
<refentrytitle>b10-xfrin</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citetitle>BIND 10 Guide</citetitle>.
</para>
......
......@@ -215,9 +215,6 @@ configuration location.
<citerefentry>
<refentrytitle>bind10</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citetitle>BIND 10 Guide</citetitle>.
</para>
<!-- TODO: point to developer docs -->
......
......@@ -69,7 +69,7 @@
<!-- TODO: briefly explain why both msqg channel and cmdctl communication -->
<para>
This daemon communicates over a <command>msgq</command> C-Channel
This daemon communicates over a <command>b10-msgq</command> C-Channel
connection. If this connection is not established,
<command>b10-cfgmgr</command> will exit.
</para>
......
pkglibexecdir = $(libexecdir)/@PACKAGE@
pkglibexec_SCRIPTS = msgq
pkglibexec_SCRIPTS = b10-msgq
CLEANFILES = msgq
man_MANS = msgq.8
man_MANS = b10-msgq.8
EXTRA_DIST = $(man_MANS) msgq.xml msgq_test.py
if ENABLE_MAN
msgq.8: msgq.xml
b10-msgq.8: msgq.xml
xsltproc --novalid --xinclude --nonet -o $@ http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $(srcdir)/msgq.xml
endif
# TODO: does this need $$(DESTDIR) also?
# this is done here since configure.ac AC_OUTPUT doesn't expand exec_prefix
msgq: msgq.py
b10-msgq: msgq.py
$(SED) "s|@@PYTHONPATH@@|@pyexecdir@|" msgq.py >$@
chmod a+x $@
......@@ -21,17 +21,17 @@
<refentry>
<refentryinfo>
<date>January 21, 2010</date>
<date>April 19, 2010</date>
</refentryinfo>
<refmeta>
<refentrytitle>msgq</refentrytitle>
<refentrytitle>b10-msgq</refentrytitle>
<manvolnum>8</manvolnum>
<refmiscinfo>BIND10</refmiscinfo>
</refmeta>
<refnamediv>
<refname>msgq</refname>
<refname>b10-msgq</refname>
<refpurpose>message routing daemon for the Command Channel</refpurpose>
</refnamediv>
......@@ -44,7 +44,7 @@
<refsynopsisdiv>
<cmdsynopsis>
<command>msgq</command>
<command>b10-msgq</command>
<arg><option>-m <replaceable>number</replaceable></option></arg>
<arg><option>-v</option></arg>
<arg><option>--msgq-port <replaceable>number</replaceable></option></arg>
......@@ -55,7 +55,7 @@
<refsect1>
<title>DESCRIPTION</title>
<para>
The <command>msgq</command>
The <command>b10-msgq</command>
daemon provides message routing for the Command Channel.
</para>
......@@ -63,7 +63,7 @@
The Command Channel is a message bus and subscription manager.
Programs may subscribe to certain groups to receive messages
for that group.
Every new connection to the <command>msgq</command> is
Every new connection to <command>b10-msgq</command> is
assigned a unique identifier -- this is the local name.
The commands it handles are:
<itemizedlist>
......@@ -97,7 +97,7 @@
</para>
<para>
The <command>msgq</command> daemon may be cleanly stopped by
The <command>b10-msgq</command> daemon may be cleanly stopped by
sending the SIGTERM signal to the process.
This shutdown does not notify the subscribers.
</para>
......@@ -114,7 +114,7 @@
<term><option>-m <replaceable>number</replaceable></option>,
<option>--msgq-port <replaceable>number</replaceable></option></term>
<listitem><para>
The port number that <command>msgq</command> will listen on.
The port number that <command>b10-msgq</command> will listen on.
The default is 9912.</para>
</listitem>
</varlistentry>
......@@ -123,7 +123,7 @@
<term><option>-v</option>, <option>--verbose</option></term>
<listitem><para>
Enabled verbose mode. This enables diagnostic messages to
STDERR. Displays more about what <command>msgq</command>
STDERR. Displays more about what <command>b10-msgq</command>
is doing.
<!-- TODO: is STDERR correct? -->
</para></listitem>
......@@ -147,7 +147,7 @@
<refsect1>
<title>AUTHORS</title>
<para>
The <command>msgq</command> daemon and Control Channel specification
The <command>b10-msgq</command> daemon and Control Channel specification
were initially designed by Michael Graff of ISC.
</para>
</refsect1>
......
......@@ -9,4 +9,4 @@ PYTHONPATH=@abs_top_srcdir@/src/lib/python
export PYTHONPATH
cd ${MYPATH_PATH}
exec ${PYTHON_EXEC} -O msgq $*
exec ${PYTHON_EXEC} -O b10-msgq $*
......@@ -68,8 +68,9 @@
</simpara></note>
<para>
This daemon communicates with the BIND 10 over a
<citerefentry><refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
<!-- TODO: does it really use msgq? what for? -->
This daemon communicates with BIND 10 over a
<citerefentry><refentrytitle>b10-msgq</refentrytitle><manvolnum>8</manvolnum></citerefentry>
C-Channel connection. If this connection is not established,
<command>b10-xfrin</command> will exit.
<!-- TODO what if connection closes later, will b10-xfrin exit? -->
......@@ -178,10 +179,10 @@ operation
<refentrytitle>b10-cfgmgr</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>bind10</refentrytitle><manvolnum>8</manvolnum>
<refentrytitle>b10-msgq</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>msgq</refentrytitle><manvolnum>8</manvolnum>
<refentrytitle>bind10</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citetitle>BIND 10 Guide</citetitle>.
</para>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment