Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Debian Apache Mailgraph - CGI Datei anzeigen

Empfohlene Antworten

Veröffentlicht

Hallo liebe Linux-Gemeinde,

ich habe folgendes Problem: Ich habe einen Apache2 Webserver auf Debian Lenny installiert, dieser läuft auch richtig. Dann habe ich auch Postfix installiert was auch richtig funktioniert. Jetzt will ich Mailgraph verwenden. Nach getaner Installation sollte beim Aufruf von http://mein-server/mailgraph/cgi-bin/mailgraph.cgi die Tabellen erscheinen. Allerdings sieht es so aus, als könnte Apache keine cgi-Dateien anzeigen können. Da er nur den Code anzeigt, ihn aber nicht ausführt.

Ausschnitt:


#!/usr/bin/perl -w


# mailgraph -- postfix mail traffic statistics

# copyright (c) 2000-2007 ETH Zurich

# copyright (c) 2000-2007 David Schweikert <david@schweikert.ch>

# released under the GNU General Public License


use RRDs;

use POSIX qw(uname);


my $VERSION = "1.14";


my $host = (POSIX::uname())[1];

my $scriptname = 'mailgraph.cgi';

my $xpoints = 540;

my $points_per_sample = 3;

my $ypoints = 160;

my $ypoints_err = 96;

my $rrd = '/var/lib/mailgraph/mailgraph.rrd'; # path to where the RRD database is

my $rrd_virus = '/var/lib/mailgraph/mailgraph_virus.rrd'; # path to where the Virus RRD database is

my $tmp_dir = '/var/lib/mailgraph'; # temporary directory where to store the images


my @graphs = (

   { title => 'Last Day',   seconds => 3600*24,        },

   { title => 'Last Week',  seconds => 3600*24*7,      },

   { title => 'Last Month', seconds => 3600*24*31,     },

   { title => 'Last Year',  seconds => 3600*24*365, },

);


my %color = (

   sent     => '000099', # rrggbb in hex

   received => '009900',

   rejected => 'AA0000',

   bounced  => '000000',

   virus    => 'DDBB00',

   spam     => '999999',

);


sub rrd_graph(@)

{

   my ($range, $file, $ypoints, @rrdargs) = @_;

   my $step = $range*$points_per_sample/$xpoints;

   # choose carefully the end otherwise rrd will maybe pick the wrong RRA:

   my $end  = time; $end -= $end % $step;

   my $date = localtime(time);

   $date =~ s|:|\\:|g unless $RRDs::VERSION < 1.199908;

usw....

Wie kann ich Apache beibringen die Datei anzuzeigen?

Vielen Dank im Vorraus!

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.