Truncate the original log file to zero size in place after creating a copy, instead of moving the old log file and optionally creating a new one. It can be used when some program cannot be told to close its logfile and thus might continue writing (appending) to the previous log file forever. Note that there is a very small time slice between copying the file and truncating it, so some logging data might be lost. When this option is used, the create option will have no effect, as the old log file stays in place.
KEY_DIR=~/openvpn-ca/keys
OUTPUT_DIR=~/client-configs/files
BASE_CONFIG=~/client-configs/base.conf
cat ${BASE_CONFIG} \
<(echo -e '<ca>') \
${KEY_DIR}/ca.crt \
<(echo -e '</ca>\n<cert>') \
${KEY_DIR}/${1}.crt \
<(echo -e '</cert>\n<key>') \
${KEY_DIR}/${1}.key \
<(echo -e '</key>\n<tls-auth>') \
${KEY_DIR}/ta.key \
<(echo -e '</tls-auth>') \
> ${OUTPUT_DIR}/${1}.ovpn
sudoers nopasswd freeIPAгугл выдал решение
GET /guest/s/default/?id=be:ef:00:df:dd:ee&ap=78:78:78:78:78:78&t=1500000000&url=http://captive.apple.com%2fhotspot-detect.html&ssid=blabla HTTP/1.0
from pyunifi.controller import Controller
c = Controller(UNIFI_WLC_IP, UNIFI_WLC_USER, UNIFI_WLC_PASSW, UNIFI_WLC_PORT, INIFI_WLC_VER, UNIFI_WLC_SITE_ID, UNIFI_WLC_SSL_VERIFY)
c.authorize_guest(mac, TIME_QOUTE,
up_bandwidth=None, down_bandwidth=None, byte_quota=None, ap_mac=None)
А вот на ноуте с USB сетевой картинка рвалась и обнаружились потери пакетов.
iddqd@iddq:~$ dmesg | grep eth[01]
[ 1.874054] e1000 0000:02:00.0 eth0: (PCI:66MHz:32-bit) 00:50:56:11:11:11
[ 1.874672] e1000 0000:02:00.0 eth0: Intel(R) PRO/1000 Network Connection
[ 2.237540] e1000 0000:02:02.0 eth1: (PCI:66MHz:32-bit) 00:50:56:11:11:12
[ 2.238185] e1000 0000:02:02.0 eth1: Intel(R) PRO/1000 Network Connection
[ 2.240464] e1000 0000:02:02.0 ens34: renamed from eth1
[ 2.243988] e1000 0000:02:00.0 ens32: renamed from eth0
### Option: Timeout
# Specifies how long we wait for agent, SNMP device or external check (in seconds).
#
# Mandatory: no
# Range: 1-30
# Default:
# Timeout=3