Toto je vyrovnávacia pamäť Google pre http://wiki.cnl.tuke.sk/QoSProjekt/ModelEmployment. Je to snímka stránky, ako sa zobrazila dňa 15. mar. 2009 13:26:48 GMT. Aktuálna stránka sa odvtedy mohla zmeniť. Viac informácií

Len textová verzia
 
ModelEmployment < QoSProjekt < TWiki
r11 - 10 Jun 2007 - 02:36:32 - DaliborKudlaYou are here: TWiki >  QoSProjekt Web  > ModelEmployment

Todo table:

task id status start date due date task
dk-1 resolved dd.mm.2007 dd.mm.2007 precitat diplomovku M. Potockeho
dk-2 resolved dd.mm.2007 dd.mm.2007 precitat "Ako pisat diplomovku"
dk-3 resolved dd.mm.2007 dd.mm.2007 nastudovat Flexible NetFlow
dk-4 resolved dd.mm.2007 dd.mm.2007 zohnat zdrojove kody
dk-5 resolved dd.mm.2007 dd.mm.2007 rozbehat Beem na qos-meter.cnl.tuke.sk
dk-6 resolved dd.mm.2007 dd.mm.2007 rozbehat Collector na qos-meter.cnl.tuke.sk
dk-7 resolved dd.mm.2007 dd.mm.2007 JavaWebStart pre Analyzer na qos-meter.cnl.tuke.sk
dk-8 resolved dd.mm.2007 dd.mm.2007 napisat pouz. prirucku pre BasicMeter

NEW:

BasicMeter_pp.pdf: kompletna pouz. prirucka

Beem:

-pozrel som si empiho pouz. a syst. prirucku, nainstaloval chybajuce kniznice, skompiloval a spustil beem

$ sudo apt-get install libpcap0.8 libpcap0.8-dev
- nainstaluje libpcap(0.8.3-5) , libpcap-dev(0.8.3-5) ...vyhovuje poziadavkam - ak nie su pritomne nainstalujeme libssl-dev ( -drobna zmena oproti empiho navodu:
 $ sudo apt-get install libpcap0 libpcap0-dev 
nainstaluje starsiu verziu (0.7.2-7) )

$ sudo apt-get install libxml2 libxml2-dev
- nainstaluje libxml2(2.6.16-7) , libxml2-dev(2.6.16-7) ...podla empiho diplomovky sa vyzaduje verzia 2.6.23 alebo vyssia - ak sa libxml nevyskytuje v /usr/include/libxml prekopirovat to tam - mne sa zdalo, ze sa to sprava rovnako aj s touto verziou, ale tak radsej som pozhanal novsiu. akurat ze balik *.tar.gz, ktory som stiahol z netu akosi neslo nainstalovat ("your operation system's lex is insufficient to compile... " ???)

-tak som do repozitarov (/etc/apt/sources.list) pridal jeden zdroj:

