* Changed typo configure --with-yang-standard-installdir to `configure --with-yang-standard-dir
* Updated command-line usage of cli,netconf,backend apps in sync with clixon-docs user manual * Documented differences between protocol stubs for external vs internal netconf
This commit is contained in:
parent
b67fae4d61
commit
478911d0f5
11 changed files with 40 additions and 29 deletions
|
|
@ -35,6 +35,12 @@
|
|||
## 5.5.0
|
||||
Planned: January, 2022
|
||||
|
||||
### Corrected Bugs
|
||||
|
||||
### Minor features
|
||||
|
||||
* Changed typo `configure --with-yang-standard-installdir` to `configure --with-yang-standard-dir`
|
||||
|
||||
## 5.4.0
|
||||
30 November, 2021
|
||||
|
||||
|
|
|
|||
|
|
@ -446,12 +446,12 @@ usage(clicon_handle h,
|
|||
"where options are\n"
|
||||
"\t-h\t\tHelp\n"
|
||||
"\t-D <level>\tDebug level\n"
|
||||
"\t-f <file>\tCLICON config file\n"
|
||||
"\t-f <file>\tClixon config file\n"
|
||||
"\t-E <dir> \tExtra configuration file directory\n"
|
||||
"\t-l (s|e|o|f<file>) Log on (s)yslog, std(e)rr or std(o)ut (stderr is default) Only valid if -F, if background syslog is on syslog.\n"
|
||||
"\t-l (s|e|o|f<file>) Log on (s)yslog, std(e)rr, std(o)ut or (f)ile. Syslog is default. If foreground, then syslog and stderr is default. Filename is given after -f as follows: -lf<file>\n"
|
||||
"\t-d <dir>\tSpecify backend plugin directory (default: %s)\n"
|
||||
"\t-p <dir>\tYang directory path (see CLICON_YANG_DIR)\n"
|
||||
"\t-b <dir>\tSpecify XMLDB database directory\n"
|
||||
"\t-p <dir>\tAdd Yang directory path (see CLICON_YANG_DIR)\n"
|
||||
"\t-b <dir>\tSpecify datastore directory\n"
|
||||
"\t-F\t\tRun in foreground, do not run as daemon\n"
|
||||
"\t-z\t\tKill other config daemon and exit\n"
|
||||
"\t-a UNIX|IPv4|IPv6 Internal backend socket family\n"
|
||||
|
|
@ -459,7 +459,7 @@ usage(clicon_handle h,
|
|||
"\t-P <file>\tPid filename (default: %s)\n"
|
||||
"\t-1\t\tRun once and then quit (dont wait for events)\n"
|
||||
"\t-s <mode>\tSpecify backend startup mode: none|startup|running|init)\n"
|
||||
"\t-c <file>\tLoad extra xml configuration, but don't commit.\n"
|
||||
"\t-c <file>\tLoad extra XML configuration file, but do not commit.\n"
|
||||
"\t-q \t\tQuit startup directly after upgrading and print result on stdout\n"
|
||||
"\t-U <user>\tRun backend daemon as this user AND drop privileges permanently\n"
|
||||
"\t-g <group>\tClient membership required to this group (default: %s)\n"
|
||||
|
|
@ -604,7 +604,7 @@ main(int argc,
|
|||
if (clicon_option_add(h, "CLICON_XMLDB_DIR", optarg) < 0)
|
||||
goto done;
|
||||
break;
|
||||
case 'p' : /* yang dir path */
|
||||
case 'p' : /* Add yang dir path */
|
||||
if (clicon_option_add(h, "CLICON_YANG_DIR", optarg) < 0)
|
||||
goto done;
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -329,7 +329,7 @@ usage(clicon_handle h,
|
|||
"\t-m <mode>\tSpecify plugin syntax mode\n"
|
||||
"\t-q \t\tQuiet mode, dont print greetings or prompt, terminate on ctrl-C\n"
|
||||
"\t-p <dir>\tYang directory path (see CLICON_YANG_DIR)\n"
|
||||
"\t-G \t\tPrint CLI syntax generated from dbspec (if CLICON_CLI_GENMODEL enabled)\n"
|
||||
"\t-G \t\tPrint auo-cli CLI syntax generated from YANG (if CLICON_CLI_GENMODEL enabled)\n"
|
||||
"\t-L \t\tDebug print dynamic CLI syntax including completions and expansions\n"
|
||||
"\t-l <s|e|o|f<file>> \tLog on (s)yslog, std(e)rr, std(o)ut or (f)ile (stderr is default)\n"
|
||||
"\t-y <file>\tOverride yang spec file (dont include .yang suffix)\n"
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@
|
|||
#include "netconf_rpc.h"
|
||||
|
||||
/* Command line options to be passed to getopt(3) */
|
||||
#define NETCONF_OPTS "hD:f:E:l:qa:u:d:p:y:U:t:eHo:"
|
||||
#define NETCONF_OPTS "hD:f:E:l:qHa:u:d:p:y:U:t:eo:"
|
||||
|
||||
#define NETCONF_LOGFILE "/tmp/clixon_netconf.log"
|
||||
|
||||
|
|
@ -625,16 +625,16 @@ usage(clicon_handle h,
|
|||
"\t-f <file>\tConfiguration file (mandatory)\n"
|
||||
"\t-E <dir> \tExtra configuration file directory\n"
|
||||
"\t-l (e|o|s|f<file>) Log on std(e)rr, std(o)ut, (s)yslog(default), (f)ile\n"
|
||||
"\t-q\t\tQuiet: dont send hello prompt\n"
|
||||
"\t-q\t\tQuiet mode, do not send hello message\n"
|
||||
"\t-H \t\tDo not expect hello message from server.\n"
|
||||
"\t-a UNIX|IPv4|IPv6 Internal backend socket family\n"
|
||||
"\t-u <path|addr>\tInternal socket domain path or IP addr (see -a)\n"
|
||||
"\t-d <dir>\tSpecify netconf plugin directory dir (default: %s)\n"
|
||||
"\t-p <dir>\tYang directory path (see CLICON_YANG_DIR)\n"
|
||||
"\t-p <dir>\tAdd Yang directory path (see CLICON_YANG_DIR)\n"
|
||||
"\t-y <file>\tLoad yang spec file (override yang main module)\n"
|
||||
"\t-U <user>\tOver-ride unix user with a pseudo user for NACM.\n"
|
||||
"\t-t <sec>\tTimeout in seconds. Quit after this time.\n"
|
||||
"\t-e \t\tDont ignore errors on packet input.\n"
|
||||
"\t-H \t\tHello messages are optional.\n"
|
||||
"\t-o \"<option>=<value>\"\tGive configuration option overriding config file (see clixon-config.yang)\n",
|
||||
argv0,
|
||||
clicon_netconf_dir(h)
|
||||
|
|
|
|||
8
configure
vendored
8
configure
vendored
|
|
@ -727,7 +727,7 @@ with_configfile
|
|||
with_libxml2
|
||||
with_sigaction
|
||||
with_yang_installdir
|
||||
with_yang_standard_installdir
|
||||
with_yang_standard_dir
|
||||
'
|
||||
ac_precious_vars='build_alias
|
||||
host_alias
|
||||
|
|
@ -5658,9 +5658,9 @@ $as_echo "Clixon yang files are installed in ${YANG_INSTALLDIR}" >&6; }
|
|||
# This is NOT installed by Clixon and is not needed for core system
|
||||
# However, it is required by the main example and some of the tests
|
||||
|
||||
# Check whether --with-yang-standard-installdir was given.
|
||||
if test "${with_yang_standard_installdir+set}" = set; then :
|
||||
withval=$with_yang_standard_installdir; YANG_STANDARD_DIR="$withval"
|
||||
# Check whether --with-yang-standard-dir was given.
|
||||
if test "${with_yang_standard_dir+set}" = set; then :
|
||||
withval=$with_yang_standard_dir; YANG_STANDARD_DIR="$withval"
|
||||
else
|
||||
YANG_STANDARD_DIR="${prefix}/share/yang/standard"
|
||||
|
||||
|
|
|
|||
|
|
@ -339,7 +339,7 @@ AC_MSG_RESULT(Clixon yang files are installed in ${YANG_INSTALLDIR})
|
|||
# YANG_STANDARD_DIR is where clixon assumes standard IETF are
|
||||
# This is NOT installed by Clixon and is not needed for core system
|
||||
# However, it is required by the main example and some of the tests
|
||||
AC_ARG_WITH(yang-standard-installdir,
|
||||
AC_ARG_WITH(yang-standard-dir,
|
||||
[AS_HELP_STRING([--with-yang-standard-dir=DIR],[Directory of standard IETF/IEEE YANG specs (default: $prefix/share/yang/standard)])],
|
||||
[YANG_STANDARD_DIR="$withval"],
|
||||
[YANG_STANDARD_DIR="${prefix}/share/yang/standard"]
|
||||
|
|
|
|||
|
|
@ -1209,7 +1209,7 @@ static clixon_plugin_api api = {
|
|||
clixon_plugin_init, /* init - must be called clixon_plugin_init */
|
||||
example_start, /* start */
|
||||
example_exit, /* exit */
|
||||
.ca_extension=example_extension, /* yang extensions */
|
||||
example_extension, /* yang extensions */
|
||||
.ca_daemon=example_daemon, /* daemon */
|
||||
.ca_reset=example_reset, /* reset */
|
||||
.ca_statedata=example_statedata, /* statedata : Note fn is switched if -sS <file> */
|
||||
|
|
|
|||
|
|
@ -323,8 +323,10 @@ msg_dump(struct clicon_msg *msg)
|
|||
}
|
||||
|
||||
/*! Send a CLICON netconf message using internal IPC message
|
||||
*
|
||||
* @param[in] s socket (unix or inet) to communicate with backend
|
||||
* @param[out] msg CLICON msg data reply structure. Free with free()
|
||||
* @see clicon_msg_send1 using plain NETCONF
|
||||
*/
|
||||
int
|
||||
clicon_msg_send(int s,
|
||||
|
|
@ -364,6 +366,7 @@ clicon_msg_send(int s,
|
|||
* @param[out] msg CLICON msg data reply structure. Free with free()
|
||||
* @param[out] eof Set if eof encountered
|
||||
* Note: caller must ensure that s is closed if eof is set after call.
|
||||
* @see clicon_msg_rcv1 using plain NETCONF
|
||||
*/
|
||||
int
|
||||
clicon_msg_rcv(int s,
|
||||
|
|
@ -419,11 +422,13 @@ clicon_msg_rcv(int s,
|
|||
return retval;
|
||||
}
|
||||
|
||||
/*! Receive a message using plain ascii
|
||||
/*! Receive a message using plain NETCONF
|
||||
*
|
||||
* @param[in] s socket (unix or inet) to communicate with backend
|
||||
* @param[out] cb1 cligen buf struct containing the incoming message
|
||||
* @param[out] eof Set if eof encountered
|
||||
* @see netconf_input_cb()
|
||||
* @see clicon_msg_rcv using IPC message struct
|
||||
*/
|
||||
int
|
||||
clicon_msg_rcv1(int s,
|
||||
|
|
@ -480,9 +485,11 @@ clicon_msg_rcv1(int s,
|
|||
return retval;
|
||||
}
|
||||
|
||||
/*! Send a CLICON netconf message plain text
|
||||
/*! Send a CLICON netconf message plain NETCONF
|
||||
*
|
||||
* @param[in] s socket (unix or inet) to communicate with backend
|
||||
* @param[out] msg CLICON msg data reply structure. Free with free()
|
||||
* @see clicon_msg_send using internal IPC header
|
||||
*/
|
||||
int
|
||||
clicon_msg_send1(int s,
|
||||
|
|
@ -604,6 +611,7 @@ clicon_rpc_connect_inet(clicon_handle h,
|
|||
* @param[out] xret Returned data as netconf xml tree.
|
||||
* @retval 0 OK
|
||||
* @retval -1 Error
|
||||
* @see clicon_rpc1 using plain NETCONF XML
|
||||
*/
|
||||
int
|
||||
clicon_rpc(int sock,
|
||||
|
|
@ -638,19 +646,16 @@ clicon_rpc(int sock,
|
|||
return retval;
|
||||
}
|
||||
|
||||
/*! Send a netconf message and recieve result.
|
||||
/*! Send a netconf message and recieve result using plain NETCONF
|
||||
*
|
||||
* TBD: timeout, interrupt?
|
||||
* retval may be -1 and
|
||||
* errno set to ENOTCONN which means that socket is now closed probably
|
||||
* due to remote peer disconnecting. The caller may have to do something,...
|
||||
* This is mainly used by the client API.
|
||||
*
|
||||
* @param[in] sock Socket / file descriptor
|
||||
* @param[in] msgin CLICON msg data structure. It has fixed header and variable body.
|
||||
* @param[out] msgret Returned data as netconf xml tree.
|
||||
* @retval 0 OK
|
||||
* @retval -1 Error
|
||||
* see clicon_rpc using clicon_msg
|
||||
* @see clicon_rpc using clicon_msg protocol header
|
||||
*/
|
||||
int
|
||||
clicon_rpc1(int sock,
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ bindir = @bindir@
|
|||
includedir = @includedir@
|
||||
datarootdir = @datarootdir@
|
||||
|
||||
# Also mandatory standard YANGs (see ../mandatory)
|
||||
YANG_INSTALLDIR = @YANG_INSTALLDIR@
|
||||
|
||||
YANGSPECS = clixon-config@2021-07-11.yang # 5.3
|
||||
|
|
|
|||
|
|
@ -707,8 +707,7 @@ module clixon-config {
|
|||
type int8;
|
||||
default 0;
|
||||
description
|
||||
"Set CLI tab mode. This is actually a bitfield of three
|
||||
combinations:
|
||||
"Set CLI tab mode. This is a bitfield of three bits:
|
||||
bit 1: 0: <tab> shows short info of available commands
|
||||
1: <tab> has same output as <?>, ie line per command
|
||||
bit 2: 0: On <tab>, select a command over a <var> if both exist
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ bindir = @bindir@
|
|||
includedir = @includedir@
|
||||
datarootdir = @datarootdir@
|
||||
|
||||
# See also YANG_INSTALLDIR for the clixon-specific yang files
|
||||
# Also clixon YANGs (see ../clixon)
|
||||
YANG_INSTALLDIR = @YANG_INSTALLDIR@
|
||||
|
||||
YANGSPECS += ietf-inet-types@2021-02-22.yang
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue