[LON-CAPA-cvs] cvs: loncom / lchttpdlogs

raeburn raeburn at source.lon-capa.org
Thu Mar 28 11:16:39 EDT 2013


raeburn		Thu Mar 28 15:16:39 2013 EDT

  Modified files:              
    /loncom	lchttpdlogs 
  Log:
  - Apache log files have different names from other distros in Debian and
    Ubuntu.
  
  
Index: loncom/lchttpdlogs
diff -u loncom/lchttpdlogs:1.1 loncom/lchttpdlogs:1.2
--- loncom/lchttpdlogs:1.1	Thu Nov  3 22:32:04 2011
+++ loncom/lchttpdlogs	Thu Mar 28 15:16:38 2013
@@ -2,7 +2,7 @@
 #
 # The Learning Online Network with CAPA
 #
-# $Id: lchttpdlogs,v 1.1 2011/11/03 22:32:04 raeburn Exp $
+# $Id: lchttpdlogs,v 1.2 2013/03/28 15:16:38 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -124,8 +124,14 @@
     my ($distro,$protocol) = @_;
     my $text;
     my $logpath = '/var/log/httpd';
-    if ($distro =~ /^(suse|debian|ubuntu)/) {
-        $logpath = '/var/log/apache2'; 
+    my $access_log_file = 'access_log';
+    my $error_log_file = 'error_log';
+    if ($distro =~ /^(debian|ubuntu)/) {
+        $logpath = '/var/log/apache2';
+        $access_log_file = 'access.log';
+        $error_log_file = 'error.log';
+    } elsif ($distro =~ /^suse/) {
+        $logpath = '/var/log/apache2';
     } elsif ($distro =~ /^sles(\d+)/) {
         if ($1 >= 10) {
             $logpath = '/var/log/apache2';
@@ -133,8 +139,6 @@
             $logpath = '/var/log/apache';
         }
     }
-    my $access_log_file = 'access_log';
-    my $error_log_file = 'error_log';
     if ($protocol eq 'https') {
         $access_log_file = 'ssl_'.$access_log_file;
         $error_log_file = 'ssl_'.$error_log_file;




More information about the LON-CAPA-cvs mailing list