[ovs-dev] [PATCH v3] lib: Add ipv6 support for active and passive socket connections

Arun Sharma arun.sharma at calsoftinc.com
Mon Dec 30 12:39:51 UTC 2013


As per MASTER, tests/ovsdb-server.at (line 486), there is a carriage
return '\r' displayed as '^M' in vim editor.

481 AT_SETUP([SSL db: implementation])
482 AT_KEYWORDS([ovsdb server positive ssl $5])
483 AT_SKIP_IF([test "$HAVE_OPENSSL" = no])
484 PKIDIR=$abs_top_builddir/tests
485 AT_SKIP_IF([expr "$PKIDIR" : ".*[   '\"
486 ^M\\]"])
487 AT_DATA([schema],




Reason for patch reject -  Patch file created using "format-patch", it has
'^M' character but when the patch is send using "git send-email", the '^M'
is *not* present. This rejects patch import.

So I have, 

1. attached the v3.1 patch (rebased with current master). If I apply using
below command it works.
	arun at debian:~/work/openvswitch$ git am
0001-lib-Add-ipv6-support-for-active-and-passive-socket-c.patch
        Applying: lib: Add ipv6 support for active and passive socket
connections 
        
2. But the same if I try using, "git am *.eml" then it throws rejects. I
see '^M' is not found in [PATCH v3.1]Š..eml file as below.

	2213 +    AT_SKIP_IF([expr "$PKIDIR" : ".*[   '\"
	2214  \\]"])
	2215 -AT_DATA([schema],


   To verify further, modified *.eml file by putting carriage return
character as below and again tried 'git am *.eml' which worked.

	2213 +    AT_SKIP_IF([expr "$PKIDIR" : ".*[   '\"
	2214  ^M\\]"])
	2215 -AT_DATA([schema],



Tried to check the options of send-email command which could solve this
problem but didm't find any clue.

-Arun



On 27/12/13 9:36 PM, "Ben Pfaff" <blp at nicira.com> wrote:

>On Tue, Dec 24, 2013 at 03:10:39AM +0530, Arun Sharma wrote:
>> Allows active/passive socket operations to use IPv6 network addresses,
>> except in-band control which is not supported for IPv6.
>> 
>> tests: Added tests for socket connections over IPv6.
>> Also added tests for NetFlow and sFlow using IPv6 sockets.
>> manpages: Updated connection information for IPv6 socket communication.
>> 
>> Signed-off-by: Nandan Nivgune <nandan.nivgune at calsoftinc.com>
>> Signed-off-by: Abhijit Bhopatkar <abhijit.bhopatkar at calsoftinc.com>
>> Signed-off-by: Arun Sharma <arun.sharma at calsoftinc.com>
>> 
>> ---
>> v2-v3:
>> - Rebased with current master.
>
>Didn't help, same error as before:
>
>Applying: lib: Add ipv6 support for active and passive socket connections
>Checking patch NEWS...
>Checking patch include/sparse/netinet/in.h...
>Checking patch lib/packets.h...
>Checking patch lib/rconn.c...
>Checking patch lib/socket-util.c...
>Checking patch lib/socket-util.h...
>Checking patch lib/stream-ssl.c...
>Checking patch lib/stream-tcp.c...
>Checking patch lib/stream.c...
>Checking patch lib/stream.h...
>Checking patch lib/vconn-active.man...
>Checking patch lib/vconn-passive.man...
>Checking patch ofproto/connmgr.c...
>Checking patch ofproto/ofproto-dpif-sflow.c...
>Checking patch ovsdb/remote-active.man...
>Checking patch ovsdb/remote-passive.man...
>Checking patch python/ovs/socket_util.py...
>Checking patch tests/ofproto-dpif.at...
>Checking patch tests/ofproto-macros.at...
>Checking patch tests/ovs-vsctl.at...
>Checking patch tests/ovsdb-idl.at...
>Checking patch tests/ovsdb-server.at...
>error: while searching for:
>AT_CHECK([test ! -e socket1])
>AT_CLEANUP
>
>AT_SETUP([SSL db: implementation])
>AT_KEYWORDS([ovsdb server positive ssl $5])
>AT_SKIP_IF([test "$HAVE_OPENSSL" = no])
>PKIDIR=$abs_top_builddir/tests
>AT_SKIP_IF([expr "$PKIDIR" : ".*[ 	'\"
>\\]"])
>AT_DATA([schema],
>  [[{"name": "mydb",
>     "tables": {
>       "SSL": {
>         "columns": {
>           "private_key": {"type": "string"},
>           "certificate": {"type": "string"},
>           "ca_cert": {"type": "string"}}}}}
>]])
>AT_CHECK([ovsdb-tool create db schema], [0], [stdout], [ignore])
>AT_CHECK(
>  [[ovsdb-tool transact db \
>     '["mydb",
>       {"op": "insert",
>        "table": "SSL",
>        "row": {"private_key": "'"$PKIDIR/testpki-privkey2.pem"'",
>                "certificate": "'"$PKIDIR/testpki-cert2.pem"'",
>                "ca_cert": "'"$PKIDIR/testpki-cacert.pem"'"}}]']],
>  [0], [ignore], [ignore])
>OVS_LOGDIR=`pwd`; export OVS_LOGDIR
>AT_CHECK(
>  [ovsdb-server --log-file --detach --no-chdir --pidfile="`pwd`"/pid \
>        --private-key=db:mydb,SSL,private_key \
>        --certificate=db:mydb,SSL,certificate \
>        --ca-cert=db:mydb,SSL,ca_cert \
>        --remote=pssl:0:127.0.0.1 --unixctl="`pwd`"/unixctl db],
>  [0], [ignore], [ignore])
>SSL_PORT=`parse_listening_port < ovsdb-server.log`
>AT_CHECK(
>  [[ovsdb-client \
>        --private-key=$PKIDIR/testpki-privkey.pem \
>        --certificate=$PKIDIR/testpki-cert.pem \
>        --ca-cert=$PKIDIR/testpki-cacert.pem \
>        transact ssl:127.0.0.1:$SSL_PORT \
>        '["mydb",
>          {"op": "select",
>           "table": "SSL",
>           "where": [],
>           "columns": ["private_key"]}]']],
>  [0], [stdout], [ignore], [test ! -e pid || kill `cat pid`])
>cat stdout >> output
>AT_CHECK_UNQUOTED(
>  [cat output], [0],
>  [[[{"rows":[{"private_key":"$PKIDIR/testpki-privkey2.pem"}]}]
>]], [ignore], [test ! -e pid || kill `cat pid`])
>OVSDB_SERVER_SHUTDOWN
>AT_CLEANUP
>
>AT_SETUP([compacting online])
>AT_KEYWORDS([ovsdb server compact])
>
>error: patch failed: tests/ovsdb-server.at:478
>Hunk #6 succeeded at 748 (offset -10 lines).
>Hunk #7 succeeded at 764 (offset -10 lines).
>Hunk #8 succeeded at 775 (offset -10 lines).
>Hunk #9 succeeded at 787 (offset -10 lines).
>Hunk #10 succeeded at 875 (offset -10 lines).
>Hunk #11 succeeded at 945 (offset -10 lines).
>Checking patch tests/test-sflow.c...
>Checking patch vswitchd/bridge.c...
>Checking patch vswitchd/vswitch.xml...
>Applied patch NEWS cleanly.
>Applied patch include/sparse/netinet/in.h cleanly.
>Applied patch lib/packets.h cleanly.
>Applied patch lib/rconn.c cleanly.
>Applied patch lib/socket-util.c cleanly.
>Applied patch lib/socket-util.h cleanly.
>Applied patch lib/stream-ssl.c cleanly.
>Applied patch lib/stream-tcp.c cleanly.
>Applied patch lib/stream.c cleanly.
>Applied patch lib/stream.h cleanly.
>Applied patch lib/vconn-active.man cleanly.
>Applied patch lib/vconn-passive.man cleanly.
>Applied patch ofproto/connmgr.c cleanly.
>Applied patch ofproto/ofproto-dpif-sflow.c cleanly.
>Applied patch ovsdb/remote-active.man cleanly.
>Applied patch ovsdb/remote-passive.man cleanly.
>Applied patch python/ovs/socket_util.py cleanly.
>Applied patch tests/ofproto-dpif.at cleanly.
>Applied patch tests/ofproto-macros.at cleanly.
>Applied patch tests/ovs-vsctl.at cleanly.
>Applied patch tests/ovsdb-idl.at cleanly.
>Applying patch tests/ovsdb-server.at with 1 rejects...
>Hunk #1 applied cleanly.
>Hunk #2 applied cleanly.
>Hunk #3 applied cleanly.
>Hunk #4 applied cleanly.
>Rejected hunk #5.
>Hunk #6 applied cleanly.
>Hunk #7 applied cleanly.
>Hunk #8 applied cleanly.
>Hunk #9 applied cleanly.
>Hunk #10 applied cleanly.
>Hunk #11 applied cleanly.
>Applied patch tests/test-sflow.c cleanly.
>Applied patch vswitchd/bridge.c cleanly.
>Applied patch vswitchd/vswitch.xml cleanly.
>Patch failed at 0001 lib: Add ipv6 support for active and passive socket
>connections
>When you have resolved this problem run "git am --resolved".
>If you would prefer to skip this patch, instead run "git am --skip".
>To restore the original branch and stop patching run "git am --abort".
>Press any key to continue...
>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-lib-Add-ipv6-support-for-active-and-passive-socket-c.patch
Type: application/octet-stream
Size: 94052 bytes
Desc: not available
URL: <http://mail.openvswitch.org/pipermail/ovs-dev/attachments/20131230/ae25214b/attachment-0005.obj>


More information about the dev mailing list