QUERY [ java | forward | demux | date | pid | conf | thread ]
Returns, to the client originating the command, a reply depending on the query.
<key_name> <value(s)> # [<flags>]where
<key_name>
is a matching configuration key,
<value(s)>
is the current comma-separated list of
values assigned to the key,
and <flags>
is a collection of characters indicating
whether certain internal handling flags are set for the key.
The flags determine how future
attempts to set values for the key will be handled:
P
: the configuration key is permanent, i.e., its value
is maintained upon reconfiguration
R
: the configuration key is read only, i.e., its value
set internally and cannot be changed by configuration files
A
: additional values will be appended to the
current list.
-
) indicates that the corresponding flag is not set.
Note that flags are set and interpreted internally and cannot be
changed by configuration files. They are included in the output
primarily as an Anetd debugging aid.
Note that the output is in Anetd configuration file format.
1 $ sc d04 QUERY 2 text/ancors: anpub@d04.csl.sri.com:3322 RELEASE_1_6_6 bsd44 3 anetd_uptime 1:02:04:52 4 _________________________________________ 5 130.107.19.127: "foo" ("anetd_ee.udp.963428600.bsd44", pid 5255, ... permanent, anep_id 80, uptime 1:02:04:24, ... working_dir "/home/anpub/anetd/var/7f136b82", autokill on) 6 _________________________________________ 7 130.107.19.127: "<no description>" ("test-load-x.963522454.bsd44", pid 20390, ... not permanent, anep_id 0, uptime 0:00:00:10, ... working_dir "/home/anpub/anetd/var/7f136b82", autokill on)
Line 1 is the sc invocation.
Line 2 tells that Anetd is running on host d04.csl.sri.com at port 3322 as user anpub, that the operating system is bsd44 (really FreeBSD) and that the release is RELEASE_1_6.
Line 3 tells that Anetd uptime is 1 day, 2 hours, 4 minutes.
Line 5 tells that a client with IP address 130.107.19.127started the service foo whose program name is
anetd_ee.udp, whose PID is 5255, is permanent, has requested
demultiplexing through ANEP ID 80,
has an uptime of 1 day and 2 hours, was started in the working
directory (on the node) /home/anpub/anetd/var/7f136b82,
and has the autokill flag set. Note that the description, program name,
and directory are displayed as double-quoted strings. If these strings
have embedded double-quotes, control characters, nonprintable characters,
or other characters, such as ``\
'', that would normally need to
be escaped, these characters will be displayed in C-style escaped form
(e.g., ``"
'' ``
\"
'',
``\
'' ``
\\
'',
newline ``
\n
'', etc.).
Line 7 describes another service, with some differences: it has no description, its program name is test-load-x, is not permanent, and hasn't asked for demultiplexing (its ANEP ID is 0).
1 sc.bsd44 sofia QUERY java 2 text/ancors: molter@sofia.csl.sri.com:3322 HEAD_SNAP_2000_05_16 bsd44 3 jdk1.1.8 4 jdk1.2
Lines 1,2 are as in example 3.4.
Lines 3,4 tell the available JVM versions.
1 $ sc d04 QUERY forward 2 text/ancors: anpub@d04.csl.sri.com:3322 RELEASE_1_6 bsd44 3 host user anep_id last_heard created 4 127.0.0.1:8000 abocc 0 0:00:00:19 N/A 5 127.0.0.1:8001 anee1 1 0:00:00:17 N/A 6 127.0.0.1:8002 anee2 2 0:00:00:15 N/A 7 127.0.0.1:8003 anee3 3 0:00:00:13 N/A 8 127.0.0.1:8004 anee4 4 0:00:00:11 N/A 9 127.0.0.1:8005 anee5 5 0:00:00:09 N/A
Lines 1,2 are as in example 3.4.
Line 3 is a header.
Lines 4..9 are the secondary Anetds.
1 $ sc d04 QUERY demux 2 text/ancors: anpub@d04.csl.sri.com:3322 RELEASE_1_6_6 bsd44 3 host user anep_id demux_count last_demux registered 4 127.0.0.1:3721 anee1 80 4143 0:00:00:23 2000-07-12_12:03:20_GMT-07
Lines 1, 2, and 3 are as in example 3.6.
Line 4 is the EE of line 5 of example 3.4.
The other EE of example 3.4 isn't listed here
since it did not request demultiplexing. The field demux_count
indicates the number of ANEP packets of the listed anep_id
received by Anetd since the EE was registered.
The field last_demux
shows the time elapsed since the last such
packet was received. If no such packets have been received,
``N/A
'' is displayed. The field registered
shows the time
at which the EE was registered.
1 $ sc d04 QUERY conf anetd_dir 2 text/ancors: anpub@d04.csl.sri.com:3322 RELEASE_1_6_6 bsd44 3 anetd_dir "/home/anpub/anetd" # [---]
Lines 1 and 2 are as in example 3.6.
Line 3 shows the setting for the requested configuration key,
anetd_dir
. It has no flags set, and its current value is
shown to be /home/anpub/anetd.
1 $ sc -f ahost d04 QUERY thread 2 text/ancors: anee1@ahost:3322->8001 RELEASE_1_6_7 bsd44 3 ---------- 4 Test_EE 5 Owner: auser@adomain 6 Source IP: 192.168.100.101 7 Anetd command: LOAD X=http://abone-tcs.sdl.sri.com/test/testee S=testfile T=55 F=http://abone-tcs.sdl.sri.com/test/testfile 8 Type: native 9 ANEP ID: 55 10 Program: /home/anee1/anetd/var/6564a8c0/testee.985720883.bsd44 11 Base URL: http://abone-tcs.sdl.sri.com/test/testee.bsd44 12 Equivalent URLs: http://abone-tcs.sdl.sri.com:80/test/testee.bsd44, http://205.178.57.134:80/test/testee.bsd44 13 Java class: <NULL> 14 Directory: /home/anee1/anetd/var/6564a8c0 15 Additional URL 1: http://abone-tcs.sdl.sri.com/test/testfile 16 Equivalent URLs 1: http://abone-tcs.sdl.sri.com:80/test/testfile, http://205.178.57.134:80/test/testfile 17 Local file 1: /home/anee1/anetd/var/6564a8c0/testfile 18 Stdin: <NULL> 19 Stdout: <NULL> 20 Stderr: <NULL> 21 Flags: Autokill 22 OS command: /home/anee1/anetd/var/6564a8c0/testee.985717281.bsd44 testfile 23 Env 0: AD_DIR=/home/anee1/anetd 24 Env 1: AD=ad.bsd44 25 Env 2: AD_PID=7932 26 Env 3: AD_COMMAND=/home/abocc/anetd/ad.bsd44 27 Env 4: AD_START_DIR=/home/abocc 28 Env 5: AD_CWD=/home/abocc 29 Env 6: AD_USER=anee1 30 Env 7: AD_ABONE_ROLE=anee1 31 Env 8: AD_ABOCC_USER=abocc 32 Env 9: DISPLAY=192.168.100.101:0.0 33 Env 10: CLASSPATH=/home/abocc/anetd/bin:/home/anee1/anetd/var/6564a8c0 34 Env 11: LD_LIBRARY_PATH=/home/abocc/anetd/bin:/home/anee1/anetd/var/6564a8c0 35 PID: 8021 36 Start: 2001-03-27_10:21:21_GMT-08 37 Uptime: 0:00:03:21 38 Port: 8017