From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=none (p=none dis=none) header.from=gibson.dropbear.id.au Authentication-Results: passt.top; dkim=pass (2048-bit key; secure) header.d=gibson.dropbear.id.au header.i=@gibson.dropbear.id.au header.a=rsa-sha256 header.s=202502 header.b=N50e5qRF; dkim-atps=neutral Received: from mail.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) by passt.top (Postfix) with ESMTPS id E8DF65A026F for ; Tue, 04 Feb 2025 07:01:12 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202502; t=1738648859; bh=8s7dVOxHgZ4GweuzKE20urLr1wvWfYtyPhxMNjoiFWI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=N50e5qRF3R9Cb2vOZmbl+rdg+4xoOFYrHlPmdebmYLjBrjKqdCyWqTueEghnTbig3 qNAiMOZYPDF8nBjptCq4+o9oI26NLKrUhw2c++392KtZ6SJR+PBW2+T+r5Y3JjfCPV OBK4GoBLwzE7KTeuxWBlG0RXA4GkVsR0nUhLM5LQ17vwPutRvOnu93ClMXKdOZfQB2 j7IhY39utkGXeypIcsypSvjqo6X3MM+H+TvCfZMPmFYCBWMbnQtieiGE98NjdgLIUo i0oA8G+/AvRNd6EijCEaLB2nUbsdDORJAB4LYyrHbvpuCP9i1c5tiiy/mQLTuEdPgZ my68r16soSguA== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4YnCQz1Swkz4wvb; Tue, 4 Feb 2025 17:00:59 +1100 (AEDT) Date: Tue, 4 Feb 2025 17:01:04 +1100 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH v4 0/8] Draft, incomplete series introducing state migration Message-ID: References: <20250204004745.97854-1-sbrivio@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="S+FKJguxgFYmmsOu" Content-Disposition: inline In-Reply-To: <20250204004745.97854-1-sbrivio@redhat.com> Message-ID-Hash: DSQKB2WAEJPCX4KHSA4CDIP4AEMIJW73 X-Message-ID-Hash: DSQKB2WAEJPCX4KHSA4CDIP4AEMIJW73 X-MailFrom: dgibson@gandalf.ozlabs.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: passt-dev@passt.top, lvivier@redhat.com X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --S+FKJguxgFYmmsOu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Feb 04, 2025 at 01:47:37AM +0100, Stefano Brivio wrote: > I applied what I could, and squashed a number patches, including > those from "[PATCH 0/6] More migration improvements". >=20 > I didn't test the full flow here. With this patch set, I'm still unable to migrate a connection. First there are some simple things: * There are, again, some bogus revert hunks in the series which I had to remove. See comments * There are some bugs in the already committed patches, I posted a couple of fixes for those Then debugging the actual migration problem. The first issue I encountered was that the connect() on the target was failing with EADDRNOTAVAIL. I think this is a timing issue - the exit of the source instance isn't happening quite in time to free up the port. I was able to work around that by closing the source side socket immediately after extracting its info with tcp_repair, instead of postponing that to the exit check_device_state. To address this properly, I think we need to do a couple of things: * Treat the source-side point of no return as being at the end of migrate_source(). Close our sockets and purge flows at that point. * On the target side, defer actually re-opening/repairing the sockets until check_state, or even send_rarp time. Laurent, if you have some insight (or can find out) what guarantees we have in terms of what points on the target come after what points on the source that would be useful to check. With the hacky workaround, the connect() now success, but I still couldn't send data from the target. From strace, the target side passt doesn't seem to be attempting doing any writes to the socket, but I'm not sure why yet. pcap on the target side does show some packets on the stream coming from the guest, although it's only one byte (0x0a) and I thought I'd typed 5ish. It then appears to retransmit several times without getting an ack from passt. I'll keep debugging tomorrow if you don't have an insight. =20 --=20 David Gibson (he or they) | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you, not the other way | around. http://www.ozlabs.org/~dgibson --S+FKJguxgFYmmsOu Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmehrR8ACgkQzQJF27ox 2Gf2vQ/6A8M6Exre2iTCDL+QB4P2tzGfsjor+EN7I5HxUuX0YGyKbKEN3FdAoW/y DsM2AOuDissrpAkCbRGor775E+d8fkaCI0oKok7NcR7LonPLuXTuKHY8Rv/uAa/L Qo6Nc8bA4sOdGqSVlzrvehY9BzxnAnveB6Tek9eHJBPby2o+NGGCT4PXU6sxiOzE UITzD+hA9Z3lfjPNO2iKMThxO+33Ohj4gNdXRLMTjx2C++D48j0FypiNDN2ws2sx xB2WRA41exa4ELVRrM4u3xry/c8mYqbyvwKB7e8b/Wu/oH1eVVGW2cqxZKFUCAdb FE5T1UG42YyeZbQABTPg9XhdOM5IGDZKLr4fCkEJjv49mmcF+wB1p4vNldF7vw33 em/SODW7NYwi6HJAwP6XmE5zYAHvIbn0yLLAQzH1g7C5o1bs/jQUcbfpGlwPkBod eC0EmMIi1ne0mN0f/V6kCtS+thakcxGIFbB1a4z1jZyb42lOMP/b3XF/kh5ZZj48 9hYiFk/HpzidY09mZGrEVpeNYmKDtGtu3zgjDSpO8ZDCu80c6moKhdZmnMJJpg5B dJzgXSY/zYWOaZCtH3sDNvrETDSoY8qF3SgFqroykeZ4pqc+oYSzdSWnFuzo/r1L d5bL4W/02gJuBiuE/D53ICnjtpZMHym8zup9DbSv9Qw9ps2PCok= =m83z -----END PGP SIGNATURE----- --S+FKJguxgFYmmsOu--