2 Wichtige IAM probleme...

Backup, Restore und Transfer von Daten
Post Reply
mrc
Posts: 22
Joined: 2003-07-04 15:08
 

2 Wichtige IAM probleme...

Post by mrc »

Hallo leute,

es geht darum das ich es nicht fertig bringe das IAM mir richtige HTML ausgaben macht ich will das er genau diesen bericht:

Code: Select all

                IP traffic (2004-01-09..2004-01-10):
                ====================================
| traffic  | cost      | description                              |
+----------+-----------+------------------------------------------+
|   0.0 MB |           | local (local network)                    |
+----------+-----------+------------------------------------------+
|   0.0 MB |           | free of charge                           |
+----------+-----------+------------------------------------------+
|          |           |                                          |
| 209.4 MB | 10.47 EUR | hlds_27030 (HLDS_27030)                  |
| 149.1 MB |  7.45 EUR | teamspeak_shx (teamspeak_shx)            |
|  46.6 MB |  2.33 EUR | teamspeak_inf (teamspeak_inf)            |
|  35.1 MB |  1.76 EUR | ventrilo (ventrilo)                      |
|  15.8 MB |  0.79 EUR | outgoing (without other listed services) |
|   6.0 MB |  0.30 EUR | hlds_27020 (HLDS_27020)                  |
|   3.4 MB |  0.17 EUR | ip_local_port_range (probably FTP)       |
|   2.9 MB |  0.14 EUR | misc (ssh, dns, identd)                  |
|   1.2 MB |  0.06 EUR | psybnc                                   |
|   1.0 MB |  0.05 EUR | www (http/https/caudium)                 |
|   0.0 MB |  0.00 EUR | ftp (FTP (without passive data))         |
|   0.0 MB |  0.00 EUR | mail (smtp)                              |
|   0.0 MB |  0.00 EUR | tsinterface (tsinterface)                |
|   0.0 MB |  0.00 EUR | cvs (grass-cvs)                          |
|   0.0 MB |  0.00 EUR | rsync (rsync server (not backup))        |
+----------+-----------+------------------------------------------+
| 470.6 MB | 23.53 EUR | internet services                        |
+----------+-----------+------------------------------------------+
|          |           |                                          |
|  49.3 MB |  2.47 EUR | unknown (not in any chain)               |
|   0.1 MB |  0.00 EUR | related (related connections)            |
|   0.0 MB |  0.00 EUR | fragment (fragmented packets)            |
+----------+-----------+------------------------------------------+
|  49.4 MB |  2.47 EUR | other traffic (unspecified)              |
+----------+-----------+------------------------------------------+
Als HTML ausgibt sollt ja auch der sinn sein glaub ich oder nicht? Sollt ja möglich sein... hier ein link: http://www.astone.biz/iam/index.html mit auswahl der beiden html datein.

Mein iam_report sieht folgender maßen aus

Code: Select all

#!/bin/sh

IAM=/usr/local/iam/iam
DUMP=/usr/local/iam/dump
WWWDIR=/home/www/web1/iam

YM_CURRENT=`date '+%Y-%m'`
YM_LAST=`date --date='1 month ago' '+%Y-%m'`
YM_NEXT=`date --date='1 month' '+%Y-%m'`

$IAM -f $YM_CURRENT-00 -t $YM_CURRENT-99 -w $WWWDIR/$YM_CURRENT.html $DUMP
$IAM -f $YM_LAST-00 -t $YM_LAST-99 -w $WWWDIR/$YM_LAST.html $DUMP

#$IAM -f $YM_CURRENT-25 -t $YM_NEXT-25 -w $WWWDIR/$YM_CURRENT.html $DUMP
#$IAM -f $YM_LAST-25 -t $YM_CURRENT-25 -w $WWWDIR/$YM_LAST.html $DUMP

ln -sf $WWWDIR/$YM_CURRENT.html $WWWDIR/current.html
ln -sf $WWWDIR/$YM_LAST.html $WWWDIR/last.html

exit $?
hoffe mir kann jemand helfen des weiteren würd ich gern wissen wie ich die preisberechnung ändern kann da ich für 1 GB Traffic 0,29 cent zahle würd ich gern den preis je MB bzw. GB eintragen damit er mir auch die EUR korrekt berechnet :)

