diff options
author | Scott Ullrich <sullrich@sullrich-MacBookPro.local> | 2009-03-18 20:19:20 -0400 |
---|---|---|
committer | Scott Ullrich <sullrich@sullrich-MacBookPro.local> | 2009-03-18 20:19:20 -0400 |
commit | c676893ce877881251a520d6b43a3d2c29b93ea3 (patch) | |
tree | a95907ba484f8ce3d872ab0d3b92adcb0eaf6464 | |
parent | 77518fbf3d033cb713512c4770f9f35696a88934 (diff) | |
download | pfsense-c676893ce877881251a520d6b43a3d2c29b93ea3.zip pfsense-c676893ce877881251a520d6b43a3d2c29b93ea3.tar.gz |
Echo out data to start of log files
-rwxr-xr-x | etc/rc | 12 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_auth.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_dhcp.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_filter.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_filter_dynamic.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_ipsec.php | 1 | ||||
-rw-r--r-- | usr/local/www/diag_logs_ntpd.php | 1 | ||||
-rw-r--r-- | usr/local/www/diag_logs_openvpn.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_relayd.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_slbd.php | 1 | ||||
-rwxr-xr-x | usr/local/www/diag_logs_vpn.php | 2 |
11 files changed, 23 insertions, 0 deletions
@@ -237,6 +237,18 @@ else /usr/sbin/fifolog_create -s 50688 /var/log/relayd.log /usr/sbin/fifolog_create -s 50688 /var/log/lighttpd.log /usr/sbin/fifolog_create -s 50688 /var/log/ntpd.log + # Echo date to log files (start time) + /bin/date | /usr/sbin/fifolog_writer /var/log/system.log + /bin/date | /usr/sbin/fifolog_writer /var/log/filter.log + /bin/date | /usr/sbin/fifolog_writer /var/log/dhcpd.log + /bin/date | /usr/sbin/fifolog_writer /var/log/vpn.log + /bin/date | /usr/sbin/fifolog_writer /var/log/openvpn.log + /bin/date | /usr/sbin/fifolog_writer /var/log/portalauth.log + /bin/date | /usr/sbin/fifolog_writer /var/log/ipsec.log + /bin/date | /usr/sbin/fifolog_writer /var/log/relayd.log + /bin/date | /usr/sbin/fifolog_writer /var/log/lighttpd.log + /bin/date | /usr/sbin/fifolog_writer /var/log/ntpd.log + fi # change permissions on newly created fifolog files. chmod 0600 /var/log/system.log /var/log/filter.log /var/log/dhcpd.log /var/log/vpn.log /var/log/portalauth.log /var/log/relayd.log diff --git a/usr/local/www/diag_logs_auth.php b/usr/local/www/diag_logs_auth.php index c8b899b..a494411 100755 --- a/usr/local/www/diag_logs_auth.php +++ b/usr/local/www/diag_logs_auth.php @@ -54,6 +54,7 @@ if ($_POST['clear']) { if(file_exists("{$portal_logfile}")) unlink("{$portal_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$portal_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$portal_logfile}"); } } diff --git a/usr/local/www/diag_logs_dhcp.php b/usr/local/www/diag_logs_dhcp.php index a648690..7e9003e 100755 --- a/usr/local/www/diag_logs_dhcp.php +++ b/usr/local/www/diag_logs_dhcp.php @@ -56,6 +56,7 @@ if ($_POST['clear']) { if(file_exists("{$dhcpd_logfile}")) unlink("{$dhcpd_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$dhcpd_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$dhcpd_logfile}"); } } diff --git a/usr/local/www/diag_logs_filter.php b/usr/local/www/diag_logs_filter.php index 6918a2b..c6c007c 100755 --- a/usr/local/www/diag_logs_filter.php +++ b/usr/local/www/diag_logs_filter.php @@ -65,6 +65,7 @@ if ($_POST['clear']) { if(file_exists("{$filter_logfile}")) unlink("{$filter_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$filter_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$filter_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_filter_dynamic.php b/usr/local/www/diag_logs_filter_dynamic.php index 23cc1fd..58d239c 100755 --- a/usr/local/www/diag_logs_filter_dynamic.php +++ b/usr/local/www/diag_logs_filter_dynamic.php @@ -57,6 +57,7 @@ if ($_POST['clear']) { if(file_exists("{$filter_logfile}") unlink("{$filter_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$filter_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$filter_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_ipsec.php b/usr/local/www/diag_logs_ipsec.php index 54b9626..bea3f00 100755 --- a/usr/local/www/diag_logs_ipsec.php +++ b/usr/local/www/diag_logs_ipsec.php @@ -72,6 +72,7 @@ if ($_POST['clear']) { if(file_exists("{$ipsec_logfile}")) unlink("{$ipsec_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$ipsec_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$ipsec_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_ntpd.php b/usr/local/www/diag_logs_ntpd.php index 3a3c041..8f2efa4 100644 --- a/usr/local/www/diag_logs_ntpd.php +++ b/usr/local/www/diag_logs_ntpd.php @@ -54,6 +54,7 @@ if ($_POST['clear']) { if(file_exists("{$ntpd_logfile}")) unlink("{$ntpd_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$ntpd_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$ntpd_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_openvpn.php b/usr/local/www/diag_logs_openvpn.php index b26c3c8..f157266 100644 --- a/usr/local/www/diag_logs_openvpn.php +++ b/usr/local/www/diag_logs_openvpn.php @@ -59,6 +59,7 @@ if ($_POST['clear']) { if(file_exists("{$openvpn_logfile}")) unlink("{$openvpn_logfile}"); exec("/usr/sbin/fifolog_create -s 262144 {$openvpn_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$openvpn_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_relayd.php b/usr/local/www/diag_logs_relayd.php index 5bb6c51..6bb746f 100755 --- a/usr/local/www/diag_logs_relayd.php +++ b/usr/local/www/diag_logs_relayd.php @@ -55,6 +55,7 @@ if ($_POST['clear']) { if(file_exists("{$relayd_logfile}")) unlink("{$relayd_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$relayd_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$relayd_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_slbd.php b/usr/local/www/diag_logs_slbd.php index a7a3a68..8cbd915 100755 --- a/usr/local/www/diag_logs_slbd.php +++ b/usr/local/www/diag_logs_slbd.php @@ -55,6 +55,7 @@ if ($_POST['clear']) { if(file_exists("{$slbd_logfile}")) unlink("{$slbd_logfile}"); exec("/usr/sbin/fifolog_create -s 511488 {$slbd_logfile}"); + exec("/bin/date | /usr/sbin/fifolog_writer {$slbd_logfile}"); system_syslogd_start(); } } diff --git a/usr/local/www/diag_logs_vpn.php b/usr/local/www/diag_logs_vpn.php index 3fccad3..156267d 100755 --- a/usr/local/www/diag_logs_vpn.php +++ b/usr/local/www/diag_logs_vpn.php @@ -54,6 +54,8 @@ if ($_POST['clear']) { if(file_exists("/var/log/vpn.log")) unlink("/var/log/vpn.log"); exec("/usr/sbin/fifolog_create -s 50688 /var/log/vpn.log"); + exec("/bin/date | /usr/sbin/fifolog_writer /var/log/vpn.log"); + system_syslogd_start(); } /* redirect to avoid reposting form data on refresh */ header("Location: diag_logs_vpn.php"); |