Ask is moving to Stack Overflow and Serverfault.com! Please use the "opendaylight" tag on either of these sites. This site is now in Read-Only mode

0

How to clear this warning fail to decode the packet.

asked 2015-02-02 02:12:02 -0800

jayakeerthi gravatar image

when there is no match for flow entry then it is given to the controller to handle it. there i'm facing this problem.

2015-02-02 14:23:03.822 IST [SwitchEvent Thread] WARN o.o.c.s.i.internal.DataPacketService - Failed to decode packet: null 2015-02-02 14:23:03.823 IST [SwitchEvent Thread] WARN o.o.c.s.i.internal.DataPacketService - Failed to decode packet: null 2015-02-02 14:23:03.824 IST [SwitchEvent Thread] WARN o.o.c.s.i.internal.DataPacketService - Failed to decode packet: null

edit retag flag offensive close merge delete

Comments

Did you try to print the incoming packet ?? Is it coming to your method ? And did you implement DataPacketService i.e SetDataPacketService and UnsetDataPacketService ?

faizan ( 2015-02-02 03:36:09 -0800 )edit

i tried to print the incoming packet in the other module but it is failing in the o.o.c.s.i.internal.DataPacketService where i didn't made any changes to the code. DataPacketService i.e SetDataPacketService and UnsetDataPacketService are implemented.

jayakeerthi ( 2015-02-02 03:44:17 -0800 )edit

following is my code snippet but is under another module but error is in another module. public class packetinfo implements IListenDataPacket { private IDataPacketService dataPacketService; void setDataPacketService(IDataPacketService s) { this.dataPacketService = s; } void unsetDataPacketService(IDataPacketService s) { if (this.dataPacketService == s) { this.dataPacketService = null; } } @Override public PacketResult receiveDataPacket(RawPacket inPkt) { if (inPkt == null) { return PacketResult.IGNORED; } Packet formattedPak = this.dataPacketService.decodeDataPacket(inPkt); System.out.println("packet System.out.println(formattedPak"); if (formattedPak instanceof Ethernet) { System.out.println(formattedPak); Object nextPak = formattedPak.getPayload(); if (nextPak instanceof IPv4) { IPv4 ipPak = (IPv4) nextPak;

jayakeerthi ( 2015-02-02 06:16:10 -0800 )edit

yes i added

jayakeerthi ( 2015-02-02 06:58:25 -0800 )edit

// Need these two methods to hook into the data path service // They are called from the activator void setDataPacketService(IDataPacketService s) { this.dataPacketService = s; } void unsetDataPacketService(IDataPacketService s) { if (this.dataPacketService == s) { this.dataPacketService = null; } } void setSwitchManager(ISwitchManager s) { log.debug("SwitchManager set"); this.switchManager = s; } void unsetSwitchManager(ISwitchManager s) { if (this.switchManager == s) { log.debug("SwitchManager removed!"); this.switchManager = null; } }

faizan ( 2015-02-02 07:18:36 -0800 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2015-02-13 08:22:00 -0800

faizan gravatar image

@jayakeerthi : What i understand is that you are building simpleforwarding module after your some changes into it, ryt ?? and when you paste the jar from target into plugins, you have two jar of same type. In this case do one thing, copy ur jar into plugins and rename it to the old one and remove the old jar. so thr will be only one jar with your changes. Also check its active by ss simpleforwardingon OSGi console. It should work.

else just rebuild your controller,it will build all the modules (mvn clean install) including simpleforwarding with your changes and creates all new set of jars into plugins. Hope this works :)

edit flag offensive delete publish link more

Comments

Hi created a new bundle which decodes the packets but it is not working . I can see the bundle active in the osgi console,

jayakeerthi ( 2015-02-13 20:25:47 -0800 )edit

It was working fine last time ? There might be so many reasons its not working, if your bundle is active on OSGi console, try see if Activator class is working by some prints or log, followed by calls reaching to the classes for example "YourDecoderClass" and your logics.

faizan ( 2015-02-13 21:03:40 -0800 )edit

i created new bundle... i added logs into the activator class of that bundle and it prints the logs when i lunch the controller.

jayakeerthi ( 2015-02-13 22:56:24 -0800 )edit

In that case something may be missing in your implementation of codes.

faizan ( 2015-02-13 23:08:24 -0800 )edit

when i decode the packets i can see some times the client/dest ports with '-' minus symbol some times. why it will so like this but in wireshark i can see different number which is positive. CLIENT_PORT -28239 DST_PORT 5672

jayakeerthi ( 2015-02-16 23:17:41 -0800 )edit
Login/Signup to Answer

Stats

Asked: 2015-02-02 02:12:02 -0800

Seen: 376 times

Last updated: Feb 13 '15