hoffe ihr habt grob verstanden was ich möcht danke im voraus,

euer

mRc
chris76
Posts: 1878
Joined: 2003-06-27 14:37
Location: Germering
 

Re: 2 Wichtige IAM probleme...

Post by chris76 »

Moin
Ich hatte das gleiche Problem bis ich meine iam_report wie folgt geändert habe.

Code: Select all

#!/bin/sh

IAM=/usr/local/iam/iam
DUMP=/usr/local/iam/dump
WWWDIR=/home/www/web1/html/_report

YM_CURRENT=`date '+%Y-%m'`
YM_TLAST=`date --date='2 month ago' '+%Y-%m'`
YM_LAST=`date --date='1 month ago' '+%Y-%m'`
YM_NEXT=`date --date='1 month' '+%Y-%m'`
YM_DAY=`date '+%d'`

if [ $YM_DAY -lt 02 ]
then
    $IAM -f $YM_LAST-02 -t $YM_CURRENT-02 -w $WWWDIR/$YM_CURRENT.html $DUMP
    $IAM -f $YM_TLAST-02 -t $YM_LAST-02 -w $WWWDIR/$YM_LAST.html $DUMP
    ln -sf $WWWDIR/$YM_CURRENT.html $WWWDIR/current.html
    ln -sf $WWWDIR/$YM_LAST.html $WWWDIR/last.html
else
    $IAM -f $YM_CURRENT-02 -t $YM_NEXT-02 -w $WWWDIR/$YM_NEXT.html $DUMP
    $IAM -f $YM_LAST-02 -t $YM_CURRENT-02 -w $WWWDIR/$YM_CURRENT.html $DUMP
    ln -sf $WWWDIR/$YM_NEXT.html $WWWDIR/current.html
    ln -sf $WWWDIR/$YM_CURRENT.html $WWWDIR/last.html
fi

exit $?
ist so auch in der Suche zu finden gewesen.
ich habe lediglich eine anderen abrechungstag.

Ciao Christian
mrc
Posts: 22
Joined: 2003-07-04 15:08
 

Re: 2 Wichtige IAM probleme...

Post by mrc »

dank dir könntest du mir noch sagen wie der report aussehen muss wenn mein abrechnungstag der 1. ist?
chris76
Posts: 1878
Joined: 2003-06-27 14:37
Location: Germering
 

Re: 2 Wichtige IAM probleme...

Post by chris76 »

Die 9 Stellen wo 02 steht ersetzt du durch 01, bei mir ist der 2te der Abrechungstag

Ciao Christian
mrc
Posts: 22
Joined: 2003-07-04 15:08
 

Re: 2 Wichtige IAM probleme...

Post by mrc »

und wie lös ich das problem mit der berechnung?
chris76
Posts: 1878
Joined: 2003-06-27 14:37
Location: Germering
 

Re: 2 Wichtige IAM probleme...

Post by chris76 »

Such doch mal im forum, da habe ich auch schon jede menge posts zum ändern der chains gesehen.

Ciao Christian
mrc
Posts: 22
Joined: 2003-07-04 15:08
 

Re: 2 Wichtige IAM probleme...

Post by mrc »

ich such und such aber im bezug auf die berechnung find ich einfach nichts :(
dopefish
Posts: 142
Joined: 2003-02-06 12:57
Location: Karlsruhe
Contact:
 

Re: 2 Wichtige IAM probleme...

Post by dopefish »

aus dem HOWTO im iam download
2. iam
------

Put the file iam and all *.py files in a directory of your choice.
Edit chains.py to set categories, names, rates and their descriptions.
There will be a configuration file for this in a future release.
in chans.py befindet sich neben die katagorien auch die definition von rates für free, service und other ;)
mrc
Posts: 22
Joined: 2003-07-04 15:08
 

Re: 2 Wichtige IAM probleme...

Post by mrc »

ach ich sehs rates nur welchen wert muss ich nun mit 0,29 Eur ersetzen damit ers mir in zukunft richtig rechnet :/
Post Reply