All of lore.kernel.org
 help / color / mirror / Atom feed
* Association issue.
@ 2013-07-30 11:34 Vipul Singhania
  2013-07-30 13:06 ` Neil Horman
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: Vipul Singhania @ 2013-07-30 11:34 UTC (permalink / raw)
  To: linux-sctp

Hi All,


I have one test case in which I have 2 interfaces on each machine (two hosts).

One is working as server and one is as client.

If in server I make one interface as public (IP address 164.x.x.x)
then the server sends reset to the client).

So question is does SCTP support association between public to private
range IP address?


Thanks in advance.
-- 
-=vipsy
http://through-dlens.blogspot.in

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
@ 2013-07-30 13:06 ` Neil Horman
  2013-07-31  5:15 ` Vipul Singhania
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Neil Horman @ 2013-07-30 13:06 UTC (permalink / raw)
  To: linux-sctp

On Tue, Jul 30, 2013 at 04:52:52PM +0530, Vipul Singhania wrote:
> Hi All,
> 
> 
> I have one test case in which I have 2 interfaces on each machine (two hosts).
> 
> One is working as server and one is as client.
> 
> If in server I make one interface as public (IP address 164.x.x.x)
> then the server sends reset to the client).
> 
> So question is does SCTP support association between public to private
> range IP address?
> 
Sort of, SCTP will gladly use any available ip address in the establishment of an
association.  That said, you do need to take care that your firewalls aren't
going to mess with those addresses. That is to say, if you have an address that
is 'private' in the sense that it is behind a nat firewall, you will likely get
a reset from the use of that address, because the peer will see connections from
that address as comming from the public natted address, which was not in the
association init chunk, hence the abort.
Neil

> 
> Thanks in advance.
> -- 
> -=vipsy
> http://through-dlens.blogspot.in
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sctp" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
  2013-07-30 13:06 ` Neil Horman
@ 2013-07-31  5:15 ` Vipul Singhania
  2013-07-31 13:11 ` Neil Horman
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Vipul Singhania @ 2013-07-31  5:15 UTC (permalink / raw)
  To: linux-sctp

Thanks for reply.

There is no firewall in that network. This is just separate network.
and I can say they are directly connected to each other using L1
switch and no other connection to outside world.

It was jut testing that I have giving public IP to one of interface in one host.

- The association look like with public IP.

sh-3.2# cat /proc/net/sctp/assocs
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
 0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
 7500   300   300   10    0    0        0
ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
 0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
 7500   300   300   10    0    0        0

-----------------------------------------------------------------------------
- But if I give private IP (10.1.1.1) this look like.

sh-3.2# cat /proc/net/sctp/assocs
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
 0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
   0    0        0
ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
 0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
   0    0        0


- I may be wrong but is it possible that when we do bind with on IP
(and if multi homing is enabled) it'll build with all available
interfaces?

Please forgive if I ask stupid question. First time I am doing network
programing and trying to learn this.


On Tue, Jul 30, 2013 at 6:36 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> On Tue, Jul 30, 2013 at 04:52:52PM +0530, Vipul Singhania wrote:
>> Hi All,
>>
>>
>> I have one test case in which I have 2 interfaces on each machine (two hosts).
>>
>> One is working as server and one is as client.
>>
>> If in server I make one interface as public (IP address 164.x.x.x)
>> then the server sends reset to the client).
>>
>> So question is does SCTP support association between public to private
>> range IP address?
>>
> Sort of, SCTP will gladly use any available ip address in the establishment of an
> association.  That said, you do need to take care that your firewalls aren't
> going to mess with those addresses. That is to say, if you have an address that
> is 'private' in the sense that it is behind a nat firewall, you will likely get
> a reset from the use of that address, because the peer will see connections from
> that address as comming from the public natted address, which was not in the
> association init chunk, hence the abort.
> Neil
>
>>
>> Thanks in advance.
>> --
>> -=vipsy
>> http://through-dlens.blogspot.in
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-sctp" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>



-- 
-=vipsy
http://through-dlens.blogspot.in

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
  2013-07-30 13:06 ` Neil Horman
  2013-07-31  5:15 ` Vipul Singhania
@ 2013-07-31 13:11 ` Neil Horman
  2013-07-31 13:36 ` Vlad Yasevich
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Neil Horman @ 2013-07-31 13:11 UTC (permalink / raw)
  To: linux-sctp

On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
> Thanks for reply.
> 
> There is no firewall in that network. This is just separate network.
> and I can say they are directly connected to each other using L1
> switch and no other connection to outside world.
> 
> It was jut testing that I have giving public IP to one of interface in one host.
> 
> - The association look like with public IP.
> 
> sh-3.2# cat /proc/net/sctp/assocs
>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>  7500   300   300   10    0    0        0
> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>  7500   300   300   10    0    0        0
> 
> -----------------------------------------------------------------------------
> - But if I give private IP (10.1.1.1) this look like.
> 
> sh-3.2# cat /proc/net/sctp/assocs
>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>    0    0        0
> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>    0    0        0
> 
I don't see any difference between the two environments here.  How exactly are
you 'giving' a private ip here?  Are you attempting an ADDIP operation?

> 
> - I may be wrong but is it possible that when we do bind with on IP
> (and if multi homing is enabled) it'll build with all available
> interfaces?
> 
The opposite in fact.  If you bind to a local address the association on that
socket will be creating using only the bound address, if you do not bind on a
local address (the autobind case), and multihoming is enabled, then all
available addresses will be used.

Neil


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (2 preceding siblings ...)
  2013-07-31 13:11 ` Neil Horman
@ 2013-07-31 13:36 ` Vlad Yasevich
  2013-08-01 10:34 ` Vipul Singhania
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Vlad Yasevich @ 2013-07-31 13:36 UTC (permalink / raw)
  To: linux-sctp

On 07/31/2013 01:03 AM, Vipul Singhania wrote:
> Thanks for reply.
>
> There is no firewall in that network. This is just separate network.
> and I can say they are directly connected to each other using L1
> switch and no other connection to outside world.
>
> It was jut testing that I have giving public IP to one of interface in one host.
>
> - The association look like with public IP.
>
> sh-3.2# cat /proc/net/sctp/assocs
>   ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
>   0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>   7500   300   300   10    0    0        0
> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
>   0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>   7500   300   300   10    0    0        0
>
> -----------------------------------------------------------------------------
> - But if I give private IP (10.1.1.1) this look like.
>
> sh-3.2# cat /proc/net/sctp/assocs
>   ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
>   0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>     0    0        0
> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
>   0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>     0    0        0
>
>
> - I may be wrong but is it possible that when we do bind with on IP
> (and if multi homing is enabled) it'll build with all available
> interfaces?

Try this test after you do:
	echo "2" > /proc/sys/net/sctp/addr_scope_policy

The default policy will not use private addresses if global ones are 
available.

-vlad

>
> Please forgive if I ask stupid question. First time I am doing network
> programing and trying to learn this.
>
>
> On Tue, Jul 30, 2013 at 6:36 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
>> On Tue, Jul 30, 2013 at 04:52:52PM +0530, Vipul Singhania wrote:
>>> Hi All,
>>>
>>>
>>> I have one test case in which I have 2 interfaces on each machine (two hosts).
>>>
>>> One is working as server and one is as client.
>>>
>>> If in server I make one interface as public (IP address 164.x.x.x)
>>> then the server sends reset to the client).
>>>
>>> So question is does SCTP support association between public to private
>>> range IP address?
>>>
>> Sort of, SCTP will gladly use any available ip address in the establishment of an
>> association.  That said, you do need to take care that your firewalls aren't
>> going to mess with those addresses. That is to say, if you have an address that
>> is 'private' in the sense that it is behind a nat firewall, you will likely get
>> a reset from the use of that address, because the peer will see connections from
>> that address as comming from the public natted address, which was not in the
>> association init chunk, hence the abort.
>> Neil
>>
>>>
>>> Thanks in advance.
>>> --
>>> -=vipsy
>>> http://through-dlens.blogspot.in
>>> --
>>> To unsubscribe from this list: send the line "unsubscribe linux-sctp" in
>>> the body of a message to majordomo@vger.kernel.org
>>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>>
>
>
>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (3 preceding siblings ...)
  2013-07-31 13:36 ` Vlad Yasevich
@ 2013-08-01 10:34 ` Vipul Singhania
  2013-08-01 11:48 ` Neil Horman
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Vipul Singhania @ 2013-08-01 10:34 UTC (permalink / raw)
  To: linux-sctp

