From jonathenwu at hotmail.com Mon Aug 15 06:21:46 2005 From: jonathenwu at hotmail.com (=?gb2312?B?zuIg6rs=?=) Date: Mon, 15 Aug 2005 13:21:46 +0000 Subject: [Diffusion-users] trace format of diffusion Message-ID: Hi, I am using diffusion 3.2.0 in ns-2. One-Phase-Pull algorithm was chosen. In my simulation exist 100 nodes, 1 sink and 99 sources. The trace file I got made analysis tough. I want to know how many data messages sent by a source have been received by sink. The following is my way: on sink node, counter the number of the data messages which has the same id as sent by a source. But I found sink node just received a small amount of data messages. I think because of the aggregation of other nodes. But from trace file, I can't know which nodes has aggregated a data message reaching it. Do I have to change trace file of ns-2? thanks From shruti.beohar at gmail.com Mon Aug 15 20:14:21 2005 From: shruti.beohar at gmail.com (Shruti Beohar) Date: Mon, 15 Aug 2005 23:14:21 -0400 Subject: [Diffusion-users] trace format of diffusion In-Reply-To: References: Message-ID: <566ac03f05081520145d308b19@mail.gmail.com> Hello, How do you find the id of the source from the message? It is possible that you are getting the wrong id. A not so good way is to have each node send a data message containing its own id. i.e. set the AppCounterAttr to ((DiffusionRouting*)dr_)->getNodeId(). Assuming you are using the sample ping application that comes with diffusion, you can find the id of the source by reading the data message in TPPPingReceiverApp::recv Hope this helps. Shruti On 8/15/05, Îâ ê» wrote: > Hi, > I am using diffusion 3.2.0 in ns-2. One-Phase-Pull algorithm was chosen. In > my simulation exist 100 nodes, 1 sink and 99 sources. The trace file I got > made analysis tough. I want to know how many data messages sent by a source > have been received by sink. The following is my way: on sink node, counter > the number of the data messages which has the same id as sent by a source. > But I found sink node just received a small amount of data messages. I > think because of the aggregation of other nodes. But from trace file, I > can't know which nodes has aggregated a data message reaching it. Do I have > to change trace file of ns-2? > thanks > > > From shruti.beohar at gmail.com Tue Aug 16 15:05:49 2005 From: shruti.beohar at gmail.com (Shruti Beohar) Date: Tue, 16 Aug 2005 18:05:49 -0400 Subject: [Diffusion-users] trace format of diffusion In-Reply-To: References: <566ac03f05081520145d308b19@mail.gmail.com> Message-ID: <566ac03f050816150510dc1f28@mail.gmail.com> Hi, I haven't looked much at trace files, I worked with the DiffPrint messages. Yeah, make the changes and run the ping application again. On 8/16/05, Îâ ê» wrote: > Hi, > The trace file has following format: > s 0.000001000 _0_ AGT --- 30504276 diffusion 0 [0 0 0 0] ------- [0:254 > 0:255 32 0] > r 0.000001000 _0_ RTR --- 30504276 diffusion 0 [0 0 0 0] ------- [0:254 > 0:255 32 0] > s 0.000001000 _1_ AGT --- 503803425 diffusion 0 [0 0 0 0] ------- [1:254 > 1:255 32 0] > r 0.000001000 _1_ RTR --- 503803425 diffusion 0 [0 0 0 0] ------- [1:254 > 1:255 32 0] > s 0.000001000 _2_ AGT --- 1374534831 diffusion 0 [0 0 0 0] ------- [2:254 > 2:255 32 0] > r 0.000001000 _2_ RTR --- 1374534831 diffusion 0 [0 0 0 0] ------- [2:254 > 2:255 32 0] > s 0.010001000 _1_ AGT --- 503803426 diffusion 0 [0 0 0 0] ------- [1:254 > 1:255 32 0] > r 0.010001000 _1_ RTR --- 503803426 diffusion 0 [0 0 0 0] ------- [1:254 > 1:255 32 0] > s 0.010001000 _2_ AGT --- 1374534832 diffusion 0 [0 0 0 0] ------- [2:254 > 2:255 32 0] > r 0.010001000 _2_ RTR --- 1374534832 diffusion 0 [0 0 0 0] ------- [2:254 > 2:255 32 0] > r 0.010002000 _1_ AGT --- 672080287 diffusion 0 [0 0 0 0] ------- [1:255 > 1:254 32 0] > r 0.010002000 _2_ AGT --- 352499576 diffusion 0 [0 0 0 0] ------- [2:255 > 2:254 32 0] > s 0.110001000 _0_ AGT --- 30504277 diffusion 0 [0 0 0 0] ------- [0:254 > 0:255 32 0] > r 0.110001000 _0_ RTR --- 30504277 diffusion 0 [0 0 0 0] ------- [0:254 > 0:255 32 0] > r 0.110002000 _0_ AGT --- 729236 diffusion 0 [0 0 0 0] ------- [0:255 > 0:254 32 0] > s 0.219003000 _0_ AGT --- 30504278 diffusion 0 [0 0 0 0] ------- [0:254 > 0:255 32 0] > r 0.219003000 _0_ RTR --- 30504278 diffusion 0 [0 0 0 0] ------- [0:254 > 0:255 32 0] > ..... > I think 503803425 is the packet id sent by node 1, so I check if node 0 has > received a packet whose id is 503803425. By this way I judge from which > source the packet came. > I can't understand your way.Do you mean I execute directly C++ code of > diffusion after I have changed the code as you told? > > > > > >From: Shruti Beohar > >To: Îâ ê» > >CC: diffusion-users at isi.edu > >Subject: Re: [Diffusion-users] trace format of diffusion > >Date: Mon, 15 Aug 2005 23:14:21 -0400 > > > >Hello, > > > >How do you find the id of the source from the message? > >It is possible that you are getting the wrong id. > >A not so good way is to have each node send a data message containing > >its own id. i.e. set the AppCounterAttr to > >((DiffusionRouting*)dr_)->getNodeId(). Assuming you are using the > >sample ping application that comes with diffusion, you can find the id > >of the source by reading the data message in TPPPingReceiverApp::recv > >Hope this helps. > > > >Shruti > > > >On 8/15/05, Îâ ê» wrote: > > > Hi, > > > I am using diffusion 3.2.0 in ns-2. One-Phase-Pull algorithm was > chosen. In > > > my simulation exist 100 nodes, 1 sink and 99 sources. The trace file I > got > > > made analysis tough. I want to know how many data messages sent by a > source > > > have been received by sink. The following is my way: on sink node, > counter > > > the number of the data messages which has the same id as sent by a > source. > > > But I found sink node just received a small amount of data messages. I > > > think because of the aggregation of other nodes. But from trace file, I > > > can't know which nodes has aggregated a data message reaching it. Do I > have > > > to change trace file of ns-2? > > > thanks > > > > > > > > > > > > From czy at pact518.hit.edu.cn Wed Aug 17 06:16:41 2005 From: czy at pact518.hit.edu.cn (czy@pact518.hit.edu.cn) Date: Wed, 17 Aug 2005 21:16:41 +0800 Subject: [Diffusion-users] About the trace format? Message-ID: <20050817131641.29679.qmail@pact518.hit.edu.cn> Hi, I'm using the diffusion3 in ns2. The trace format does not contain inforamtion about the DATA or INTEREST. How to statistic the number of the DATA message gathered by the sink. I changed tools.hh #ifdef NS_DIFFUSION #define DEBUG_DEFAULT 10 #else #define DEBUG_DEFAULT 1 #endif // NS_DIFFUSION after remake, ns simple-diffusion.tcl but, no information were printed in screen. Can anyone help me to resolve it? Or teach me how to statistic the inforamtion. Thanks. From shruti.beohar at gmail.com Wed Aug 17 07:46:43 2005 From: shruti.beohar at gmail.com (Shruti Beohar) Date: Wed, 17 Aug 2005 10:46:43 -0400 Subject: [Diffusion-users] trace format of diffusion In-Reply-To: References: <566ac03f050816150510dc1f28@mail.gmail.com> Message-ID: <566ac03f0508170746686b1d4c@mail.gmail.com> Hi, There are two files in apps/ping - 2pp_ping_sender.cc and 2pp_ping_receiver.cc. They correspond to the source and sink applications respectively. Study these two carefully and you will understand whats going on. In 2pp_ping_sender.cc, last_seq_sent_ is being sent as a data message by the source application. Change this value in the function : TPPPingSenderApp::send() to ((DiffusionRouting*)dr_)->getNodeId() That way each source node will send its own id as a data message. In the sink application, 2pp_ping_receiver.cc, check for the data message received by the sink in the function, TPPPingReceiverApp::recv(). Here you can check for the data value and find the node which sent them. After you do these changes, you need to "make" ns again. Type "make" at your/ns directory/ns-2.28/. Run diffusion again to see your changes. Hope this helps. Shruti On 8/16/05, Îâ ê» wrote: > Hi, > Thanx.In which file should I change > ((DiffusionRouting*)dr_)->getNodeId().how do I compile the file after I > have changed? > regards > hao wu > > >From: Shruti Beohar > >To: diffusion-users at ISI.EDU > >Subject: Re: [Diffusion-users] trace format of diffusion > >Date: Tue, 16 Aug 2005 18:05:49 -0400 > > > >Hi, > > > >I haven't looked much at trace files, I worked with the DiffPrint > messages. > >Yeah, make the changes and run the ping application again. > > > > > >On 8/16/05, Îâ ê» wrote: > > > Hi, > > > The trace file has following format: > > > s 0.000001000 _0_ AGT --- 30504276 diffusion 0 [0 0 0 0] ------- > [0:254 > > > 0:255 32 0] > > > r 0.000001000 _0_ RTR --- 30504276 diffusion 0 [0 0 0 0] ------- > [0:254 > > > 0:255 32 0] > > > s 0.000001000 _1_ AGT --- 503803425 diffusion 0 [0 0 0 0] ------- > [1:254 > > > 1:255 32 0] > > > r 0.000001000 _1_ RTR --- 503803425 diffusion 0 [0 0 0 0] ------- > [1:254 > > > 1:255 32 0] > > > s 0.000001000 _2_ AGT --- 1374534831 diffusion 0 [0 0 0 0] ------- > [2:254 > > > 2:255 32 0] > > > r 0.000001000 _2_ RTR --- 1374534831 diffusion 0 [0 0 0 0] ------- > [2:254 > > > 2:255 32 0] > > > s 0.010001000 _1_ AGT --- 503803426 diffusion 0 [0 0 0 0] ------- > [1:254 > > > 1:255 32 0] > > > r 0.010001000 _1_ RTR --- 503803426 diffusion 0 [0 0 0 0] ------- > [1:254 > > > 1:255 32 0] > > > s 0.010001000 _2_ AGT --- 1374534832 diffusion 0 [0 0 0 0] ------- > [2:254 > > > 2:255 32 0] > > > r 0.010001000 _2_ RTR --- 1374534832 diffusion 0 [0 0 0 0] ------- > [2:254 > > > 2:255 32 0] > > > r 0.010002000 _1_ AGT --- 672080287 diffusion 0 [0 0 0 0] ------- > [1:255 > > > 1:254 32 0] > > > r 0.010002000 _2_ AGT --- 352499576 diffusion 0 [0 0 0 0] ------- > [2:255 > > > 2:254 32 0] > > > s 0.110001000 _0_ AGT --- 30504277 diffusion 0 [0 0 0 0] ------- > [0:254 > > > 0:255 32 0] > > > r 0.110001000 _0_ RTR --- 30504277 diffusion 0 [0 0 0 0] ------- > [0:254 > > > 0:255 32 0] > > > r 0.110002000 _0_ AGT --- 729236 diffusion 0 [0 0 0 0] ------- [0:255 > > > 0:254 32 0] > > > s 0.219003000 _0_ AGT --- 30504278 diffusion 0 [0 0 0 0] ------- > [0:254 > > > 0:255 32 0] > > > r 0.219003000 _0_ RTR --- 30504278 diffusion 0 [0 0 0 0] ------- > [0:254 > > > 0:255 32 0] > > > ..... > > > I think 503803425 is the packet id sent by node 1, so I check if node 0 > has > > > received a packet whose id is 503803425. By this way I judge from which > > > source the packet came. > > > I can't understand your way.Do you mean I execute directly C++ code of > > > diffusion after I have changed the code as you told? > > > > > > > > > > > > > > > >From: Shruti Beohar > > > >To: Îâ ê» > > > >CC: diffusion-users at isi.edu > > > >Subject: Re: [Diffusion-users] trace format of diffusion > > > >Date: Mon, 15 Aug 2005 23:14:21 -0400 > > > > > > > >Hello, > > > > > > > >How do you find the id of the source from the message? > > > >It is possible that you are getting the wrong id. > > > >A not so good way is to have each node send a data message containing > > > >its own id. i.e. set the AppCounterAttr to > > > >((DiffusionRouting*)dr_)->getNodeId(). Assuming you are using the > > > >sample ping application that comes with diffusion, you can find the id > > > >of the source by reading the data message in TPPPingReceiverApp::recv > > > >Hope this helps. > > > > > > > >Shruti > > > > > > > >On 8/15/05, Îâ ê» wrote: > > > > > Hi, > > > > > I am using diffusion 3.2.0 in ns-2. One-Phase-Pull algorithm was > > > chosen. In > > > > > my simulation exist 100 nodes, 1 sink and 99 sources. The trace > file I > > > got > > > > > made analysis tough. I want to know how many data messages sent by > a > > > source > > > > > have been received by sink. The following is my way: on sink node, > > > counter > > > > > the number of the data messages which has the same id as sent by a > > > source. > > > > > But I found sink node just received a small amount of data > messages. I > > > > > think because of the aggregation of other nodes. But from trace > file, I > > > > > can't know which nodes has aggregated a data message reaching it. > Do I > > > have > > > > > to change trace file of ns-2? > > > > > thanks > > > > > > > > > > > > > > > > > > > > > > > > > > >