TESTING revision 6305
6305N/A/usr/lib/rsyslog/rsyslogd -d -n 2>&1 | grep ': source file'
6305N/Anm /usr/lib/rsyslog/lmnet.so |grep AllowedSenders_GSS
6305N/Asvcadm disable system/system-log:default
6305N/Asvcadm enable system/system-log:rsyslog
6305N/A# Logging a message should appear in dmesg and /var/adm/messages
6305N/Admesg | tail # should contain '2016-06-10T07:53:00+00:00 S12-99 root: [ID 702911 user.error] Message 1'
6305N/A======================== Create /etc/rsyslog.d/by_mail =========================
6305N/A subject.template="mailSubject"
6305N/A body.enable="on" # !!!!! should not be needed - see 23584223
6305N/Asvcadm restart system/system-log:rsyslog
6305N/A====================== Create /etc/rsyslog.d/follow_file =======================
6305N/A file="/var/tmp/file_to_follow"
6305N/Asvcadm restart system/system-log:rsyslog
6305N/Aecho $"line created in a file\nand a second line" > /var/tmp/file_to_follow
6305N/A======================= Create file /etc/rsyslog.d/stats =======================
6305N/A log.syslog="off" # don't send stats through the normal processing pipeline. More on that in a bit
6305N/Arm -f /tmp/stats
6305N/Asvcadm restart system/system-log:rsyslog
6305N/Acat /tmp/stats # The file should be there and contain some stats
6305N/A======================== Create file /etc/rsyslog.d/tcp ========================
6305N/Asvcadm restart system/system-log:rsyslog
6305N/AMYSQL_TEST_DATADIR=/var/tmp/mysql
6305N/A"$MYSQL_BINDIR/mysqld" --datadir="$MYSQL_TEST_DATADIR" \
6305N/A --basedir=/usr/mysql/$MYSQL_VERSION --initialize-insecure
6305N/A========================= Create /etc/rsyslog.d/mysql ==========================
6305N/A$ModLoad ommysql.so
6305N/Asvcadm restart system/system-log:rsyslog
6305N/Aecho "select Message from SystemEvents" | mysql --user="$MYSQL_TEST_USER" --password="$MYSQL_TEST_PASSWORD" -D Syslog
6305N/A============================= Create /var/tmp/a.py =============================
6305N/A========================= Create /etc/rsyslog.d/socket =========================
6305N/A$OMUxSockSocket /tmp/socksample
6305N/Arm -f /tmp/socksample
6305N/Apython /var/tmp/a.py &
6305N/Asvcadm restart system/system-log:rsyslog
6305N/A# there should be output like !!! <14>Jun 13 20:05:56 S12-99 root: [ID 702911 user.info] test
6305N/A========================= Create /etc/rsyslog.d/server =========================
6305N/Asvcadm restart system/system-log:rsyslog
6305N/A!!! ================ On second machine create /etc/rsyslog.d/client ================
6305N/A!!! svcadm disable system/system-log:default
6305N/A!!! svcadm enable system/system-log:rsyslog
6305N/A!!! svcadm restart system/system-log:rsyslog
6305N/A!!! 2016-06-18T23:22:56+00:00 S12-101 root: [ID 702911 user.error] udp log
6305N/A========================= Modify /etc/rsyslog.d/server =========================
6305N/A!!! =============== On second machine replace /etc/rsyslog.d/client ================
6305N/A!!! svcadm restart system/system-log:rsyslog
6305N/A========================= Modify /etc/rsyslog.d/server =========================
6305N/A$DefaultNetstreamDriverCAFile /etc/rsyslog.cert/ca-cert.pem
6305N/A$DefaultNetstreamDriverCertFile /etc/rsyslog.cert/server-cert.pem
6305N/A$DefaultNetstreamDriverKeyFile /etc/rsyslog.cert/server-key.pem
6305N/Amkdir -p /etc/rsyslog.cert
6305N/ASUBJ='/CN=server.cz.oracle.com/O=Oracle Corporation/OU=Solaris RPE/C=CZ/ST=Czech republic/L=Prague/emailAddress=root@localhost'
6305N/Aopenssl genrsa 2048 > ca-key.pem
6305N/ASUBJ='/CN=client.cz.oracle.com/O=Oracle Corporation/OU=Solaris RPE/C=CZ/ST=Czech republic/L=Prague/emailAddress=root@localhost'
6305N/Aopenssl req -newkey rsa:2048 -days 3600 -nodes -keyout server-key.pem -out server-req.pem -subj "$SUBJ"
6305N/Aopenssl x509 -req -in server-req.pem -days 3600 -CA ca-cert.pem -CAkey ca-key.pem -set_serial 01 -out server-cert.pem
6305N/A!!! =============== On second machine replace /etc/rsyslog.d/client ================
6305N/A!!! $DefaultNetstreamDriverCAFile /etc/rsyslog.cert/ca-cert.pem
6305N/A!!! mkdir -p /etc/rsyslog.cert
6305N/A!!! svcadm restart system/system-log:rsyslog