#Etch
deb  http://ftp.debian.org/debian/ testing main  
(nech vas nemyli to "testing". tie balicky su v Etchi stable - http://packages.debian.org/stable/allpackages)

$ sudo apt-get install libxml2  
-upgradne libxml2 + dalsie potrebne balicky na najnovsiu stable verziu:
libxml2_2.6.27.dfsg-1
libxml2-dev_2.6.27.dfsg-1
libc6_2.3.6.ds1-13
libc6-dev 2.3.6.ds1-13
tzdata_2007d-1 
(to posledne je nejaka hlupost ohladom Time Zone and Daylight Saving Time, ale proste to nainstaloval akoze potrebny package...)

kudla@qos-meter:~/beem20070105$ make -f Makefile
g++ -Wall -g -O2 -D_THREAD_SAFE -o beem beem.o config.o capture.o sampling.o cache.o export.o ipfix.o -lpcap -lxml2 -lrt -lm

kudla@qos-meter:~/beem20070105$ ls
Doxyfile beem.h capture.h debug.h ipfix.c sampling.h
JXColl-linux beem.o capture.o debug.log ipfix.h sampling.o
JXColl.conf cache.c config.c example_collector ipfix.o test.dump
Makefile cache.h config.h export.c ipfix_def.h test2.dump
beem cache.o config.o export.h ipfix_fields.h test3.dump
beem.c capture.c config.xml export.o sampling.c

kudla@qos-meter:~/beem20070105$ ./beem
[info] Configured interface for capture is: eth3
[info] Configured read from file flag is: false
[info] Configured dumpfile filename is: test.dump
[info] Configured LibPcap BPF filter is: ip  
[info] Configured sampling type is: 0
[info] Configured 1st sampling parameter is: 4
[info] Configured 2nd sampling parameter is: 10
[error]:capture.c:363: SIOCGIFADDR: eth3: No such device
[debug]:config.c :150: Cleaning memory
[debug]:config.c:153: Exiting

-zrejme sa snazi cosi odchytavat na rozhrani eth3, ale to tam zjavne nie je, zrejme sa to tyka nejakeho configu... kazdopadne ja do toho zatial hlbsie nevidim, takze ocenim vsetky pripomienky a rady (co s tym, ako postupovat dalej, atd.)

(pozn. bezi vobec na qos-meter.cnl.tuke.sk nejaky traffic, ktory by sa dal merat?)

EDIT:

-v configure.xml zmenene interface na eth0:

<interface>eth0</interface>
-v configure.xml collector -> host zmena z "localhost" na "127.0.0.1":
<collector>
     <version>10</version>
     <host>127.0.0.1</host>
     ...       
</collector>

pozn.: $ ./beem potrebne spustat pomocou "sudo", inac to vyhodi tento error:

$ ./beem
...
[error]:capture.c:401: socket: Operation not permitted
...

$ sudo ./beem
[info] Configured interface for capture is: eth0
[info] Configured read from file flag is: false
[info] Configured dumpfile filename is: test.dump
[info] Configured LibPcap BPF filter is: ip
[info] Configured sampling type is: 0
[info] Configured 1st sampling parameter is: 4
[info] Configured 2nd sampling parameter is: 10
[info] Selected interface IP address: 147.232.48.148
[info] Selected interface IP netmask: 255.255.255.255
[info] Starting packet capturing.
[info] Starting time expiration of flows
[info] Starting export of flows
[info] Adding collector: 127.0.0.1:5647
[debug]:export.c:86: Adding template field #86 (eno:0, length:8)
[info] Exporting data to collector
[debug]:ipfix.c:1761: Records exported: 2
[info] Exporting data to collector
[debug]:ipfix.c:1761: Records exported: 1
...
[info] Number of captured packets: 219
[info] SIGINT signal trapped (CTRL + C)
[info] In case it got stuck, press CTRL + C again

Collector:

Ako prve treba nainstalovat Javu. Z repozitarov pre Etch je to easy.

Do /etc/apt/sources.list pridame

#Etch
deb http://ftp.us.debian.org/debian/ etch main contrib non-free
a potom
$sudo apt-get update

$sudo apt-get install sun-java5-jre

$java -version
java version "1.5.0_10"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_10-b03)
Java HotSpot(TM) Client VM (build 1.5.0_10-b03, mixed mode, sharing)

Potom bolo treba zmenit prava na subor JXColl-linux

kudla@qos-meter:~/zzz$ sudo chmod go+x JXColl-linux

Nestaci to spustit takto (sudo netreba):

kudla@qos-meter:~/zzz$ ./JXColl-linux JXColl.conf
Unable to find a supported JDK or JRE version. Version 1.3.1 or higher is required.
Check your installation and use +javahome to specify the JDK or JRE location

Prva moznost je pri kazdom spusteni na koniec pridat toto:

kudla@qos-meter:~/zzz$ ./JXColl-linux JXColl.conf +javahome /usr/lib/jvm/java-1.5.0-sun-1.5.0.10/jre/

Druha moznost (permanentne riesenie) je podla tohto navodu upravit subor .bashrc:

To add the bin directory of the jdk to your own PATH, for your own work, try the following inside a bash shell:

1) Change into your home directory - cd $HOME

2) Open the file ".bashrc". I recommend vi for simplicity here - vi .bashrc

3) Add the following line to the file. Replace the term (jdk directory) with the name of your java installation directory

export PATH=/usr/java/(jdk directory)/bin:$PATH
4) then save and exit vi - :wq

5) Use the "source" command to force linux to reload the .bashrc file which normally is read only when you log in each time - source .bashrc

6) You can test your PATH setting by checking for the version - java -version

Note that if you wish to set the PATH setting for all users of the system, you will want to log in as root in the bash shell and perform the same steps upon the file "/etc/ profile" rather than ".bashrc" in the home directory. Careful when editing system files. It's a good idea to make a backup of the file first just in case.

V nasom pripade to nie je jdk ale iba jre, ale to je jedno. Takze na koniec suboru .bashrc pridame tento riadok:

 
export PATH=/usr/lib/jvm/java-1.5.0-sun-1.5.0.10/jre/bin:$PATH