On Wed, Jul 31, 2013 at 6:41 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
>> Thanks for reply.
>>
>> There is no firewall in that network. This is just separate network.
>> and I can say they are directly connected to each other using L1
>> switch and no other connection to outside world.
>>
>> It was jut testing that I have giving public IP to one of interface in one host.
>>
>> - The association look like with public IP.
>>
>> sh-3.2# cat /proc/net/sctp/assocs
>>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
>> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
>> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
>>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
>> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>>  7500   300   300   10    0    0        0
>> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
>>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
>> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>>  7500   300   300   10    0    0        0
>>
>> -----------------------------------------------------------------------------
>> - But if I give private IP (10.1.1.1) this look like.
>>
>> sh-3.2# cat /proc/net/sctp/assocs
>>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
>> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
>> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
>>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
>> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>>    0    0        0
>> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
>>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
>> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>>    0    0        0
>>
> I don't see any difference between the two environments here.  How exactly are
> you 'giving' a private ip here?  Are you attempting an ADDIP operation?
>

[Vipul] -- The difference which I can is the public IP 164.48.1.1 is
there in association list. (Why & how this case in this list this I am
not able to understand). however If I assign the IP 10.1.1.1/24 to my
eth0 it doesn't come in this association.
The IP address assignment is using ifconfig.

>>
>> - I may be wrong but is it possible that when we do bind with on IP
>> (and if multi homing is enabled) it'll build with all available
>> interfaces?
>>
> The opposite in fact.  If you bind to a local address the association on that
> socket will be creating using only the bound address, if you do not bind on a
> local address (the autobind case), and multihoming is enabled, then all
> available addresses will be used.
>
[Vipul] -- If this is the case one host is working as server and I am
doing bind on that for IP 127.4.252.1 and the other host is always
acting as client and in this I just do connect().
So Client will bind with all IP addresses, in this case I am not clear
why & how private IP is not coming for the accociation and why public
IP is coming in this association?
I have also tries with "echo "2" >
/proc/sys/net/sctp/addr_scope_policy" which even doesn't allow the
association with private IP. for both (private & public IP) the server
receiver end receives the connection reset by peer.

> Neil
>


-- 
-=vipsy
http://through-dlens.blogspot.in

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (4 preceding siblings ...)
  2013-08-01 10:34 ` Vipul Singhania
@ 2013-08-01 11:48 ` Neil Horman
  2013-08-02 13:00 ` Neil Horman
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Neil Horman @ 2013-08-01 11:48 UTC (permalink / raw)
  To: linux-sctp

On Thu, Aug 01, 2013 at 03:52:50PM +0530, Vipul Singhania wrote:
> On Wed, Jul 31, 2013 at 6:41 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> > On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
> >> Thanks for reply.
> >>
> >> There is no firewall in that network. This is just separate network.
> >> and I can say they are directly connected to each other using L1
> >> switch and no other connection to outside world.
> >>
> >> It was jut testing that I have giving public IP to one of interface in one host.
> >>
> >> - The association look like with public IP.
> >>
> >> sh-3.2# cat /proc/net/sctp/assocs
> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> >> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
> >>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
> >>  7500   300   300   10    0    0        0
> >> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
> >>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
> >>  7500   300   300   10    0    0        0
> >>
> >> -----------------------------------------------------------------------------
> >> - But if I give private IP (10.1.1.1) this look like.
> >>
> >> sh-3.2# cat /proc/net/sctp/assocs
> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> >> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
> >>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
> >>    0    0        0
> >> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
> >>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
> >>    0    0        0
> >>
> > I don't see any difference between the two environments here.  How exactly are
> > you 'giving' a private ip here?  Are you attempting an ADDIP operation?
> >
> 
> [Vipul] -- The difference which I can is the public IP 164.48.1.1 is
> there in association list. (Why & how this case in this list this I am
> not able to understand). however If I assign the IP 10.1.1.1/24 to my
> eth0 it doesn't come in this association.
> The IP address assignment is using ifconfig.
> 
Ok, so all your doing is specifying it on the interface, you're not explicitly
binding to it in whatever program you have.

> >>
> >> - I may be wrong but is it possible that when we do bind with on IP
> >> (and if multi homing is enabled) it'll build with all available
> >> interfaces?
> >>
> > The opposite in fact.  If you bind to a local address the association on that
> > socket will be creating using only the bound address, if you do not bind on a
> > local address (the autobind case), and multihoming is enabled, then all
> > available addresses will be used.
> >
> [Vipul] -- If this is the case one host is working as server and I am
> doing bind on that for IP 127.4.252.1 and the other host is always
> acting as client and in this I just do connect().
> So Client will bind with all IP addresses, in this case I am not clear
> why & how private IP is not coming for the accociation and why public
> IP is coming in this association?
Can you post the code that you are using to set up this connection?

> I have also tries with "echo "2" >
> /proc/sys/net/sctp/addr_scope_policy" which even doesn't allow the
> association with private IP. for both (private & public IP) the server
> receiver end receives the connection reset by peer.
> 
Can you provide a tcpdump of this as well?
Neil


> > Neil
> >
> 
> 
> -- 
> -=vipsy
> http://through-dlens.blogspot.in
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (5 preceding siblings ...)
  2013-08-01 11:48 ` Neil Horman
@ 2013-08-02 13:00 ` Neil Horman
  2013-08-02 17:32 ` Vipul Singhania
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: Neil Horman @ 2013-08-02 13:00 UTC (permalink / raw)
  To: linux-sctp

