#!/bin/bash set -eu if [[ $EUID -ne 0 ]]; then echo "ERROR: you must be root to run this" 1>&2 exit 1 fi scr_name=os-logs scr_file=$(mktemp) this_dir=$(cd `dirname "${BASH_SOURCE[0]}"` && pwd) cat > $scr_file <> $scr_file fi done # XXX: Note that this is obsolete if the Neutron DHCP agent is in use. echo "screen -t dnsmasq sh -c \"tail -f /var/log/syslog | grep dnsmasq\"" >> $scr_file exec screen -c $scr_file