Some tools or libraries might be included in your installation depending on which options (such as development packages) you chose to install FreeBSD 9. The rest of the tools and libraries either need to be installed from ports or downloaded from the Internet as tar.gz archives, and then copied to the system, extracted, configured, and installed.
IMPORTANT: Because you will end up with more than one version of certain packages installed after the installation completes, you must rename or remove the legacy packages so that JUISE and ANYCONF can locate the correct binaries.
To make sure you have the necessary components installed, follow this process. If you are missing anything, you can run a dependency scan to find the missing components.
Download and install the following either from ports or source:
cd /usr/ports/shells/bash && make install clean
cd /usr/ports/lang/gcc && make install clean
cd /usr/ports/devel/gmake && make install clean
cd /usr/ports/devel/autoconf && make install clean
cd /usr/ports/devel/automake && make install clean
cd /usr/ports/devel/bison && make install clean
cd /usr/ports/textproc/libxml2 && make install clean
cd /usr/ports/textproc/libxslt && make install clean
cd /usr/ports/security/openssl && make install clean
cd /usr/ports/devel/mingw32-openssl && make install clean
cd /usr/ports/ftp/curl && make install clean
FreeBSD ports is version 7.21 and will work but you can download it from http://curl.haxx.se/download.html and compile from source.
cd /usr/ports/devel/readline && make install clean
Readline is shipped as a standard library on most GNU/Linux and FreeBSD systems.
FreeBSDserver# tar –xvf libslax-0.12.2.tar.gz
make install clean
cd /usr/ports/security/libssh2 && make install clean
FreeBSDserver# tar –xvf openssh-6.1p1.tar.gz
The ports version is OpenSSH 5.8 and would work as well.
FreeBSDserver# tar –xvf getopt-1.1.5.tar.gz
You now have FreeBSD ports or base installation packages installed that conflict with newer versions you want to use with this platform.
For example, after installing OpenSSH 6.1p1:
FreeBSDserver# where ssh
/usr/bin/ssh (openssh 5.8)
/usr/local/bin/ssh (openssh 6.1)
Same thing for Getopt 1.1.5:
FreeBSDserver# where getopt
/usr/bin/getopt (ports getopt)
/usr/local/bin/getopt (GNU getopt)
You must rename or remove binaries for both getopt and ssh that reside in “/usr/bin” to avoid conflicts with the newer versions that are installed into /usr/local/bin. You can rename them whatever you like so long as the environment can no longer find it. In the example below, both have had ".base" appended to their names.
rename /usr/bin/getptopt > /usr/bin/getopt.base
rename /usr/bin/ssh > /usr/bin/ssh.base
Your environment should now be ready for ANYCONF and JUISE.
Once the FreeBSD environmnent is prepared, download and install ANYCONF.
FreeBSDserver# anyconf --help
anyconf: Junos Anyconf "V12 Engine"
-t <template-file> (REQ, upto 2)
-d <data-file> (upto 3)
--show: will show the output file to the screen after merge
IMPORTANT: If you do not get the help description for any reason, then stop and resolve the issue before moving on, otherwise JUISE will not work without ANYCONF.
Once the FreeBSD environment is prepared and ANYCONF is working, download and install JUISE.
FreeBSDserver# tar –xvf juise-0.3.17.tar.gz
Verify that JUISE is working.
FreeBSDserver# juise --help
Usage: juise [@target] [options] [script] [param value]*
--agent OR -A: enable ssh-agent forwarding
--commit-script OR -c: test a commit script
--debug OR -d: use the libslax debugger
--directory <dir> OR -D <dir>: set the directory for server scripts
--include <dir> OR -I <dir>: search directory for includes/imports
--input <file> OR -i <file>: use given file for input
--indent OR -g: indent output ala output-method/indent
--junoscript OR -J: use junoscript API protocol
--load OR -l: load commit script changes in test mode
--lib <dir> OR -L <dir>: search directory for extension libraries
--no-randomize: do not initialize the random number generator
--param <name> <value> OR -a <name> <value>: pass parameters
--protocol <name> OR -P <name>: use the given API protocol
--run-server OR -R: run in juise server mode
--script <name> OR -S <name>: run the given script
--target <name> OR -T <name>: specify the default target device
--trace <file> OR -t <file>: write trace data to a file
--user <name> OR -u <name>: specify the user name for API connections
--verbose OR -v: enable debugging output (slaxLog())
--version OR -V: show version information (and exit)
--wait <seconds>: wait after starting (for gdb to attach)
For more information, click the project JUISE home page: https://github.com/Juniper/juise/.