On Fri, Aug 02, 2013 at 02:24:07PM +0530, Vipul Singhania wrote:
> On Thu, Aug 1, 2013 at 5:18 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> > On Thu, Aug 01, 2013 at 03:52:50PM +0530, Vipul Singhania wrote:
> >> On Wed, Jul 31, 2013 at 6:41 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> >> > On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
> >> >> Thanks for reply.
> >> >>
> >> >> There is no firewall in that network. This is just separate network.
> >> >> and I can say they are directly connected to each other using L1
> >> >> switch and no other connection to outside world.
> >> >>
> >> >> It was jut testing that I have giving public IP to one of interface in one host.
> >> >>
> >> >> - The association look like with public IP.
> >> >>
> >> >> sh-3.2# cat /proc/net/sctp/assocs
> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> >> >> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
> >> >>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
> >> >>  7500   300   300   10    0    0        0
> >> >> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
> >> >>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
> >> >>  7500   300   300   10    0    0        0
> >> >>
> >> >> -----------------------------------------------------------------------------
> >> >> - But if I give private IP (10.1.1.1) this look like.
> >> >>
> >> >> sh-3.2# cat /proc/net/sctp/assocs
> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> >> >> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
> >> >>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
> >> >>    0    0        0
> >> >> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
> >> >>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
> >> >>    0    0        0
> >> >>
> >> > I don't see any difference between the two environments here.  How exactly are
> >> > you 'giving' a private ip here?  Are you attempting an ADDIP operation?
> >> >
> >>
> >> [Vipul] -- The difference which I can is the public IP 164.48.1.1 is
> >> there in association list. (Why & how this case in this list this I am
> >> not able to understand). however If I assign the IP 10.1.1.1/24 to my
> >> eth0 it doesn't come in this association.
> >> The IP address assignment is using ifconfig.
> >>
> > Ok, so all your doing is specifying it on the interface, you're not explicitly
> > binding to it in whatever program you have.
> >
> 
> [vipul] - Yes, At client side I am not doing explicitly bind.
> 
> >> >>
> >> >> - I may be wrong but is it possible that when we do bind with on IP
> >> >> (and if multi homing is enabled) it'll build with all available
> >> >> interfaces?
> >> >>
> >> > The opposite in fact.  If you bind to a local address the association on that
> >> > socket will be creating using only the bound address, if you do not bind on a
> >> > local address (the autobind case), and multihoming is enabled, then all
> >> > available addresses will be used.
> >> >
> >> [Vipul] -- If this is the case one host is working as server and I am
> >> doing bind on that for IP 127.4.252.1 and the other host is always
> >> acting as client and in this I just do connect().
> >> So Client will bind with all IP addresses, in this case I am not clear
> >> why & how private IP is not coming for the accociation and why public
> >> IP is coming in this association?
> > Can you post the code that you are using to set up this connection?
> >
> ******
> #define SERVER_IP "127.4.252.1"
> #define CLIENT_IP "127.4.253.1"
> 
> socklen_t optlen = sizeof (optval);
> struct sctp_event_subscribe   events ;
> ..
> ..
>  start_socket:
> 
>  tSoc = -1 ;
>  lSoc = -1 ; /* intialize the socket description */
>     if (  (lSoc = socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP)) < 0 ) {
>          //error handling.
>          return ;
>     }
> ...
> ...
> 
>  /* Specify the peer end point for connection */
>      servaddr.sin_family = AF_INET;
>      servaddr.sin_port = htons(7169);
>      inet_aton(SERVER_IP, &servaddr.sin_addr);
> 
>      optval = 0;
>      if (setsockopt(lSoc, SOL_SOCKET, SO_KEEPALIVE, &optval, optlen) < 0) {
>          //error handling.
>      }
> 
>      /* set to re-use to avoid "Address in use" on retry */
>      optval = 1;
>      if(setsockopt(lSoc, SOL_SOCKET, SO_REUSEADDR, &optval, optlen) < 0) {
>          //error handling.
>      }
> 
> 
> ....
> ....
> 
>     /* bind the server address in keep listening */
>      if (0 != bind(lSoc, (struct sockaddr *)&servaddr, sizeof(sockaddr))) {
>     // error handling.
>              close(lSoc);
>              sleep(2);
>              goto start_socket;
>      }
> 
>     if (listen(lSoc,5) = -1) {
>         close(lSoc);
>         sleep(2);
>         goto start_socket ; /* close the current connection and wait for new */
>     }
> ...
> ...
> 
>      /* SCTP Events noticiation to listen */
>      bzero(&events,sizeof(events));
>      events.sctp_data_io_event = 1;
>      events.sctp_association_event = 1;
>      events.sctp_address_event = 1;
>      events.sctp_send_failure_event = 1;
>      events.sctp_peer_error_event = 1;
>      events.sctp_shutdown_event = 1;
>      if(setsockopt(lSoc,IPPROTO_SCTP,SCTP_EVENTS,&events,sizeof(events)) < 0) {
>          // Error handling.
>      }
> ...
> ...
> 
>     while (1) {
>     start:
>     if (server) { //server case
>         if((tSoc = accept (lSoc, NULL, 0))  = -1 ) {
>         //Error handle
>         sleep(2) ;
>                 goto start ;
>             }
>     } else {  // client case
>         if ((connect(lSoc, (struct sockaddr *)&servaddr,
> sizeof(sockaddr))) != 0) {
>             //Error Handling
>                }
>         }
> 
>    }
> 
> ...
> ...
> after that when I do
> 
>    if((len = recvmsg(tSoc, msg, MSG_NOSIGNAL)) > 0) {
>     // Some operation.
>    } /* if (len > 0) */
> 
>    if (len  < 0) {
>     if (getsockopt(tSoc, IPPROTO_SCTP,SCTP_STATUS, &status, &socklen) = -1) {
>         HERE I GET CONNECTION RESET BY PEER
>     }
>    }
> ************************************
> 
> I have following default setting related to sctp.
> 
> h-3.2# sysctl -a |grep sctp
> net.sctp.rto_initial = 3000
> net.sctp.rto_min = 1000
> net.sctp.rto_max = 60000
> net.sctp.valid_cookie_life = 600000
> net.sctp.max_burst = 4
> net.sctp.association_max_retrans = 10
> net.sctp.sndbuf_policy = 0
> net.sctp.rcvbuf_policy = 0
> net.sctp.path_max_retrans = 5
> net.sctp.max_init_retransmits = 8
> net.sctp.hb_interval = 30000
> net.sctp.cookie_preserve_enable = 1
> net.sctp.rto_alpha_exp_divisor = 3
> net.sctp.rto_beta_exp_divisor = 2
> net.sctp.addip_enable = 0
> net.sctp.prsctp_enable = 1
> net.sctp.sack_timeout = 200
> net.sctp.sctp_mem = 36171    48230    72342
> net.sctp.sctp_rmem = 4096    397500    1543360
> net.sctp.sctp_wmem = 4096    16384    1543360
> net.sctp.auth_enable = 0
> net.sctp.addip_noauth_enable = 0
> net.sctp.addr_scope_policy = 1
> net.sctp.rwnd_update_shift = 4
> net.sctp.max_autoclose = 8589934
> sh-3.2#
> 
> ********
> Attaching two pcap files.
> 
> 1. Client_localIP.pcap ---> In this file local IP (10.1.1.1) is not in
> association.
> 2, Client_publicIP.pcap. ---> in this 164.48.1.1 is part of association.
> 
> 
> 
> >> I have also tries with "echo "2" >
> >> /proc/sys/net/sctp/addr_scope_policy" which even doesn't allow the
> >> association with private IP. for both (private & public IP) the server
> >> receiver end receives the connection reset by peer.
> >>
> > Can you provide a tcpdump of this as well?
> > Neil
> >
> >
> >> > Neil
> >> >
> >>
> >>
> >> --
> >> -=vipsy
> >> http://through-dlens.blogspot.in
> >>
> 
So, I'm somewhat confused here.  I've looked at both the tcpdumps you provided
and both traces show that ABORT chunks are generated, the exact same ABORT
chunks.

So I'm left wondering why you think one environment works and the other
doesn't (unless neither environment works and I just misunderstood you
previously).

FWIW, the ABORT chunks have no causal data, which suggests they are either the
result of the reception of an out of the blue packet, a t5 timer expiration or
an init verification failure (I would guess the latter).  What does
/proc/net/sctp/snmp show after you get the aborts?

Neil

> 
> 
> -- 
> -=vipsy
> http://through-dlens.blogspot.in



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (6 preceding siblings ...)
  2013-08-02 13:00 ` Neil Horman
@ 2013-08-02 17:32 ` Vipul Singhania
  2013-08-02 20:05 ` Neil Horman
  2013-08-05  6:53 ` Vipul Singhania
  9 siblings, 0 replies; 11+ messages in thread
From: Vipul Singhania @ 2013-08-02 17:32 UTC (permalink / raw)
  To: linux-sctp

On Fri, Aug 2, 2013 at 6:30 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> On Fri, Aug 02, 2013 at 02:24:07PM +0530, Vipul Singhania wrote:
>> On Thu, Aug 1, 2013 at 5:18 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
>> > On Thu, Aug 01, 2013 at 03:52:50PM +0530, Vipul Singhania wrote:
>> >> On Wed, Jul 31, 2013 at 6:41 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
>> >> > On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
>> >> >> Thanks for reply.
>> >> >>
>> >> >> There is no firewall in that network. This is just separate network.
>> >> >> and I can say they are directly connected to each other using L1
>> >> >> switch and no other connection to outside world.
>> >> >>
>> >> >> It was jut testing that I have giving public IP to one of interface in one host.
>> >> >>
>> >> >> - The association look like with public IP.
>> >> >>
>> >> >> sh-3.2# cat /proc/net/sctp/assocs
>> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
>> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
>> >> >> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
>> >> >>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>> >> >>  7500   300   300   10    0    0        0
>> >> >> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
>> >> >>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>> >> >>  7500   300   300   10    0    0        0
>> >> >>
>> >> >> -----------------------------------------------------------------------------
>> >> >> - But if I give private IP (10.1.1.1) this look like.
>> >> >>
>> >> >> sh-3.2# cat /proc/net/sctp/assocs
>> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
>> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
>> >> >> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
>> >> >>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>> >> >>    0    0        0
>> >> >> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
>> >> >>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>> >> >>    0    0        0
>> >> >>
>> >> > I don't see any difference between the two environments here.  How exactly are
>> >> > you 'giving' a private ip here?  Are you attempting an ADDIP operation?
>> >> >
>> >>
>> >> [Vipul] -- The difference which I can is the public IP 164.48.1.1 is
>> >> there in association list. (Why & how this case in this list this I am
>> >> not able to understand). however If I assign the IP 10.1.1.1/24 to my
>> >> eth0 it doesn't come in this association.
>> >> The IP address assignment is using ifconfig.
>> >>
>> > Ok, so all your doing is specifying it on the interface, you're not explicitly
>> > binding to it in whatever program you have.
>> >
>>
>> [vipul] - Yes, At client side I am not doing explicitly bind.
>>
>> >> >>
>> >> >> - I may be wrong but is it possible that when we do bind with on IP
>> >> >> (and if multi homing is enabled) it'll build with all available
>> >> >> interfaces?
>> >> >>
>> >> > The opposite in fact.  If you bind to a local address the association on that
>> >> > socket will be creating using only the bound address, if you do not bind on a
>> >> > local address (the autobind case), and multihoming is enabled, then all
>> >> > available addresses will be used.
>> >> >
>> >> [Vipul] -- If this is the case one host is working as server and I am
>> >> doing bind on that for IP 127.4.252.1 and the other host is always
>> >> acting as client and in this I just do connect().
>> >> So Client will bind with all IP addresses, in this case I am not clear
>> >> why & how private IP is not coming for the accociation and why public
>> >> IP is coming in this association?
>> > Can you post the code that you are using to set up this connection?
>> >
>> ******
>> #define SERVER_IP "127.4.252.1"
>> #define CLIENT_IP "127.4.253.1"
>>
>> socklen_t optlen = sizeof (optval);
>> struct sctp_event_subscribe   events ;
>> ..
>> ..
>>  start_socket:
>>
>>  tSoc = -1 ;
>>  lSoc = -1 ; /* intialize the socket description */
>>     if (  (lSoc = socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP)) < 0 ) {
>>          //error handling.
>>          return ;
>>     }
>> ...
>> ...
>>
>>  /* Specify the peer end point for connection */
>>      servaddr.sin_family = AF_INET;
>>      servaddr.sin_port = htons(7169);
>>      inet_aton(SERVER_IP, &servaddr.sin_addr);
>>
>>      optval = 0;
>>      if (setsockopt(lSoc, SOL_SOCKET, SO_KEEPALIVE, &optval, optlen) < 0) {
>>          //error handling.
>>      }
>>
>>      /* set to re-use to avoid "Address in use" on retry */
>>      optval = 1;
>>      if(setsockopt(lSoc, SOL_SOCKET, SO_REUSEADDR, &optval, optlen) < 0) {
>>          //error handling.
>>      }
>>
>>
>> ....
>> ....
>>
>>     /* bind the server address in keep listening */
>>      if (0 != bind(lSoc, (struct sockaddr *)&servaddr, sizeof(sockaddr))) {
>>     // error handling.
>>              close(lSoc);
>>              sleep(2);
>>              goto start_socket;
>>      }
>>
>>     if (listen(lSoc,5) = -1) {
>>         close(lSoc);
>>         sleep(2);
>>         goto start_socket ; /* close the current connection and wait for new */
>>     }
>> ...
>> ...
>>
>>      /* SCTP Events noticiation to listen */
>>      bzero(&events,sizeof(events));
>>      events.sctp_data_io_event = 1;
>>      events.sctp_association_event = 1;
>>      events.sctp_address_event = 1;
>>      events.sctp_send_failure_event = 1;
>>      events.sctp_peer_error_event = 1;
>>      events.sctp_shutdown_event = 1;
>>      if(setsockopt(lSoc,IPPROTO_SCTP,SCTP_EVENTS,&events,sizeof(events)) < 0) {
>>          // Error handling.
>>      }
>> ...
>> ...
>>
>>     while (1) {
>>     start:
>>     if (server) { //server case
>>         if((tSoc = accept (lSoc, NULL, 0))  = -1 ) {
>>         //Error handle
>>         sleep(2) ;
>>                 goto start ;
>>             }
>>     } else {  // client case
>>         if ((connect(lSoc, (struct sockaddr *)&servaddr,
>> sizeof(sockaddr))) != 0) {
>>             //Error Handling
>>                }
>>         }
>>
>>    }
>>
>> ...
>> ...
>> after that when I do
>>
>>    if((len = recvmsg(tSoc, msg, MSG_NOSIGNAL)) > 0) {
>>     // Some operation.
>>    } /* if (len > 0) */
>>
>>    if (len  < 0) {
>>     if (getsockopt(tSoc, IPPROTO_SCTP,SCTP_STATUS, &status, &socklen) = -1) {
>>         HERE I GET CONNECTION RESET BY PEER
>>     }
>>    }
>> ************************************
>>
>> I have following default setting related to sctp.
>>
>> h-3.2# sysctl -a |grep sctp
>> net.sctp.rto_initial = 3000
>> net.sctp.rto_min = 1000
>> net.sctp.rto_max = 60000
>> net.sctp.valid_cookie_life = 600000
>> net.sctp.max_burst = 4
>> net.sctp.association_max_retrans = 10
>> net.sctp.sndbuf_policy = 0
>> net.sctp.rcvbuf_policy = 0
>> net.sctp.path_max_retrans = 5
>> net.sctp.max_init_retransmits = 8
>> net.sctp.hb_interval = 30000
>> net.sctp.cookie_preserve_enable = 1
>> net.sctp.rto_alpha_exp_divisor = 3
>> net.sctp.rto_beta_exp_divisor = 2
>> net.sctp.addip_enable = 0
>> net.sctp.prsctp_enable = 1
>> net.sctp.sack_timeout = 200
>> net.sctp.sctp_mem = 36171    48230    72342
>> net.sctp.sctp_rmem = 4096    397500    1543360
>> net.sctp.sctp_wmem = 4096    16384    1543360
>> net.sctp.auth_enable = 0
>> net.sctp.addip_noauth_enable = 0
>> net.sctp.addr_scope_policy = 1
>> net.sctp.rwnd_update_shift = 4
>> net.sctp.max_autoclose = 8589934
>> sh-3.2#
>>
>> ********
>> Attaching two pcap files.
>>
>> 1. Client_localIP.pcap ---> In this file local IP (10.1.1.1) is not in
>> association.
>> 2, Client_publicIP.pcap. ---> in this 164.48.1.1 is part of association.
>>
>>
>>
>> >> I have also tries with "echo "2" >
>> >> /proc/sys/net/sctp/addr_scope_policy" which even doesn't allow the
>> >> association with private IP. for both (private & public IP) the server
>> >> receiver end receives the connection reset by peer.
>> >>
>> > Can you provide a tcpdump of this as well?
>> > Neil
>> >
>> >
>> >> > Neil
>> >> >
>> >>
>> >>
>> >> --
>> >> -=vipsy
>> >> http://through-dlens.blogspot.in
>> >>
>>
> So, I'm somewhat confused here.  I've looked at both the tcpdumps you provided
> and both traces show that ABORT chunks are generated, the exact same ABORT
> chunks.
>

[Vipul] -- Ohh I got your point. If you are looking at starting ABORT,
that time server was not running but once IT started there is not
ABORT in between, (Please forgave me I didn't explain this in my
previous mail). And if you look into capture with publicIP there are
continue ABORT in some interval. I don;t know why this ABORT after
some data transmission.


> So I'm left wondering why you think one environment works and the other
> doesn't (unless neither environment works and I just misunderstood you
> previously).
>
> FWIW, the ABORT chunks have no causal data, which suggests they are either the
> result of the reception of an out of the blue packet, a t5 timer expiration or
> an init verification failure (I would guess the latter).  What does
> /proc/net/sctp/snmp show after you get the aborts?
>
> Neil
>
>>

I used the Bind before connect to bind only one IP and this fixes the
issue. Now I cannot see multiple IP in association and no ABORT
PACKET.

I'll be able to update with snmp output after a while as I need revert
the code again to get this.

(If you think this is worth to discusses why ABORT is coming I'll
really like to continue this).

PS: Really thanks a lot to all team for helping me and guiding me.


>>
>> --
>> -=vipsy
>> http://through-dlens.blogspot.in
>
>



-- 
-=vipsy
http://through-dlens.blogspot.in

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (7 preceding siblings ...)
  2013-08-02 17:32 ` Vipul Singhania
@ 2013-08-02 20:05 ` Neil Horman
  2013-08-05  6:53 ` Vipul Singhania
  9 siblings, 0 replies; 11+ messages in thread
From: Neil Horman @ 2013-08-02 20:05 UTC (permalink / raw)
  To: linux-sctp

On Fri, Aug 02, 2013 at 10:50:44PM +0530, Vipul Singhania wrote:
> On Fri, Aug 2, 2013 at 6:30 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> > On Fri, Aug 02, 2013 at 02:24:07PM +0530, Vipul Singhania wrote:
> >> On Thu, Aug 1, 2013 at 5:18 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> >> > On Thu, Aug 01, 2013 at 03:52:50PM +0530, Vipul Singhania wrote:
> >> >> On Wed, Jul 31, 2013 at 6:41 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
> >> >> > On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
> >> >> >> Thanks for reply.
> >> >> >>
> >> >> >> There is no firewall in that network. This is just separate network.
> >> >> >> and I can say they are directly connected to each other using L1
> >> >> >> switch and no other connection to outside world.
> >> >> >>
> >> >> >> It was jut testing that I have giving public IP to one of interface in one host.
> >> >> >>
> >> >> >> - The association look like with public IP.
> >> >> >>
> >> >> >> sh-3.2# cat /proc/net/sctp/assocs
> >> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> >> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> >> >> >> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
> >> >> >>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
> >> >> >>  7500   300   300   10    0    0        0
> >> >> >> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
> >> >> >>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
> >> >> >>  7500   300   300   10    0    0        0
> >> >> >>
> >> >> >> -----------------------------------------------------------------------------
> >> >> >> - But if I give private IP (10.1.1.1) this look like.
> >> >> >>
> >> >> >> sh-3.2# cat /proc/net/sctp/assocs
> >> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
> >> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
> >> >> >> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
> >> >> >>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
> >> >> >>    0    0        0
> >> >> >> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
> >> >> >>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
> >> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
> >> >> >>    0    0        0
> >> >> >>
> >> >> > I don't see any difference between the two environments here.  How exactly are
> >> >> > you 'giving' a private ip here?  Are you attempting an ADDIP operation?
> >> >> >
> >> >>
> >> >> [Vipul] -- The difference which I can is the public IP 164.48.1.1 is
> >> >> there in association list. (Why & how this case in this list this I am
> >> >> not able to understand). however If I assign the IP 10.1.1.1/24 to my
> >> >> eth0 it doesn't come in this association.
> >> >> The IP address assignment is using ifconfig.
> >> >>
> >> > Ok, so all your doing is specifying it on the interface, you're not explicitly
> >> > binding to it in whatever program you have.
> >> >
> >>
> >> [vipul] - Yes, At client side I am not doing explicitly bind.
> >>
> >> >> >>
> >> >> >> - I may be wrong but is it possible that when we do bind with on IP
> >> >> >> (and if multi homing is enabled) it'll build with all available
> >> >> >> interfaces?
> >> >> >>
> >> >> > The opposite in fact.  If you bind to a local address the association on that
> >> >> > socket will be creating using only the bound address, if you do not bind on a
> >> >> > local address (the autobind case), and multihoming is enabled, then all
> >> >> > available addresses will be used.
> >> >> >
> >> >> [Vipul] -- If this is the case one host is working as server and I am
> >> >> doing bind on that for IP 127.4.252.1 and the other host is always
> >> >> acting as client and in this I just do connect().
> >> >> So Client will bind with all IP addresses, in this case I am not clear
> >> >> why & how private IP is not coming for the accociation and why public
> >> >> IP is coming in this association?
> >> > Can you post the code that you are using to set up this connection?
> >> >
> >> ******
> >> #define SERVER_IP "127.4.252.1"
> >> #define CLIENT_IP "127.4.253.1"
> >>
> >> socklen_t optlen = sizeof (optval);
> >> struct sctp_event_subscribe   events ;
> >> ..
> >> ..
> >>  start_socket:
> >>
> >>  tSoc = -1 ;
> >>  lSoc = -1 ; /* intialize the socket description */
> >>     if (  (lSoc = socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP)) < 0 ) {
> >>          //error handling.
> >>          return ;
> >>     }
> >> ...
> >> ...
> >>
> >>  /* Specify the peer end point for connection */
> >>      servaddr.sin_family = AF_INET;
> >>      servaddr.sin_port = htons(7169);
> >>      inet_aton(SERVER_IP, &servaddr.sin_addr);
> >>
> >>      optval = 0;
> >>      if (setsockopt(lSoc, SOL_SOCKET, SO_KEEPALIVE, &optval, optlen) < 0) {
> >>          //error handling.
> >>      }
> >>
> >>      /* set to re-use to avoid "Address in use" on retry */
> >>      optval = 1;
> >>      if(setsockopt(lSoc, SOL_SOCKET, SO_REUSEADDR, &optval, optlen) < 0) {
> >>          //error handling.
> >>      }
> >>
> >>
> >> ....
> >> ....
> >>
> >>     /* bind the server address in keep listening */
> >>      if (0 != bind(lSoc, (struct sockaddr *)&servaddr, sizeof(sockaddr))) {
> >>     // error handling.
> >>              close(lSoc);
> >>              sleep(2);
> >>              goto start_socket;
> >>      }
> >>
> >>     if (listen(lSoc,5) = -1) {
> >>         close(lSoc);
> >>         sleep(2);
> >>         goto start_socket ; /* close the current connection and wait for new */
> >>     }
> >> ...
> >> ...
> >>
> >>      /* SCTP Events noticiation to listen */
> >>      bzero(&events,sizeof(events));
> >>      events.sctp_data_io_event = 1;
> >>      events.sctp_association_event = 1;
> >>      events.sctp_address_event = 1;
> >>      events.sctp_send_failure_event = 1;
> >>      events.sctp_peer_error_event = 1;
> >>      events.sctp_shutdown_event = 1;
> >>      if(setsockopt(lSoc,IPPROTO_SCTP,SCTP_EVENTS,&events,sizeof(events)) < 0) {
> >>          // Error handling.
> >>      }
> >> ...
> >> ...
> >>
> >>     while (1) {
> >>     start:
> >>     if (server) { //server case
> >>         if((tSoc = accept (lSoc, NULL, 0))  = -1 ) {
> >>         //Error handle
> >>         sleep(2) ;
> >>                 goto start ;
> >>             }
> >>     } else {  // client case
> >>         if ((connect(lSoc, (struct sockaddr *)&servaddr,
> >> sizeof(sockaddr))) != 0) {
> >>             //Error Handling
> >>                }
> >>         }
> >>
> >>    }
> >>
> >> ...
> >> ...
> >> after that when I do
> >>
> >>    if((len = recvmsg(tSoc, msg, MSG_NOSIGNAL)) > 0) {
> >>     // Some operation.
> >>    } /* if (len > 0) */
> >>
> >>    if (len  < 0) {
> >>     if (getsockopt(tSoc, IPPROTO_SCTP,SCTP_STATUS, &status, &socklen) = -1) {
> >>         HERE I GET CONNECTION RESET BY PEER
> >>     }
> >>    }
> >> ************************************
> >>
> >> I have following default setting related to sctp.
> >>
> >> h-3.2# sysctl -a |grep sctp
> >> net.sctp.rto_initial = 3000
> >> net.sctp.rto_min = 1000
> >> net.sctp.rto_max = 60000
> >> net.sctp.valid_cookie_life = 600000
> >> net.sctp.max_burst = 4
> >> net.sctp.association_max_retrans = 10
> >> net.sctp.sndbuf_policy = 0
> >> net.sctp.rcvbuf_policy = 0
> >> net.sctp.path_max_retrans = 5
> >> net.sctp.max_init_retransmits = 8
> >> net.sctp.hb_interval = 30000
> >> net.sctp.cookie_preserve_enable = 1
> >> net.sctp.rto_alpha_exp_divisor = 3
> >> net.sctp.rto_beta_exp_divisor = 2
> >> net.sctp.addip_enable = 0
> >> net.sctp.prsctp_enable = 1
> >> net.sctp.sack_timeout = 200
> >> net.sctp.sctp_mem = 36171    48230    72342
> >> net.sctp.sctp_rmem = 4096    397500    1543360
> >> net.sctp.sctp_wmem = 4096    16384    1543360
> >> net.sctp.auth_enable = 0
> >> net.sctp.addip_noauth_enable = 0
> >> net.sctp.addr_scope_policy = 1
> >> net.sctp.rwnd_update_shift = 4
> >> net.sctp.max_autoclose = 8589934
> >> sh-3.2#
> >>
> >> ********
> >> Attaching two pcap files.
> >>
> >> 1. Client_localIP.pcap ---> In this file local IP (10.1.1.1) is not in
> >> association.
> >> 2, Client_publicIP.pcap. ---> in this 164.48.1.1 is part of association.
> >>
> >>
> >>
> >> >> I have also tries with "echo "2" >
> >> >> /proc/sys/net/sctp/addr_scope_policy" which even doesn't allow the
> >> >> association with private IP. for both (private & public IP) the server
> >> >> receiver end receives the connection reset by peer.
> >> >>
> >> > Can you provide a tcpdump of this as well?
> >> > Neil
> >> >
> >> >
> >> >> > Neil
> >> >> >
> >> >>
> >> >>
> >> >> --
> >> >> -=vipsy
> >> >> http://through-dlens.blogspot.in
> >> >>
> >>
> > So, I'm somewhat confused here.  I've looked at both the tcpdumps you provided
> > and both traces show that ABORT chunks are generated, the exact same ABORT
> > chunks.
> >
> 
> [Vipul] -- Ohh I got your point. If you are looking at starting ABORT,
> that time server was not running but once IT started there is not
> ABORT in between, (Please forgave me I didn't explain this in my
> previous mail). And if you look into capture with publicIP there are
> continue ABORT in some interval. I don;t know why this ABORT after
> some data transmission.
> 
Ah, ok, I still don't see a significant difference though.  You have have
identical INIT chunks in the client_localIP trace, some of which produce aborts,
some of which result in successful connections. I'm not sure what the difference
is, and neither of them contain your 168.* address in the init chunk (look at
frames 109-112 and 113-116 for comprative examples).  I would suggest looking at
the snmp stats on the peer, or just enable dynamic debugging in the sctp module
to get some clue as to whats going on here.


> 
> > So I'm left wondering why you think one environment works and the other
> > doesn't (unless neither environment works and I just misunderstood you
> > previously).
> >
> > FWIW, the ABORT chunks have no causal data, which suggests they are either the
> > result of the reception of an out of the blue packet, a t5 timer expiration or
> > an init verification failure (I would guess the latter).  What does
> > /proc/net/sctp/snmp show after you get the aborts?
> >
> > Neil
> >
> >>
> 
> I used the Bind before connect to bind only one IP and this fixes the
> issue. Now I cannot see multiple IP in association and no ABORT
> PACKET.
> 
> I'll be able to update with snmp output after a while as I need revert
> the code again to get this.
> 
> (If you think this is worth to discusses why ABORT is coming I'll
> really like to continue this).
> 
> PS: Really thanks a lot to all team for helping me and guiding me.
> 
Don't thank me yet, I'm going on vacation here for a week or so.
> 
> >>
> >> --
> >> -=vipsy
> >> http://through-dlens.blogspot.in
> >
> >
> 
> 
> 
> -- 
> -=vipsy
> http://through-dlens.blogspot.in
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Association issue.
  2013-07-30 11:34 Association issue Vipul Singhania
                   ` (8 preceding siblings ...)
  2013-08-02 20:05 ` Neil Horman
@ 2013-08-05  6:53 ` Vipul Singhania
  9 siblings, 0 replies; 11+ messages in thread
From: Vipul Singhania @ 2013-08-05  6:53 UTC (permalink / raw)
  To: linux-sctp

[-- Attachment #1: Type: text/plain, Size: 11767 bytes --]

I have attached one log file with assocs & snmp log out put in all
cases. (with pvt IP & with Public IP) for HOST A & HOST B.

On Sat, Aug 3, 2013 at 1:35 AM, Neil Horman <nhorman@tuxdriver.com> wrote:
> On Fri, Aug 02, 2013 at 10:50:44PM +0530, Vipul Singhania wrote:
>> On Fri, Aug 2, 2013 at 6:30 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
>> > On Fri, Aug 02, 2013 at 02:24:07PM +0530, Vipul Singhania wrote:
>> >> On Thu, Aug 1, 2013 at 5:18 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
>> >> > On Thu, Aug 01, 2013 at 03:52:50PM +0530, Vipul Singhania wrote:
>> >> >> On Wed, Jul 31, 2013 at 6:41 PM, Neil Horman <nhorman@tuxdriver.com> wrote:
>> >> >> > On Wed, Jul 31, 2013 at 10:33:50AM +0530, Vipul Singhania wrote:
>> >> >> >> Thanks for reply.
>> >> >> >>
>> >> >> >> There is no firewall in that network. This is just separate network.
>> >> >> >> and I can say they are directly connected to each other using L1
>> >> >> >> switch and no other connection to outside world.
>> >> >> >>
>> >> >> >> It was jut testing that I have giving public IP to one of interface in one host.
>> >> >> >>
>> >> >> >> - The association look like with public IP.
>> >> >> >>
>> >> >> >> sh-3.2# cat /proc/net/sctp/assocs
>> >> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
>> >> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
>> >> >> >> ffff8800089b0000 ffff8800335944c0 2   1   3  37916    3      516
>> >> >> >>  0       0 10635 48520  7168  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>> >> >> >>  7500   300   300   10    0    0        0
>> >> >> >> ffff8800089b2000 ffff880033594000 2   1   3  50717    4      516
>> >> >> >>  0       0 10634 60890  7169  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> >> 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1
>> >> >> >>  7500   300   300   10    0    0        0
>> >> >> >>
>> >> >> >> -----------------------------------------------------------------------------
>> >> >> >> - But if I give private IP (10.1.1.1) this look like.
>> >> >> >>
>> >> >> >> sh-3.2# cat /proc/net/sctp/assocs
>> >> >> >>  ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE
>> >> >> >> LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
>> >> >> >> ffff88003c721800 ffff8800335944c0 2   1   3  22045    2        0
>> >> >> >>  0       0  5674 47434  7169  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>> >> >> >>    0    0        0
>> >> >> >> ffff88003c720800 ffff880033594000 2   1   3  36124    1        0
>> >> >> >>  0       0  5673 58513  7168  127.3.253.1 127.3.21.1 127.4.253.1
>> >> >> >> 127.2.253.1 127.1.221.1 <-> *127.4.252.1         7500   300   300   10
>> >> >> >>    0    0        0
>> >> >> >>
>> >> >> > I don't see any difference between the two environments here.  How exactly are
>> >> >> > you 'giving' a private ip here?  Are you attempting an ADDIP operation?
>> >> >> >
>> >> >>
>> >> >> [Vipul] -- The difference which I can is the public IP 164.48.1.1 is
>> >> >> there in association list. (Why & how this case in this list this I am
>> >> >> not able to understand). however If I assign the IP 10.1.1.1/24 to my
>> >> >> eth0 it doesn't come in this association.
>> >> >> The IP address assignment is using ifconfig.
>> >> >>
>> >> > Ok, so all your doing is specifying it on the interface, you're not explicitly
>> >> > binding to it in whatever program you have.
>> >> >
>> >>
>> >> [vipul] - Yes, At client side I am not doing explicitly bind.
>> >>
>> >> >> >>
>> >> >> >> - I may be wrong but is it possible that when we do bind with on IP
>> >> >> >> (and if multi homing is enabled) it'll build with all available
>> >> >> >> interfaces?
>> >> >> >>
>> >> >> > The opposite in fact.  If you bind to a local address the association on that
>> >> >> > socket will be creating using only the bound address, if you do not bind on a
>> >> >> > local address (the autobind case), and multihoming is enabled, then all
>> >> >> > available addresses will be used.
>> >> >> >
>> >> >> [Vipul] -- If this is the case one host is working as server and I am
>> >> >> doing bind on that for IP 127.4.252.1 and the other host is always
>> >> >> acting as client and in this I just do connect().
>> >> >> So Client will bind with all IP addresses, in this case I am not clear
>> >> >> why & how private IP is not coming for the accociation and why public
>> >> >> IP is coming in this association?
>> >> > Can you post the code that you are using to set up this connection?
>> >> >
>> >> ******
>> >> #define SERVER_IP "127.4.252.1"
>> >> #define CLIENT_IP "127.4.253.1"
>> >>
>> >> socklen_t optlen = sizeof (optval);
>> >> struct sctp_event_subscribe   events ;
>> >> ..
>> >> ..
>> >>  start_socket:
>> >>
>> >>  tSoc = -1 ;
>> >>  lSoc = -1 ; /* intialize the socket description */
>> >>     if (  (lSoc = socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP)) < 0 ) {
>> >>          //error handling.
>> >>          return ;
>> >>     }
>> >> ...
>> >> ...
>> >>
>> >>  /* Specify the peer end point for connection */
>> >>      servaddr.sin_family = AF_INET;
>> >>      servaddr.sin_port = htons(7169);
>> >>      inet_aton(SERVER_IP, &servaddr.sin_addr);
>> >>
>> >>      optval = 0;
>> >>      if (setsockopt(lSoc, SOL_SOCKET, SO_KEEPALIVE, &optval, optlen) < 0) {
>> >>          //error handling.
>> >>      }
>> >>
>> >>      /* set to re-use to avoid "Address in use" on retry */
>> >>      optval = 1;
>> >>      if(setsockopt(lSoc, SOL_SOCKET, SO_REUSEADDR, &optval, optlen) < 0) {
>> >>          //error handling.
>> >>      }
>> >>
>> >>
>> >> ....
>> >> ....
>> >>
>> >>     /* bind the server address in keep listening */
>> >>      if (0 != bind(lSoc, (struct sockaddr *)&servaddr, sizeof(sockaddr))) {
>> >>     // error handling.
>> >>              close(lSoc);
>> >>              sleep(2);
>> >>              goto start_socket;
>> >>      }
>> >>
>> >>     if (listen(lSoc,5) == -1) {
>> >>         close(lSoc);
>> >>         sleep(2);
>> >>         goto start_socket ; /* close the current connection and wait for new */
>> >>     }
>> >> ...
>> >> ...
>> >>
>> >>      /* SCTP Events noticiation to listen */
>> >>      bzero(&events,sizeof(events));
>> >>      events.sctp_data_io_event = 1;
>> >>      events.sctp_association_event = 1;
>> >>      events.sctp_address_event = 1;
>> >>      events.sctp_send_failure_event = 1;
>> >>      events.sctp_peer_error_event = 1;
>> >>      events.sctp_shutdown_event = 1;
>> >>      if(setsockopt(lSoc,IPPROTO_SCTP,SCTP_EVENTS,&events,sizeof(events)) < 0) {
>> >>          // Error handling.
>> >>      }
>> >> ...
>> >> ...
>> >>
>> >>     while (1) {
>> >>     start:
>> >>     if (server) { //server case
>> >>         if((tSoc = accept (lSoc, NULL, 0))  == -1 ) {
>> >>         //Error handle
>> >>         sleep(2) ;
>> >>                 goto start ;
>> >>             }
>> >>     } else {  // client case
>> >>         if ((connect(lSoc, (struct sockaddr *)&servaddr,
>> >> sizeof(sockaddr))) != 0) {
>> >>             //Error Handling
>> >>                }
>> >>         }
>> >>
>> >>    }
>> >>
>> >> ...
>> >> ...
>> >> after that when I do
>> >>
>> >>    if((len = recvmsg(tSoc, msg, MSG_NOSIGNAL)) > 0) {
>> >>     // Some operation.
>> >>    } /* if (len > 0) */
>> >>
>> >>    if (len  < 0) {
>> >>     if (getsockopt(tSoc, IPPROTO_SCTP,SCTP_STATUS, &status, &socklen) == -1) {
>> >>         HERE I GET CONNECTION RESET BY PEER
>> >>     }
>> >>    }
>> >> ************************************
>> >>
>> >> I have following default setting related to sctp.
>> >>
>> >> h-3.2# sysctl -a |grep sctp
>> >> net.sctp.rto_initial = 3000
>> >> net.sctp.rto_min = 1000
>> >> net.sctp.rto_max = 60000
>> >> net.sctp.valid_cookie_life = 600000
>> >> net.sctp.max_burst = 4
>> >> net.sctp.association_max_retrans = 10
>> >> net.sctp.sndbuf_policy = 0
>> >> net.sctp.rcvbuf_policy = 0
>> >> net.sctp.path_max_retrans = 5
>> >> net.sctp.max_init_retransmits = 8
>> >> net.sctp.hb_interval = 30000
>> >> net.sctp.cookie_preserve_enable = 1
>> >> net.sctp.rto_alpha_exp_divisor = 3
>> >> net.sctp.rto_beta_exp_divisor = 2
>> >> net.sctp.addip_enable = 0
>> >> net.sctp.prsctp_enable = 1
>> >> net.sctp.sack_timeout = 200
>> >> net.sctp.sctp_mem = 36171    48230    72342
>> >> net.sctp.sctp_rmem = 4096    397500    1543360
>> >> net.sctp.sctp_wmem = 4096    16384    1543360
>> >> net.sctp.auth_enable = 0
>> >> net.sctp.addip_noauth_enable = 0
>> >> net.sctp.addr_scope_policy = 1
>> >> net.sctp.rwnd_update_shift = 4
>> >> net.sctp.max_autoclose = 8589934
>> >> sh-3.2#
>> >>
>> >> ********
>> >> Attaching two pcap files.
>> >>
>> >> 1. Client_localIP.pcap ---> In this file local IP (10.1.1.1) is not in
>> >> association.
>> >> 2, Client_publicIP.pcap. ---> in this 164.48.1.1 is part of association.
>> >>
>> >>
>> >>
>> >> >> I have also tries with "echo "2" >
>> >> >> /proc/sys/net/sctp/addr_scope_policy" which even doesn't allow the
>> >> >> association with private IP. for both (private & public IP) the server
>> >> >> receiver end receives the connection reset by peer.
>> >> >>
>> >> > Can you provide a tcpdump of this as well?
>> >> > Neil
>> >> >
>> >> >
>> >> >> > Neil
>> >> >> >
>> >> >>
>> >> >>
>> >> >> --
>> >> >> -=vipsy
>> >> >> http://through-dlens.blogspot.in
>> >> >>
>> >>
>> > So, I'm somewhat confused here.  I've looked at both the tcpdumps you provided
>> > and both traces show that ABORT chunks are generated, the exact same ABORT
>> > chunks.
>> >
>>
>> [Vipul] -- Ohh I got your point. If you are looking at starting ABORT,
>> that time server was not running but once IT started there is not
>> ABORT in between, (Please forgave me I didn't explain this in my
>> previous mail). And if you look into capture with publicIP there are
>> continue ABORT in some interval. I don;t know why this ABORT after
>> some data transmission.
>>
> Ah, ok, I still don't see a significant difference though.  You have have
> identical INIT chunks in the client_localIP trace, some of which produce aborts,
> some of which result in successful connections. I'm not sure what the difference
> is, and neither of them contain your 168.* address in the init chunk (look at
> frames 109-112 and 113-116 for comprative examples).  I would suggest looking at
> the snmp stats on the peer, or just enable dynamic debugging in the sctp module
> to get some clue as to whats going on here.
>
>
>>
>> > So I'm left wondering why you think one environment works and the other
>> > doesn't (unless neither environment works and I just misunderstood you
>> > previously).
>> >
>> > FWIW, the ABORT chunks have no causal data, which suggests they are either the
>> > result of the reception of an out of the blue packet, a t5 timer expiration or
>> > an init verification failure (I would guess the latter).  What does
>> > /proc/net/sctp/snmp show after you get the aborts?
>> >
>> > Neil
>> >
>> >>
>>
>> I used the Bind before connect to bind only one IP and this fixes the
>> issue. Now I cannot see multiple IP in association and no ABORT
>> PACKET.
>>
>> I'll be able to update with snmp output after a while as I need revert
>> the code again to get this.
>>
>> (If you think this is worth to discusses why ABORT is coming I'll
>> really like to continue this).
>>
>> PS: Really thanks a lot to all team for helping me and guiding me.
>>
> Don't thank me yet, I'm going on vacation here for a week or so.
>>
>> >>
>> >> --
>> >> -=vipsy
>> >> http://through-dlens.blogspot.in
>> >
>> >
>>
>>
>>
>> --
>> -=vipsy
>> http://through-dlens.blogspot.in
>>



-- 
-=vipsy
http://through-dlens.blogspot.in

[-- Attachment #2: Assoc & snmp logs --]
[-- Type: application/octet-stream, Size: 16482 bytes --]

(HOST A runing as SERVER & HOST B as Client)
##################################################
Host A without any IP on eth0.
------------------------------
sh-3.2# cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff88005be71800 ffff88000a48ce40 2   1   3  51514    2        0        0       0  6098 7168  51699  127.4.252.1 <-> *127.4.253.1 127.3.253.1 127.3.21.1 127.2.253.1 127.1.221.1 	    7500   300   300   10    0    0        0 
ffff880009f7f000 ffff88000a48c980 2   1   3  58839    1        0        0       0  6097 7169  58419  127.4.252.1 <-> *127.4.253.1 127.3.253.1 127.3.21.1 127.2.253.1 127.1.221.1 	    7500   300   300   10    0    0        0 
sh-3.2# 
sh-3.2#

sh-3.2# cat /proc/net/sctp/snmp   
SctpCurrEstab                   	2
SctpActiveEstabs                	0
SctpPassiveEstabs               	2
SctpAborteds                    	0
SctpShutdowns                   	0
SctpOutOfBlues                  	2
SctpChecksumErrors              	0
SctpOutCtrlChunks               	154
SctpOutOrderChunks              	1381
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	1144
SctpInOrderChunks               	1171
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	106
SctpReasmUsrMsgs                	1
SctpOutSCTPPacks                	1436
SctpInSCTPPacks                 	1735
SctpT1InitExpireds              	0
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	69
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	1662
SctpInPktBacklog                	73
SctpInPktDiscards               	2
SctpInDataChunkDiscards         	0
sh-3.2# 


Host B without any IP on eth0.
-------------------------------

sh-3.2#  cat /proc/net/sctp/assocs
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff88000a1ec000 ffff8800098404c0 2   1   3  12061    1        0        0       0  5880 58419  7169  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 
ffff88000a84e000 ffff880009840000 2   1   3  61212    2        0        0       0  5879 51699  7168  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 

sh-3.2#  cat /proc/net/sctp/snmp  
SctpCurrEstab                   	2
SctpActiveEstabs                	2
SctpPassiveEstabs               	0
SctpAborteds                    	2
SctpShutdowns                   	0
SctpOutOfBlues                  	0
SctpChecksumErrors              	0
SctpOutCtrlChunks               	750
SctpOutOrderChunks              	1207
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	1078
SctpInOrderChunks               	1417
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	1
SctpReasmUsrMsgs                	106
SctpOutSCTPPacks                	1807
SctpInSCTPPacks                 	1404
SctpT1InitExpireds              	0
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	597
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	1392
SctpInPktBacklog                	12
SctpInPktDiscards               	0
SctpInDataChunkDiscards         	0
sh-3.2# 
==============================================================================================

Adding Private IP (10.1.1.1/24) on HOST B
******************************************
sh-3.2#  cat /proc/net/sctp/assocs
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff880002938800 ffff8800098404c0 2   1   3  32028    4        0        0       0 23997 41057  7168  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 127.3.254.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 
ffff88004338f000 ffff880009840000 2   1   3  54813    3        0        0       0 23996 51658  7169  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 127.3.254.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 
sh-3.2# 

h-3.2#  cat /proc/net/sctp/snmp  
SctpCurrEstab                   	2
SctpActiveEstabs                	4
SctpPassiveEstabs               	0
SctpAborteds                    	37
SctpShutdowns                   	2
SctpOutOfBlues                  	0
SctpChecksumErrors              	0
SctpOutCtrlChunks               	1136
SctpOutOrderChunks              	1753
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	1623
SctpInOrderChunks               	1951
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	8
SctpReasmUsrMsgs                	107
SctpOutSCTPPacks                	2710
SctpInSCTPPacks                 	2102
SctpT1InitExpireds              	6
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	933
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	2086
SctpInPktBacklog                	16
SctpInPktDiscards               	0
SctpInDataChunkDiscards         	0
sh-3.2# 

During this time HOST A values:
******************************* 
sh-3.2# cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff88004c423800 ffff88004ff94e40 2   1   3  41153    2        0        0       0  6084 7168  41057  127.4.252.1 <-> *127.4.253.1 127.3.253.1 127.3.21.1 127.2.253.1 127.1.221.1 127.3.254.1 	    7500   300   300   10    0    0        0 
ffff88005c27d800 ffff88004ff94000 2   1   3  51203    1        0        0       0  6052 7169  51658  127.4.252.1 <-> *127.4.253.1 127.3.253.1 127.3.21.1 127.2.253.1 127.1.221.1 127.3.254.1 	    7500   300   300   10    0    0        0 
sh-3.2# 

sh-3.2# cat /proc/net/sctp/snmp   
SctpCurrEstab                   	2
SctpActiveEstabs                	0
SctpPassiveEstabs               	2
SctpAborteds                    	0
SctpShutdowns                   	0
SctpOutOfBlues                  	31
SctpChecksumErrors              	0
SctpOutCtrlChunks               	547
SctpOutOrderChunks              	762
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	667
SctpInOrderChunks               	938
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	1
SctpReasmUsrMsgs                	89
SctpOutSCTPPacks                	1172
SctpInSCTPPacks                 	933
SctpT1InitExpireds              	0
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	321
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	922
SctpInPktBacklog                	11
SctpInPktDiscards               	31
SctpInDataChunkDiscards         	0
sh-3.2# 



==============================================================================================

Adding Private IP (164.48.1.1/24) on HOST B
********************************************
sh-3.2#  cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff880056ec2000 ffff88004d398000 2   1   3  1309    3        0        0       0 15764 48921  7169  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 
ffff880024389800 ffff88004d3984c0 2   1   3  7196    5        0        0       0 22265 35584  7168  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 
sh-3.2#  cat /proc/net/sctp/snmp 
SctpCurrEstab                   	1
SctpActiveEstabs                	5
SctpPassiveEstabs               	0
SctpAborteds                    	34
SctpShutdowns                   	2
SctpOutOfBlues                  	0
SctpChecksumErrors              	0
SctpOutCtrlChunks               	707
SctpOutOrderChunks              	1773
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	1460
SctpInOrderChunks               	1774
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	86
SctpReasmUsrMsgs                	87
SctpOutSCTPPacks                	2233
SctpInSCTPPacks                 	1997
SctpT1InitExpireds              	6
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	529
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	1914
SctpInPktBacklog                	83
SctpInPktDiscards               	0
SctpInDataChunkDiscards         	0

At this point HOST A (Server) Received the Error.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

sh-3.2#  cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff880056ec2000 ffff88004d398000 2   1   3  1309    3        0        0       0 15764 48921  7169  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 
sh-3.2#  cat /proc/net/sctp/snmp 
SctpCurrEstab                   	2
SctpActiveEstabs                	7
SctpPassiveEstabs               	0
SctpAborteds                    	35
SctpShutdowns                   	2
SctpOutOfBlues                  	0
SctpChecksumErrors              	0
SctpOutCtrlChunks               	719
SctpOutOrderChunks              	1835
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	1494
SctpInOrderChunks               	1831
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	89
SctpReasmUsrMsgs                	88
SctpOutSCTPPacks                	2282
SctpInSCTPPacks                 	2044
SctpT1InitExpireds              	6
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	534
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	1957
SctpInPktBacklog                	87
SctpInPktDiscards               	0
SctpInDataChunkDiscards         	0
sh-3.2#  cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff880024249000 ffff88004d3984c0 2   1   3  1052    6        0        0       0 23367 44824  7168  127.3.253.1 127.3.21.1 127.4.253.1 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 <-> *127.4.252.1 	    7500   300   300   10    0    0        0 


HOST A Vales :
****************
Just beofre receving error
*****************************
sh-3.2# cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff880055bc5800 ffff88004d304980 2   1   3  48806    1        0        0       0  5946 7169  48921  127.4.252.1 <-> *127.4.253.1 127.3.253.1 127.3.21.1 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 	    7500   300   300   10    0    0        0 
sh-3.2# cat /proc/net/sctp/snmp 
SctpCurrEstab                   	1
SctpActiveEstabs                	0
SctpPassiveEstabs               	3
SctpAborteds                    	2
SctpShutdowns                   	0
SctpOutOfBlues                  	31
SctpChecksumErrors              	0
SctpOutCtrlChunks               	416
SctpOutOrderChunks              	618
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	520
SctpInOrderChunks               	786
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	1
SctpReasmUsrMsgs                	85
SctpOutSCTPPacks                	886
SctpInSCTPPacks                 	773
SctpT1InitExpireds              	0
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	186
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	769
SctpInPktBacklog                	4
SctpInPktDiscards               	31
SctpInDataChunkDiscards         	0
sh-3.2# Aug 4 23:30:49: ***** recv error (-1) Error: Connection reset by peer

Just After Error
*****************
cat /proc/net/sctp/assocs 
 ASSOC     SOCK   STY SST ST HBKT ASSOC-ID TX_QUEUE RX_QUEUE UID INODE LPORT RPORT LADDRS <-> RADDRS HBINT INS OUTS MAXRT T1X T2X RTXC
ffff88005bb89800 ffff88004d304e40 2   1   3  35867    5        0        0       0 10393 7169  36246  127.4.252.1 <-> *127.4.253.1 127.3.253.1 127.3.21.1 127.2.253.1 127.1.221.1 164.48.1.1 127.3.254.1 	    7500   300   300   10    0    0        0 
sh-3.2# cat /proc/net/sctp/snmp 
SctpCurrEstab                   	1
SctpActiveEstabs                	0
SctpPassiveEstabs               	5
SctpAborteds                    	4
SctpShutdowns                   	0
SctpOutOfBlues                  	35
SctpChecksumErrors              	0
SctpOutCtrlChunks               	454
SctpOutOrderChunks              	679
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	559
SctpInOrderChunks               	851
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	2
SctpReasmUsrMsgs                	88
SctpOutSCTPPacks                	954
SctpInSCTPPacks                 	831
SctpT1InitExpireds              	0
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	199
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	827
SctpInPktBacklog                	4
SctpInPktDiscards               	35
SctpInDataChunkDiscards         	0

sh-3.2# cat /proc/net/sctp/snmp 
SctpCurrEstab                   	0
SctpActiveEstabs                	0
SctpPassiveEstabs               	5
SctpAborteds                    	5
SctpShutdowns                   	0
SctpOutOfBlues                  	36
SctpChecksumErrors              	0
SctpOutCtrlChunks               	459
SctpOutOrderChunks              	681
SctpOutUnorderChunks            	0
SctpInCtrlChunks                	563
SctpInOrderChunks               	853
SctpInUnorderChunks             	0
SctpFragUsrMsgs                 	2
SctpReasmUsrMsgs                	88
SctpOutSCTPPacks                	961
SctpInSCTPPacks                 	835
SctpT1InitExpireds              	0
SctpT1CookieExpireds            	0
SctpT2ShutdownExpireds          	0
SctpT3RtxExpireds               	0
SctpT4RtoExpireds               	0
SctpT5ShutdownGuardExpireds     	0
SctpDelaySackExpireds           	200
SctpAutocloseExpireds           	0
SctpT3Retransmits               	0
SctpPmtudRetransmits            	0
SctpFastRetransmits             	0
SctpInPktSoftirq                	831
SctpInPktBacklog                	4
SctpInPktDiscards               	36
SctpInDataChunkDiscards         	0





^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2013-08-05  6:53 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-30 11:34 Association issue Vipul Singhania
2013-07-30 13:06 ` Neil Horman
2013-07-31  5:15 ` Vipul Singhania
2013-07-31 13:11 ` Neil Horman
2013-07-31 13:36 ` Vlad Yasevich
2013-08-01 10:34 ` Vipul Singhania
2013-08-01 11:48 ` Neil Horman
2013-08-02 13:00 ` Neil Horman
2013-08-02 17:32 ` Vipul Singhania
2013-08-02 20:05 ` Neil Horman
2013-08-05  6:53 ` Vipul Singhania

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.