Project

General

Profile

Download (3.56 KB) Statistics
| Branch: | Tag: | Revision:

univnautes / usr / local / www / diag_logs_relayd.php @ a1b66bec

1
<?php
2
/* $Id$ */
3
/*
4
	diag_logs_relayd.php
5
	part of pfSense
6

    
7
	Copyright (C) 2008 Bill Marquette <bill.marquette@gmail.com>.
8
	Copyright (C) 2008 Seth Mos <seth.mos@dds.nl>.
9
	All rights reserved.
10

    
11
	Redistribution and use in source and binary forms, with or without
12
	modification, are permitted provided that the following conditions are met:
13

    
14
	1. Redistributions of source code must retain the above copyright notice,
15
	   this list of conditions and the following disclaimer.
16

    
17
	2. Redistributions in binary form must reproduce the above copyright
18
	   notice, this list of conditions and the following disclaimer in the
19
	   documentation and/or other materials provided with the distribution.
20

    
21
	THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
22
	INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
23
	AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
24
	AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
25
	OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26
	SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27
	INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28
	CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29
	ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30
	POSSIBILITY OF SUCH DAMAGE.
31
*/
32

    
33
/*	
34
	pfSense_MODULE:	routing
35
*/
36

    
37
##|+PRIV
38
##|*IDENT=page-status-systemlogs-loadbalancer
39
##|*NAME=Status: System logs: Load Balancer page
40
##|*DESCR=Allow access to the 'Status: System logs: Load Balancer' page.
41
##|*MATCH=diag_logs_relayd.php*
42
##|-PRIV
43

    
44
require("guiconfig.inc");
45

    
46
$relayd_logfile = "{$g['varlog_path']}/relayd.log";
47

    
48
$nentries = $config['syslog']['nentries'];
49
if (!$nentries)
50
	$nentries = 50;
51

    
52
if ($_POST['clear']) 
53
	clear_log_file($relayd_logfile);
54

    
55
$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("Load Balancer"));
56
$shortcut_section = "relayd";
57
include("head.inc");
58

    
59
?>
60

    
61
<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
62
<?php include("fbegin.inc"); ?>
63
<table width="100%" border="0" cellpadding="0" cellspacing="0" summary="load balancer">
64
  <tr><td>
65
<?php
66
	$tab_array = array();
67
	$tab_array[] = array(gettext("System"), false, "diag_logs.php");
68
	$tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php");
69
	$tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php");
70
	$tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php");
71
	$tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php");
72
	$tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php");
73
	$tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php");
74
	$tab_array[] = array(gettext("Load Balancer"), true, "diag_logs_relayd.php");
75
	$tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php");
76
	$tab_array[] = array(gettext("NTP"), false, "diag_logs_ntpd.php");
77
	$tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php");
78
	display_top_tabs($tab_array);
79
?>
80
  </td></tr>
81
  <tr>
82
    <td>
83
	<div id="mainarea">
84
		<table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0" summary="main area">
85
		  <tr>
86
			<td colspan="2" class="listtopic">
87
			  <?php printf(gettext("Last %s Load Balancer log entries"),$nentries);?></td>
88
		  </tr>
89
		  <?php dump_clog($relayd_logfile, $nentries); ?>
90
		<tr><td><br /><form action="diag_logs_relayd.php" method="post">
91
<input name="clear" type="submit" class="formbtn" value="<?=gettext("Clear log"); ?>" /></form></td></tr>
92
		</table>
93
	</div>
94
	</td>
95
  </tr>
96
</table>
97
<?php include("fend.inc"); ?>
98
</body>
99
</html>
(31-31/256)