Najprv spustame Collector a az potom Beem (exporter), lebo tento hned na zaciatku posle sablonu (template) a potom uz len data.

 
kudla@qos-meter:~/zzz$  ./JXColl-linux JXColl.conf
2007-05-22 11:45:20,547 INFO [main] JXColl.Config    : Loading config file: JXColl.conf
2007-05-22 11:45:20,587 INFO [main] JXColl.JXColl    : Setting log level: ALL
2007-05-22 11:45:20,587 DEBUG[main] JXColl.JXColl    : Providing PacketCache for 25 packets.
2007-05-22 11:45:20,598 INFO [main] JXColl.NetConnect: Listening on port: 5647
2007-05-22 11:45:20,598 DEBUG[main] JXColl.NetConnect: Listening to UDP packets
2007-05-22 11:45:20,598 DEBUG[main] JXColl.NetConnect: Setting default input buffer: 65540
2007-05-22 11:45:20,601 INFO [main] export.DCServer  : DC server online on: 2138
2007-05-22 11:45:20,605 INFO [main] JXColl.JXColl    : press any key to KILL me ;)
2007-05-22 11:45:20,608 DEBUG[DC Service] export.DCServer  : Spawned 5 workers.
2007-05-22 11:45:35,226 INFO [Net Connect] JXColl.PacketListener: Incoming: /127.0.0.1 at port 37340 with length: 44
2007-05-22 11:45:35,226 INFO [Net Connect] JXColl.PacketListener: Parsed size: 65540 i=44
2007-05-22 11:45:35,227 INFO [Net Parser] JXColl.NetXMLParser: Processing data from: /127.0.0.1 NF version: 9 Flow count: 2
2007-05-22 11:45:35,242 DEBUG[Net Parser] JXColl.NetXMLParser: This packet was sent at : 2007-05-22 11:45:35+0100 with seq ID : 0
2007-05-22 11:45:35,242 DEBUG[Net Parser] JXColl.NetXMLParser: The netflow exporter is online for : 5 seconds (0 minutes) + sourceID is: 0
2007-05-22 11:45:35,242 DEBUG[Net Parser] JXColl.NetXMLParser: TLV: 12
2007-05-22 11:45:35,242 DEBUG[Net Parser] JXColl.NetXMLParser: FlowsetID: 0 TLV-4: 8
2007-05-22 11:45:35,242 DEBUG[Net Parser] JXColl.NetXMLParser: Template ID: 256
2007-05-22 11:45:35,242 DEBUG[Net Parser] JXColl.NetXMLParser: Field Count: 1
2007-05-22 11:45:35,243 DEBUG[Net Parser] JXColl.NetXMLParser: Type: 86  Length: 8
2007-05-22 11:45:35,243 INFO [Net Parser] JXColl.NetXMLParser: END Cycle no. : 1
2007-05-22 11:45:35,243 DEBUG[Net Parser] JXColl.NetXMLParser: TLV: 12
2007-05-22 11:45:35,243 DEBUG[Net Parser] JXColl.NetXMLParser: FlowsetID: 256 TLV-4: 8
2007-05-22 11:45:35,243 INFO [Net Parser] JXColl.NetXMLParser: DATA ind:36 dlzka flowu: 8
2007-05-22 11:45:35,243 INFO [Net Parser] JXColl.NetXMLParser: Dekodujem flow, pre template size: 8
2007-05-22 11:45:35,244 DEBUG[Net Parser] JXColl.NetXMLParser: Insert: '0.0.0.0','0.0.0.0',null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,'127.0.0.1' ,'2007-05-22 11:45:35+0100' ,9
2007-05-22 11:45:35,244 DEBUG[Net Parser] JXColl.NetXMLParser: Padding seek: 0
2007-05-22 11:45:35,245 DEBUG[Net Parser] JXColl.NetXMLParser: INDEX after flow(s) decode: 44
2007-05-22 11:45:35,245 INFO [Net Parser] JXColl.NetXMLParser: END Cycle no. : 2
2007-05-22 11:45:35,245 INFO [Net Parser] JXColl.NetXMLParser: END INDEX: 44
...
2007-05-22 11:46:23,049 INFO [main] JXColl.JXColl    : JXColl catched kill signal, starting cleaning process ...
2007-05-22 11:46:23,049 INFO [main] JXColl.JXColl    :
2007-05-22 11:46:23,050 ERROR[Net Connect] JXColl.NetConnect: java.nio.channels.AsynchronousCloseException
2007-05-22 11:46:23,051 ERROR[Net Parser] JXColl.NetXMLParser: Blocking interrupted! java.lang.InterruptedException
2007-05-22 11:46:23,051 ERROR[DC WThread 0] export.DCWorker  : Waiting for connection was interrupted : java.lang.InterruptedException
2007-05-22 11:46:23,051 ERROR[DC WThread 1] export.DCWorker  : Waiting for connection was interrupted : java.lang.InterruptedException
2007-05-22 11:46:23,051 ERROR[DC WThread 2] export.DCWorker  : Waiting for connection was interrupted : java.lang.InterruptedException
2007-05-22 11:46:23,051 ERROR[DC WThread 3] export.DCWorker  : Waiting for connection was interrupted : java.lang.InterruptedException
2007-05-22 11:46:23,052 ERROR[DC WThread 4] export.DCWorker  : Waiting for connection was interrupted : java.lang.InterruptedException
2007-05-22 11:46:23,052 ERROR[DC Service] export.DCServer  : java.net.SocketException: Socket closed

-- DaliborKudla - Last edit: 22 May 2007

toggleopenShow attachmentstogglecloseHide attachments
Topic attachments
I Attachment Action Size Date Who Comment
pdfpdf BasicMeter_pp.pdf manage 1102.5 K 10 Jun 2007 - 02:10 DaliborKudla BasicMeter - pouz. prirucka
Edit | WYSIWYG | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r11 < r10 < r9 < r8 < r7 | More topic actions
 
Powered by TWiki
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback