From nobody Mon Dec 9 18:19:20 2024 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Y6VWt1lFvz5gcqY for ; Mon, 09 Dec 2024 18:19:54 +0000 (UTC) (envelope-from freebsd@walstatt-de.de) Received: from smtp6.goneo.de (smtp6.goneo.de [IPv6:2001:1640:5::8:31]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4Y6VWs6hWlz4qsw; Mon, 9 Dec 2024 18:19:53 +0000 (UTC) (envelope-from freebsd@walstatt-de.de) Authentication-Results: mx1.freebsd.org; none Received: from hub2.goneo.de (hub2.goneo.de [85.220.129.53]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp6.goneo.de (Postfix) with ESMTPS id 9959A240EC1; Mon, 9 Dec 2024 19:19:50 +0100 (CET) Received: from hub2.goneo.de (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by hub2.goneo.de (Postfix) with ESMTPS id 37E48240031; Mon, 9 Dec 2024 19:19:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walstatt-de.de; s=DKIM001; t=1733768388; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=icX7PDuqYEe8KcGivgbwOte+2csDVMnhp5xcS7tMKfE=; b=EEtamF7mW0pflxBnfULlHw4P90oKGj6nJpLYejxiyblqZo3iJgW1Pf/QIT8zZbUi952NBW pNwZt3790Y0KZkZDsP8Qig32JwFi0KxuoEaxVCbvFrGZEtebkOwduUtVpFWY8VLoQF+Lvw ZWCWFSMWaf5zyJdbfGrEHgiaPx2PpVxWx+QFSxSBtp0R5udtXCcSG6hkcqP/l6OwnMy4AS YnyrGJqUztxaVZl5NHG0YArll9Szq4AM67ehKXkuNC/gMkGpilI2PM7wvjf4oLdCe9mhcU wYAbaGgNR2MLAlnBUN5hIDgj5QI0jNw4Ca6yjd8WdgSiXZP+qh34MZVaHR2ezg== Received: from thor.intern.walstatt.dynvpn.de (dynamic-077-183-031-236.77.183.pool.telefonica.de [77.183.31.236]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by hub2.goneo.de (Postfix) with ESMTPSA id E20ED24001B; Mon, 9 Dec 2024 19:19:47 +0100 (CET) Date: Mon, 9 Dec 2024 19:19:20 +0100 From: FreeBSD User To: Tomoaki AOKI Cc: Juraj Lutter , Ronald Klop , freebsd-current@freebsd.org Subject: Re: (ipfw) Re: HELP! fetch: stuck forever OR error: RPC failed: curl 56 recv failure: Operation timed out Message-ID: <20241209191947.39ac4843@thor.intern.walstatt.dynvpn.de> In-Reply-To: <20241210022710.88c9087dd7cb09774507f232@dec.sakura.ne.jp> References: <20241206034709.4dd32cc5@thor.intern.walstatt.dynvpn.de> <279848701.11738.1733510402875@localhost> <20241206210947.3ae835e4@thor.intern.walstatt.dynvpn.de> <8E43EAA1-BA3E-4655-ACE1-2E4523E901DE@FreeBSD.org> <20241209214314.2443b590d774423a2b97f0a8@dec.sakura.ne.jp> <20241209174541.39c286f5@thor.intern.walstatt.dynvpn.de> <20241210022710.88c9087dd7cb09774507f232@dec.sakura.ne.jp> Organization: walstatt-de.de List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-UID: 5c6c10 X-Rspamd-UID: 146114 X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:25394, ipnet:2001:1640::/32, country:DE] X-Rspamd-Queue-Id: 4Y6VWs6hWlz4qsw X-Spamd-Bar: ---- Am Tue, 10 Dec 2024 02:27:10 +0900 Tomoaki AOKI schrieb: My apology for topposting. The host I first realised the problems is updated on an almost daily basis = and the issue reported started last weekend. A possible candidate could be https://cgit.freebsd.org/src/commit/sys/netpfil/ipfw?id=3D0fc7bdc978366abb4= 351b0b76b50a5848cc5d982 since the other, younger, seem innocent. I try to revert the patch mentione= d and see ... > On Mon, 9 Dec 2024 17:45:14 +0100 > FreeBSD User wrote: >=20 > > Am Mon, 9 Dec 2024 21:43:14 +0900 > > Tomoaki AOKI schrieb: > > =20 > > > On Mon, 9 Dec 2024 11:09:14 +0100 > > > Juraj Lutter wrote: > > > =20 > > > > > On 8 Dec 2024, at 20:30, Ronald Klop wrote: > > > > >=20 > > > > > Hi, > > > > >=20 > > > > > I can reproduce your error. > > > > >=20 > > > > > A cronjob which does a scp to another server didn't work anymore.= When I go back to > > > > > the previous BE it works fine again. Ipfw disable firewall also m= akes the scp work. > > > > >=20 > > > > > Scp also seems to work fine if I replace the statefull firewall r= ules with stateless > > > > > "pass all from any to any". =20 > > > >=20 > > > > Have you tried to allow ICMP in both directions explicitly, in case= of stateful rules? > > > >=20 > > > > =E2=80=94 > > > > Juraj Lutter > > > > otis@FreeBSD.org =20 > > >=20 > > > I think would usually work for clients with some limited services > > > exposed to outside. IIUC, it basically allow all sessions from inside > > > and allows limited serivices configured with variables > > > via /etc/rc.conf[.local]. > > >=20 > > > Some notes. > > > *Last actual changes in /usr/src/libexec/rc/rc.firewall was at > > > Jul.23, 2020. > > > https://github.com/freebsd/freebsd-src/commits/main/libexec/rc/r= c.firewall > > > [cgit.freebsd.org seems to be unstable now.] > > >=20 > > > *Variable firewall_logif currently does not exist. > > >=20 > > > *Don't you need allowing 22/UDP, too, like below? > > > firewall_myservices=3D"22/tcp 22/udp" > > >=20 > > > And if you're creating kernel config from scratch (such as copying fr= om > > > GENERIC at some point and editing it), it's no longer adviced. > > > It's not robust for changes in GENERIC. > > >=20 > > > Instead, include GENERIC and describe changes you want. > > >=20 > > > An example (one of my test kernel config for a bit old stable). > > >=20 > > > =3D=3D=3D=3D=3D Start example =3D=3D=3D=3D=3D > > > =20 > > > include GENERIC > > >=20 > > > ident TEST15 > > >=20 > > > nooptions DDB > > > nooptions GDB=20 > > > nooptions INVARIANTS > > > nooptions INVARIANT_SUPPORT > > > nooptions WITNESS > > > nooptions WITNESS_SKIPSPIN > > > nooptions DEADLKRES > > >=20 > > > options CAM_IOSCHED_DYNAMIC > > >=20 > > > device sg > > >=20 > > > =3D=3D=3D=3D=3D End example =3D=3D=3D=3D=3D > > >=20 > > > =20 > >=20 > > Thank you very much for the advice - but I do this kind of confugration= now since, I guess, > > 2020 or 2021. consider the host's kernel name to be "THOR", then /etc/s= rc.conf has lines > >=20 > > KERNCONF=3D THOR > > KERNCONFDIR=3D /etc/config/amd64/kernel_conf/ > >=20 > > and the target's config file "/etc/config/amd64/kernel_conf/THOR" conta= ins > >=20 > > include GENERIC > > include NODEVICE-THOR > > include "std.nodebug" > > include ADDON-THOR > >=20 > > This concept isn't bullet proof, since I had trouble with the relativel= y recent introduced > > "std.nodebug". As you mentioned, NODEVICE contains ALL "nooptions" and = "nodevice" and ADDON > > contains some extra options not contained in GENERIC. GENERIC is a symb= olic link to the > > original GENERIC in the appropriate sys folder. > >=20 > > Thanks to FReeBSD's sophisticated kernel configuration, this hierarchic= al scheme prevents > > most accidents triggered by significant GENERIC changes. > >=20 > > Do you suspect a misconfiguration due to uncaught changes in GENERIC?=20 > >=20 > > --=20 > > O. Hartmann =20 >=20 > Just a possibility. Not sure when it was and which firewall (ipfw? pf? > or else?) it was, but IIRC, I've seen some excessive configs to enable > non-default options/devices built into kernel caused unwanted changes > in default before when I was searching unrelated things of FreeBSD. >=20 > And why I've mentioned about kernel configuration file is because I've > bitten by the changes in GENERIC before. >=20 > In contrast with rc.firewall, kernel side of ipfw received some changes > this year. >=20 > https://cgit.freebsd.org/src/log/sys/netpfil/ipfw >=20 > So anything committed after your previous build could cause the issue. > Sorry, I have not enough time to dig into deeper. Other points to worth > checking would be: >=20 > https://cgit.freebsd.org/src/log/sys/netgraph >=20 > https://cgit.freebsd.org/src/tree/sys/net >=20 > The latter should be limited with bpf related (otherwise too bload). > net and netinet would be too bload, too. Bloader codes should be > checked when narrow and close codes are analysed to be NOT affecting. > Otherwise, there would be too much confusions. >=20 --=20 O. Hartmann