From owner-freebsd-questions@freebsd.org Sun Oct 11 03:05:42 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D77D9434B4C for ; Sun, 11 Oct 2020 03:05:42 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C86BY1r8cz4bDr for ; Sun, 11 Oct 2020 03:05:40 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 857BE5C00D3 for ; Sat, 10 Oct 2020 23:05:40 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Sat, 10 Oct 2020 23:05:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zyxst.net; h= date:from:to:subject:message-id:mime-version:content-type; s= fm3; bh=YPZSSVpNMWoEQpsfdZZjwOiKs/Hi8bWR80WO84WLRfM=; b=Y1lSX/3U mIivuV+a8QdNQbIOqYb+14j3Zh0W4TRuB0FkOxNjHI/W7jIXBFYWOwMZ5domLbeO EKM2lx3F3k4aKHxXFG7T1uopRXCbgwjB8hkv2FAcQrv3H5EhzPFcx1NhuC7FEtNp N2fZL2cjn2nLtza4e5XwmTzNMLhSAnetbL8ee5Hd0zQdt3P4C1dRaAJfTpGhliRf uw/nICUqBSDJ+av37EkSHdIQP8GOwHrQltV8+WiN046HKuKcNwP7LVxkPc8XJYa5 Sbl2f2bDCzERGs4vgg9z2xHWrbwaR+v30sQ2fnOv7uIJMg+X5CwASHkM+Bt4CDbt b6gMSOpfZ6RcPA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:message-id :mime-version:subject:to:x-me-proxy:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; bh=YPZSSVpNMWoEQpsfdZZjwOiKs/Hi8 bWR80WO84WLRfM=; b=nhf1LccNpJ0syvoHttFzDqXIeKZWQ7OcdiTryYvY24WAS bTkEjgXFjMnuLO87viEvl5QWhE14LCiyvC7qmfKE3oeELTiNVIZlgZXitFnMTjtr l3v2WUfmNh/XwY5rqJvz3thHPwKqLIe52mur6LMZshtrx+A+/LejX8RCECnD+fjR lopYHJjhdXsTOvjUkeHQwB2t111kC43QAWxrkdiMBmq1R7+rSJzywLjaHt3xxPmu jIJDgWpM2lCEhBH+pSuLg2KTz3ojbRPq8X6e+RZu3zCYgkuhJzpgq5WqmRyFdV2I FZS3QnwMPYcHzONkK92pXViYMj9JirHn4jtJIrOrA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrheeggdehjecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurhepfffhvffukfggtggusehgtderredttd dvnecuhfhrohhmpehtvggthhdqlhhishhtshcuoehtvggthhdqlhhishhtshesiiihgihs thdrnhgvtheqnecuggftrfgrthhtvghrnhepvefghffftdefkeelleehtdejledvhfdvge eijeevfffguddvhfetgeejueejueeinecukfhppeekvddrjedtrdeluddruddtvdenucev lhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehtvggthhdqlh hishhtshesiiihgihsthdrnhgvth X-ME-Proxy: Received: from rpi4.gilescoppice.lan (axs-0-ipv4.zyxst.net [82.70.91.102]) by mail.messagingengine.com (Postfix) with ESMTPA id E8A41328005D for ; Sat, 10 Oct 2020 23:05:39 -0400 (EDT) Date: Sun, 11 Oct 2020 04:05:37 +0100 From: tech-lists To: freebsd-questions@freebsd.org Subject: errors happening with /usr/libexec/save-entropy on 12.1-p10 Message-ID: <20201011030537.GA30207@rpi4.gilescoppice.lan> Mail-Followup-To: freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="BOKacYhQ+x31HxR3" Content-Disposition: inline X-Rspamd-Queue-Id: 4C86BY1r8cz4bDr X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=zyxst.net header.s=fm3 header.b=Y1lSX/3U; dkim=pass header.d=messagingengine.com header.s=fm1 header.b=nhf1LccN; dmarc=none; spf=pass (mx1.freebsd.org: domain of tech-lists@zyxst.net designates 66.111.4.29 as permitted sender) smtp.mailfrom=tech-lists@zyxst.net X-Spamd-Result: default: False [-5.50 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[zyxst.net:s=fm3,messagingengine.com:s=fm1]; NEURAL_HAM_MEDIUM(-1.02)[-1.021]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[66.111.4.29:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:66.111.4.29]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-0.998]; RCVD_COUNT_THREE(0.00)[4]; DMARC_NA(0.00)[zyxst.net]; DKIM_TRACE(0.00)[zyxst.net:+,messagingengine.com:+]; NEURAL_HAM_SHORT(-0.78)[-0.780]; SIGNED_PGP(-2.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:11403, ipnet:66.111.4.0/24, country:US]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[66.111.4.29:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 11 Oct 2020 03:05:42 -0000 --BOKacYhQ+x31HxR3 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, I've noticed recently in the daily security email that *sometimes* when this is run out of /etc/crontab on a 12.1-p10 system: # Save some entropy so that /dev/random can re-seed on boot. */11 * * * * operator /usr/libexec/save-entropy that it'll generate an error visible in the security email like this: [redacted] kernel log messages: +pid 12995 (dd), uid 2 inumber 2086730 on /: filesystem full (the filesystem has plenty of inodes spare and plenty of space) It's the only one I've seen so far (12.1-p10) with this issue. 12-stable doesn't have this problem, but the /usr/libexec/save-entropy is=20 significantly different: [12.1-p10 snip] umask 377 n=3D$(( ${entropy_save_num} - 1 )) while [ ${n} -ge 1 ]; do if [ -f "saved-entropy.${n}" ]; then mv "saved-entropy.${n}" "saved-entropy.$(( ${n} + 1 ))" elif [ -e "saved-entropy.${n}" -o -L "saved-entropy.${n}" ]; then logger -is -t "$0" \ "${entropy_dir}/saved-entropy.${n}" is not a regular file, and so \ it will not be rotated. Entropy file rotation is aborted. exit 1 fi n=3D$(( ${n} - 1 )) done dd if=3D/dev/random of=3Dsaved-entropy.1 bs=3D${entropy_save_sz} count=3D1 = 2>/dev/null exit 0 [snip] Weird umask too. What's also weird is that it doesn't happen when it's *not* expected to be under load. $FreeBSD: stable/12/libexec/save-entropy/save-entropy.sh 355748 2019-12-14 09:49:09Z delphij $ has this: [12-stable-r365826-snip] # 3. Check if the pointer we have in hand is really a regular file or # an empty slot, and bail out as that means there is no available slot. # if [ -e "${save_file}" -a ! -f "${save_file}" ]; then logger -is -t "$0" \ No available slot in "${entropy_dir}", save entropy is abo= rted. exit 1 fi # Save entropy to the selected slot. chmod 600 "${save_file}" 2>/dev/null || : dd if=3D/dev/random of=3D"${save_file}" bs=3D${entropy_save_sz} count=3D1 2= >/dev/null chflags nodump "${save_file}" 2>/dev/null || : fsync "${save_file}" "." [snip] What I'm asking is, would transplanting a working 12-stable /usr/libexec/sa= ve-entropy=20 into the 12.1-p10 system having the problem be a simple fix or are there other things I've not considered, like the entropy subsystem being=20 significantly modified between 12.1-R and recent 12-stable? thanks, --=20 J. --BOKacYhQ+x31HxR3 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEE8n3tWhxW11Ccvv9/s8o7QhFzNAUFAl+CdngACgkQs8o7QhFz NAXxFQ/+KwmWfp2gpeWIrDZlb9okyNq4veCTJk9z+NCUGxE0FngYiTLGa+65el4U tnphFtMpfEAQOHa61vwytsm605krlX6ULWaxfjJULvFDiQbNY6urbrW3i0uM7dgt jIJznmFp4bpsfDLtz/+yr+tART2+OgevqPSaVnSuEnBnht8XPyWM0TeO97jFhrUq /mpnQAxVYlfdGjFjSGd2PIdO+dxSTwCxTzOoBZD5hVMzgs0zSIJeHBHS8hIYqHE5 Ulp4N8BMCp+WsAu3v+zgv9gObotyNWC92K0mj5XivRvbnfTd7uh6nK1Mlaw+mTra iCNH+b60V3/5YqQ+20RiH6nMz3tT3au6i4CptP3f8oVxH5FX25BvV6GszwIzIcE6 XwHu/9sfkdk6K+LfunYg0zci5/s/ZgSimp+l2VSCeErm1xjRLX219t5rwgfqAysp C31lME6aOCZS6BaQ63yZK3TPBF7HASaUzwkgBd/IB15o1uTIq4tEXoCLUz7g/C70 pmfbgUNwteSYiXix0JhX9ZmA4Y8o3pBkN4z/j9d6vXdrrMswvy2vDBkQAHwyRZll b7zVbRL2d4n0xD/Ju1ZNtPKWMw0iKtqC3OCdtlWutBOnw+83+i7eLB/Bk7PNulGG aSN/ykSe8NETdnZgyUKB1UUoRAnnSkAWDnzp6URO/KVkqkgKOlM= =+gov -----END PGP SIGNATURE----- --BOKacYhQ+x31HxR3-- From owner-freebsd-questions@freebsd.org Sun Oct 11 14:09:45 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 1CDE73F541F for ; Sun, 11 Oct 2020 14:09:45 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C8Nwm3knBz4GSw for ; Sun, 11 Oct 2020 14:09:44 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: by mail-wm1-x341.google.com with SMTP id b127so1946398wmb.3 for ; Sun, 11 Oct 2020 07:09:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=HJdanCPY72ulIZvE01XJd6YLP7aw6/MhVcwSRH8Svo0=; b=WtUcnOf8VEclfokNowvwy7sors/hPPhD+hRA1VEAyo9lW7xAP9sHImHVkDfmNn6g1l lalGYwy1sb3eDriyZFyvYa6caiod3oW02qB5BibNVlBPzmeKDDM5jbKzBTtb6sIpPepB XCYab8qD/F4LbU1uqXLFPAeRvkPwWrhs91Dn+hzG/9C4o1fZ91sC/AJ8CqPBpoU6amkk PGh8AeSufuiHu2OmFPFDi+xLfqr62u33kO+v+yZHE9/iQohWH43B0PVpfwOPR9THzhrs uypC3XDEVCj4p4+qzqVmt2X/GTd9n4Xm0w7lEvdII3zMMY55Dha9AY78LsVlJhcMpcTW tq3A== X-Gm-Message-State: AOAM530UrWBWh1GO0xOpLdTti4hyGoxoKsWGhVVdjGC3hMGBv6/Tvngn FWxfw64/tjuwRJKT13DoxSJ/CdUlvst2Yg== X-Google-Smtp-Source: ABdhPJx1hnH7TUCLvDUgJZbvJy2qDSJPFq/oPEWg6R4UkpEmHZqDTCPIMAQOO/P5Myf5g9sDazXIJg== X-Received: by 2002:a1c:9d90:: with SMTP id g138mr6847516wme.5.1602425382889; Sun, 11 Oct 2020 07:09:42 -0700 (PDT) Received: from gumby.homeunix.com ([90.195.199.9]) by smtp.gmail.com with ESMTPSA id r1sm20514565wro.18.2020.10.11.07.09.41 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 11 Oct 2020 07:09:42 -0700 (PDT) Date: Sun, 11 Oct 2020 15:09:40 +0100 From: RW To: freebsd-questions@freebsd.org Subject: Re: errors happening with /usr/libexec/save-entropy on 12.1-p10 Message-ID: <20201011150940.6d0f5547@gumby.homeunix.com> In-Reply-To: <20201011030537.GA30207@rpi4.gilescoppice.lan> References: <20201011030537.GA30207@rpi4.gilescoppice.lan> X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; amd64-portbld-freebsd12.1) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4C8Nwm3knBz4GSw X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.51 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; FREEMAIL_FROM(0.00)[googlemail.com]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[googlemail.com:+]; DMARC_POLICY_ALLOW(-0.50)[googlemail.com,quarantine]; NEURAL_HAM_SHORT(-0.61)[-0.607]; RECEIVED_SPAMHAUS_PBL(0.00)[90.195.199.9:received]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[googlemail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; DWL_DNSWL_NONE(0.00)[googlemail.com:dkim]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.97)[-0.971]; R_DKIM_ALLOW(-0.20)[googlemail.com:s=20161025]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.93)[-0.927]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::341:from]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 11 Oct 2020 14:09:45 -0000 On Sun, 11 Oct 2020 04:05:37 +0100 tech-lists wrote: > Hi, > > I've noticed recently in the daily security email that *sometimes* > when this is run out of /etc/crontab on a 12.1-p10 system: > > # Save some entropy so that /dev/random can re-seed on boot. > */11 * * * * operator > /usr/libexec/save-entropy > > that it'll generate an error visible in the security email like this: > > [redacted] kernel log messages: +pid 12995 (dd), uid 2 inumber 2086730 > on /: filesystem full > > (the filesystem has plenty of inodes spare and plenty of space) > > It's the only one I've seen so far (12.1-p10) with this issue. > 12-stable doesn't have this problem, but the If it fails on 12.1 but not on 12-stable that would imply that it's a long standing problem and something was fixed in stable. There's no sign that anything like that happened. I think it's unlikely that this is caused by save-entropy. All it does is dd the output of /dev/random to a file and rotate the files. When you say that there's plenty of space, are you allowing for the fact that the operator user can't write to space reserved for root. From owner-freebsd-questions@freebsd.org Mon Oct 12 23:27:36 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 8A51442AAF9 for ; Mon, 12 Oct 2020 23:27:36 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.ilk.org (be-well.ilk.org [23.30.133.173]) by mx1.freebsd.org (Postfix) with ESMTP id 4C9FFz4Mctz3YpK for ; Mon, 12 Oct 2020 23:27:35 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from lowell-desk.be-well.ilk.org (router.lan [172.30.250.2]) by be-well.ilk.org (Postfix) with ESMTP id 5736733C06; Mon, 12 Oct 2020 19:27:24 -0400 (EDT) Received: by lowell-desk.be-well.ilk.org (Postfix, from userid 1147) id 2EB0C163232E; Mon, 12 Oct 2020 19:27:22 -0400 (EDT) From: Lowell Gilbert To: sasha vigole Cc: freebsd-questions@freebsd.org Subject: Re: Adding a laptop with defected 2nd/GPU to the Wiki References: <64e85f7e-e9a7-7899-d272-061feadcfdb1@vigole.com> Date: Mon, 12 Oct 2020 19:27:22 -0400 In-Reply-To: (sasha vigole's message of "Sat, 10 Oct 2020 11:14:09 +0330") Message-ID: <44tuuzm3dx.fsf@be-well.ilk.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 4C9FFz4Mctz3YpK X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-questions-local@be-well.ilk.org has no SPF policy when checking 23.30.133.173) smtp.mailfrom=freebsd-questions-local@be-well.ilk.org X-Spamd-Result: default: False [0.97 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.49)[-0.488]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_SPAM_SHORT(0.18)[0.177]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[ilk.org]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_SPAM_LONG(0.28)[0.282]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:7922, ipnet:23.30.0.0/15, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Oct 2020 23:27:36 -0000 sasha vigole writes: > On 09/10/2020 00:35, sasha vigole wrote: >> Hi, I have to test/post, technical info of two laptops to the wiki. >> I'm familiar with procedure, and it's not a hardware diagnostic post. >> One of the laptops works OK with FreeBSD, but its 2nd/GPU is >> defected. >> If I post its info to the wiki, it's going to lack info about 2nd/GPU. >> Official specs at the Lenovo, states that this laptop has a 2nd/GPU. >> Should I post such non-complete technical information to the wiki, >> or >> it's not appropriate and it's going to confuse some users. >> > > I'll post the result to the wiki ASAP, setting the defected 2nd/GPU's > "Status" to: "Present but status unknown or untested". > Meanwhile, I'm happy to hear your suggestion/correct, regarding such > issues, and I'll change related status accordingly. Thanks. Unfortunately, handling these issues can be quite tricky. Telling the differences between tiny variations of "the same chip" can (usually) require vast amounts of time, and that's with the company selling the chip being extremely generous in the amount of time they're willing to expend in documenting the differences. Good luck. From owner-freebsd-questions@freebsd.org Tue Oct 13 00:31:04 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9D28E42CA14 for ; Tue, 13 Oct 2020 00:31:04 +0000 (UTC) (envelope-from jguojun@gmail.com) Received: from mail-ot1-x331.google.com (mail-ot1-x331.google.com [IPv6:2607:f8b0:4864:20::331]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9GgB71Qvz3c74 for ; Tue, 13 Oct 2020 00:31:02 +0000 (UTC) (envelope-from jguojun@gmail.com) Received: by mail-ot1-x331.google.com with SMTP id m11so17446915otk.13 for ; Mon, 12 Oct 2020 17:31:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=to:from:subject:message-id:date:user-agent:mime-version :content-transfer-encoding:content-language; bh=SO6uqWZ3krt0n53O1/VTU4CSRz6GbaeXhiSB2H6Ct1A=; b=Aczby2jYtZup08Z9LtaCVj1Mh6uxFIfMClTMsgE8ZKDhpOi7foV7QKTHwyZFG2sXAM dnk0h/i7K4I1JNxDKPpV4kFVKS36iyxY0p2hfCVvDZw7AThonryN0B9cRTpvxcCf7ffF oA4zXuSbr4amkltKhmxL37iDPYKMKvuV847pCyrIsoio5d1B9lWr109Ge2nBluF9ZrUt ohr1IM9hrWX5L5dZUVyn8kyNoYyhSMtJN7pvWgtTbA26/tS6NfJiOJpGnkOQnyjH/on3 T60Y8+h134OqQjyrTAR3Y/QjQ3FY2Iv3L+FLiTFohmjfMZidM6T5Qf8TM4f/qdS1qxKG Q4nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-transfer-encoding:content-language; bh=SO6uqWZ3krt0n53O1/VTU4CSRz6GbaeXhiSB2H6Ct1A=; b=XB08ZnZhBm2DhumuEKyOcXpoUR/xaQ/ZTE57BmVBLIRoJpGYb9/+YURBbL/7ppThQ3 6S2y+f6aXZoylLHf3/6RbAWArDaCPqbU0245Ox8olP6iLRZORBW7BK8vEWYYCrQX9Tf9 eEtnhseE/42lZ43+91cRXH+JFfpNWqcS5NNhW85I/ih8OkxSUEY2qSinIGA2bmHWlzOD BZR1hn0YI+ZYO758jmu96HHM9HrLU7xsDHwJPWgYLrnjn5Phwc9LQSEsmHLaIhSO2glZ vSXYmEWS/Obl7tFsuxZ4CuWI0yMYTsHRV3DM/idbkgxxSyirmSed/sIS1ZKFjRo/JwEa S39A== X-Gm-Message-State: AOAM531ECL/7tGe82AEezxXD8iBCKi8pc0rTJgJFnQSMr9hVIrUnMh4Y odiuAnIoHubvDheeZ3msH/5jGWjb6A== X-Google-Smtp-Source: ABdhPJw0Z3lPJ69zIcTtrg7Aoo5WxBjsEO1CPogzoYrX27xw/0hdJH7zMfKtHRV3+oWdOc+wxms2QA== X-Received: by 2002:a9d:5910:: with SMTP id t16mr21675082oth.155.1602549061386; Mon, 12 Oct 2020 17:31:01 -0700 (PDT) Received: from ?IPv6:2600:1702:2771:1060:e23f:49ff:fe45:91e6? ([2600:1702:2771:1060:e23f:49ff:fe45:91e6]) by smtp.gmail.com with ESMTPSA id w7sm11348126oon.2.2020.10.12.17.31.00 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 12 Oct 2020 17:31:00 -0700 (PDT) To: freebsd-questions@freebsd.org From: "Jin Guojun[VFF]" Subject: strange binary status when linked with shared binary in 11.4-R Message-ID: Date: Mon, 12 Oct 2020 17:30:54 -0700 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Rspamd-Queue-Id: 4C9GgB71Qvz3c74 X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=Aczby2jY; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of jguojun@gmail.com designates 2607:f8b0:4864:20::331 as permitted sender) smtp.mailfrom=jguojun@gmail.com X-Spamd-Result: default: False [-3.52 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; NEURAL_HAM_SHORT(-0.55)[-0.554]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.97)[-0.968]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-0.996]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::331:from]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 00:31:04 -0000 In 11.4-Release, the binary linked with shared library (.so) is MUCH bigger then expected, and ldd shows the binary linked with shared binary is not really dynamically linked. This has not been seen in 10.x-Release and earlier. Does anyone know if the dynamic link flag has been changed in CLang 10? -Jin $ CC -v FreeBSD clang version 10.0.0 (git@github.com:llvm/llvm-project.git llvmorg-10.0.0-0-gd32170dbd5b) Target: x86_64-unknown-freebsd11.4 Move libccs.a to libccs.ax to demo that this is not a mistake: -rw-r--r--  1 jin  100   435688 Sep  7 14:59 /usr/local/lib/libccs.ax lrwxr-xr-x  1 jin  100         13 Sep  7 15:00 /usr/local/lib/libccs.so@ -> libccs.so.2.3 -rw-r--r--  1 jin  100   339648 Sep  7 15:00 /usr/local/lib/libccs.so.2.3 # static linker fails due to no static library $ cc -I$HOME/include stol.c -o stol -L/usr/local/lib -Xlinker -Bstatic -lccs -lm /usr/bin/ld: cannot find -lccs cc: error: linker command failed with exit code 1 (use -v to see invocation) # now we know binary is linked to a shared library, but the binary is big and no dynamic link sign (ldd) $ cc -I$HOME/include stol.c -o stol -L/usr/local/lib -Xlinker -Bdynamic -lccs -lm $ ll stol -rwxr-xr-x  1 jin  wheel  229130 Oct 12 16:49 stol* $ ldd stol stol:         libm.so.5 => /lib/libm.so.5 (0x800854000)         libc.so.7 => /lib/libc.so.7 (0x800a84000) # move .ax back to .a and try static link $ cc -I$HOME/include stol.c -o stol -L/usr/local/lib -Xlinker -Bstatic -lccs -lm $  ll stol -rwxr-xr-x  1 jin  wheel  13855 Oct 12 16:56 stol* $ ldd stol stol:         libm.so.5 => /lib/libm.so.5 (0x800824000)         libc.so.7 => /lib/libc.so.7 (0x800a54000) From owner-freebsd-questions@freebsd.org Tue Oct 13 11:19:28 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BEB2F43DC37 for ; Tue, 13 Oct 2020 11:19:28 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9Y3M6KQlz4YyP for ; Tue, 13 Oct 2020 11:19:27 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 04CA15C00E0 for ; Tue, 13 Oct 2020 07:19:27 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Tue, 13 Oct 2020 07:19:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zyxst.net; h= date:from:to:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm3; bh=daIOBWqlHwyTE/2VAyRrysiV8YQ tyGFzSt4CfgW220Y=; b=JQKJ61n6L9Wn/YzwsLrNYoVra+Z9XLNymrSRxeQMg9D UOVRRVNeHDUV8Gwuy1Zz30cNJZcimOim0SsIaEdSzrC47YzYOqdylNknFs4PHK7q uXx8FAOnlj1oLsrO5BFdYS7n4rzjj7cCRybuCnjiuJgGJuZAI7m2JTngDdjw6l2K MdQuBKlE1z5BBjNqhW5UhVEZrOg7J0iR2gTmWatGIUQxg+3YYOL2VQ4ZfF1ky89Q GTVxfsJ1GgvwT3f+CypZzcWZgHtjhg6Jllmq8QgtzFU/j4jHwx25SdKGTaOjyPPO PYmx8ZVjV0tJMjBb6avfkEpU6qVaA7GtSDrDrtJQ0Mg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=daIOBW qlHwyTE/2VAyRrysiV8YQtyGFzSt4CfgW220Y=; b=rTJd4pLe4qKKuVKunLVVre 9jgkwxG16Kwm/5appVxiMaYlx+6KV+0VXGBXPxzlXKVWOkpEvqtiWwXBFRkViJXL +qVHXTyUWFIF0rWmCscdGv4uOo64cywd5xjjb5x4j9uUs6FcXTnnu73dG/wddAXa 44qCPKciwDv0bJR//bnJ6zYapteK2fFCIR+bXT3/GR4EQAiQW0BZCkq/iezPStoX G/9qtxuQo34E7rftY7gUU/HVBvkwfb63FP0XNFLKMF6DYCkm2Ilv6Xhd8u53GOks nJ44anw3OEJ+jOgQBz6gzQj7DIkzzHQ75CdA2GYFNAewJkO9+qz99Far5MvwG7DA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrheelgdefkecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurhepfffhvffukfhfgggtuggjsehgtderre dttddvnecuhfhrohhmpehtvggthhdqlhhishhtshcuoehtvggthhdqlhhishhtshesiiih gihsthdrnhgvtheqnecuggftrfgrthhtvghrnheptdehiefgvddufeekkedvtdefvdettd dtkeduvdegveelffdtkeffudejvdfhudetnecukfhppeekvddrjedtrdeluddruddtvden ucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehtvggthh dqlhhishhtshesiiihgihsthdrnhgvth X-ME-Proxy: Received: from rpi4.gilescoppice.lan (axs-0-ipv4.zyxst.net [82.70.91.102]) by mail.messagingengine.com (Postfix) with ESMTPA id 190E4328005E for ; Tue, 13 Oct 2020 07:19:26 -0400 (EDT) Date: Tue, 13 Oct 2020 12:19:23 +0100 From: tech-lists To: freebsd-questions@freebsd.org Subject: Re: errors happening with /usr/libexec/save-entropy on 12.1-p10 Message-ID: <20201013111923.GC30207@rpi4.gilescoppice.lan> Mail-Followup-To: freebsd-questions@freebsd.org References: <20201011030537.GA30207@rpi4.gilescoppice.lan> <20201011150940.6d0f5547@gumby.homeunix.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="PuGuTyElPB9bOcsM" Content-Disposition: inline In-Reply-To: <20201011150940.6d0f5547@gumby.homeunix.com> X-Rspamd-Queue-Id: 4C9Y3M6KQlz4YyP X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=zyxst.net header.s=fm3 header.b=JQKJ61n6; dkim=pass header.d=messagingengine.com header.s=fm1 header.b=rTJd4pLe; dmarc=none; spf=pass (mx1.freebsd.org: domain of tech-lists@zyxst.net designates 66.111.4.27 as permitted sender) smtp.mailfrom=tech-lists@zyxst.net X-Spamd-Result: default: False [-5.42 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[zyxst.net:s=fm3,messagingengine.com:s=fm1]; NEURAL_HAM_MEDIUM(-0.98)[-0.977]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[66.111.4.27:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:66.111.4.27]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.96)[-0.956]; RCVD_COUNT_THREE(0.00)[4]; DMARC_NA(0.00)[zyxst.net]; DKIM_TRACE(0.00)[zyxst.net:+,messagingengine.com:+]; NEURAL_HAM_SHORT(-0.78)[-0.783]; SIGNED_PGP(-2.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:11403, ipnet:66.111.4.0/24, country:US]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[66.111.4.27:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 11:19:28 -0000 --PuGuTyElPB9bOcsM Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Oct 11, 2020 at 03:09:40PM +0100, RW via freebsd-questions wrote: >If it fails on 12.1 but not on 12-stable that would imply that >it's a long standing problem and something was fixed in stable. There's >no sign that anything like that happened. > >I think it's unlikely that this is caused by save-entropy. All it >does is dd the output of /dev/random to a file and rotate the files. > >When you say that there's plenty of space, are you allowing for the >fact that the operator user can't write to space reserved for root. Basically, at the time, I put 2+2 together and made 7. The problem=20 wasn't with operator or save-entropy at all. There was a process=20 that maxed out the space when save-entropy ran, just at that=20 particular time, and then tidied up after itself. Fixed the process,=20 fixed the problem. Sorry for the noise! --=20 J. --PuGuTyElPB9bOcsM Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEE8n3tWhxW11Ccvv9/s8o7QhFzNAUFAl+FjTIACgkQs8o7QhFz NAW6hg/+OhA9C3Xs8fmcEr68TyFoZVFVsbeEdPE8R65iTi+YrHT2n/u3LXOHA2Sf yAdRNGglHf2RKpVgju96gjp6E2qM2Ohua5xNHlJTtlZtQYuSo20zpmYcTToYY0iD UnzRiOJKF3YpLWbqrVI39eT66ZkbfoM8kEsbImb/1IqBAPV0+xBUBmVm6bQ8eP6k yquWM5m3ZmV6nqMEmhGOYwEhhBxeQVgmgmMBt0VtAkKcbSbI/fEfltKwev1RMKK7 SihMnebOjVBVF3GyCos2mJ7rSougB7+8GCwgNEBnzv1+CYQhrMVEfZjUXCsahbg+ 15kkHDpp6j+v/Xtqx9Lii1rZdfU73CLAVaW0cVsQ0wBKgz0u3dkOE/Fp7KIt8ggE vPTlVY14RWE/K23CX/3Akf6crLU60zB8F03gKsh8aL+6MtPxGpOh9eWBDyDJ/Mr5 cNqbaLI0EB7XcYwBixoZTji6evJm75qSKFj5bBKJgzHL0Y2UN7QRbNwUywDoVvji CtC/cZYsd1NPZvUinh0Dwz+OQKisRExzwZyOfpCT9tovwDzPuRLIsW1NjkhkT1Da BTdE8+TClp2VDpt8T3OJUqbqeHqw7J9LNRnt41WNZICBx0wq+oCtC2SNMELw7K/G zjm2gGJx/iFgkYr6Xsz+pnR3eUj/rA+ohZ+MX/KpbMZWtU3Mz4o= =yAJ0 -----END PGP SIGNATURE----- --PuGuTyElPB9bOcsM-- From owner-freebsd-questions@freebsd.org Tue Oct 13 12:16:53 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 94CD7440BEA for ; Tue, 13 Oct 2020 12:16:53 +0000 (UTC) (envelope-from wa5qjh@xmission.com) Received: from out03.mta.xmission.com (out03.mta.xmission.com [166.70.13.233]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9ZKc4wCZz4fbk for ; Tue, 13 Oct 2020 12:16:52 +0000 (UTC) (envelope-from wa5qjh@xmission.com) Received: from in02.mta.xmission.com ([166.70.13.52]) by out03.mta.xmission.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1kSJEX-00CYb8-WF for freebsd-questions@freebsd.org; Tue, 13 Oct 2020 06:16:50 -0600 Received: from [175.176.7.170] (helo=[192.168.7.110]) by in02.mta.xmission.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.87) (envelope-from ) id 1kSJEW-0003Vo-Vh for freebsd-questions@freebsd.org; Tue, 13 Oct 2020 06:16:49 -0600 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable From: wa5qjh Mime-Version: 1.0 (1.0) Date: Tue, 13 Oct 2020 20:16:37 +0800 Message-Id: <28048DED-1A4C-41E7-A1D1-582482285629@xmission.com> To: freebsd-questions@freebsd.org X-Mailer: iPad Mail (17H35) X-XM-SPF: eid=1kSJEW-0003Vo-Vh; ; ; mid=<28048DED-1A4C-41E7-A1D1-582482285629@xmission.com>; ; ; hst=in02.mta.xmission.com; ; ; ip=175.176.7.170; ; ; frm=wa5qjh@xmission.com; ; ; spf=neutral X-XM-AID: U2FsdGVkX1+kFWa8eQLN/5ja92rdPcmG X-SA-Exim-Connect-IP: 175.176.7.170 X-SA-Exim-Mail-From: wa5qjh@xmission.com X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on sa04.xmission.com X-Spam-Level: **** X-Spam-Status: No, score=4.5 required=8.0 tests=ALL_TRUSTED,BAYES_80, DCC_CHECK_NEGATIVE,XMSubMetaSxObfu_03,XMSubMetaSx_00 autolearn=disabled version=3.4.2 X-Spam-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP * 3.3 BAYES_80 BODY: Bayes spam probability is 80 to 95% * [score: 0.8569] * -0.0 DCC_CHECK_NEGATIVE Not listed in DCC * [sa04 1397; Body=1 Fuz1=1 Fuz2=1] * 1.0 XMSubMetaSx_00 1+ Sexy Words * 1.2 XMSubMetaSxObfu_03 Obfuscated Sexy Noun-People X-Spam-DCC: XMission; sa04 1397; Body=1 Fuz1=1 Fuz2=1 X-Spam-Combo: ****;freebsd-questions@freebsd.org X-Spam-Relay-Country: X-Spam-Timing: total 171 ms - load_scoreonly_sql: 0.03 (0.0%), signal_user_changed: 12 (6.8%), b_tie_ro: 11 (6.2%), parse: 0.61 (0.4%), extract_message_metadata: 1.93 (1.1%), get_uri_detail_list: 0.40 (0.2%), tests_pri_-1000: 2.8 (1.6%), tests_pri_-950: 1.03 (0.6%), tests_pri_-900: 0.81 (0.5%), tests_pri_-90: 51 (30.1%), check_bayes: 50 (29.3%), b_tokenize: 3.0 (1.8%), b_tok_get_all: 3.9 (2.3%), b_comp_prob: 1.18 (0.7%), b_tok_touch_all: 39 (22.9%), b_finish: 0.85 (0.5%), tests_pri_0: 87 (50.6%), check_dkim_signature: 0.39 (0.2%), check_dkim_adsp: 2.1 (1.2%), poll_dns_idle: 0.61 (0.4%), tests_pri_10: 1.82 (1.1%), tests_pri_500: 6 (3.6%), rewrite_mail: 0.00 (0.0%) Subject: service mysql start X-Spam-Flag: No X-SA-Exim-Version: 4.2.1 (built Thu, 05 May 2016 13:38:54 -0600) X-SA-Exim-Scanned: Yes (on in02.mta.xmission.com) X-Rspamd-Queue-Id: 4C9ZKc4wCZz4fbk X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=pass (policy=none) header.from=xmission.com; spf=pass (mx1.freebsd.org: domain of wa5qjh@xmission.com designates 166.70.13.233 as permitted sender) smtp.mailfrom=wa5qjh@xmission.com X-Spamd-Result: default: False [-1.61 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; SUBJECT_ENDS_SPACES(0.50)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; ARC_NA(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.98)[-0.982]; RCVD_COUNT_THREE(0.00)[3]; NEURAL_HAM_MEDIUM(-0.87)[-0.874]; R_SPF_ALLOW(-0.20)[+ip4:166.70.13.0/24]; DMARC_POLICY_ALLOW(-0.50)[xmission.com,none]; NEURAL_SPAM_SHORT(0.15)[0.151]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:6315, ipnet:166.70.0.0/16, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[166.70.13.233:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 12:16:53 -0000 Prints Starting mysql. Delays briefly then prints then: then/endif not found And mysql not started. Upon reboot you see in the message then: then/endif not found Indeed, in /usr/local/etc/mysql/mysql-server file there are many "then" but n= o "endif". And I'm just guessing thats where the problem is. I dont really know So, is there a way to start mysql server any other way? I just ran freebsd-update upgrade -r 12.1 from a zfs based 11.2 installatio= n followed by pkg upgrade -f to hopefully bring the system up to a useable 1= 2.1 system. The first time sinceFreeBSD 1.5 to try this. Gary Corell Ya gotta see time beyond the end of your nose= From owner-freebsd-questions@freebsd.org Tue Oct 13 17:25:26 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B57CB446986 for ; Tue, 13 Oct 2020 17:25:26 +0000 (UTC) (envelope-from doug@fledge.watson.org) Received: from cyrus.watson.org (cyrus.watson.org [204.107.128.30]) by mx1.freebsd.org (Postfix) with ESMTP id 4C9j9d6pkDz3ygk for ; Tue, 13 Oct 2020 17:25:25 +0000 (UTC) (envelope-from doug@fledge.watson.org) Received: from fledge.watson.org (fledge.watson.org [198.74.231.63]) by cyrus.watson.org (Postfix) with ESMTPS id 191DD4BD37; Tue, 13 Oct 2020 17:25:25 +0000 (UTC) Received: from fledge.watson.org (doug@localhost [127.0.0.1]) by fledge.watson.org (8.16.1/8.16.1) with ESMTPS id 09DHPOqk068127 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Tue, 13 Oct 2020 17:25:24 GMT (envelope-from doug@fledge.watson.org) Received: from localhost (doug@localhost) by fledge.watson.org (8.16.1/8.16.1/Submit) with ESMTP id 09DHPOsd068124; Tue, 13 Oct 2020 17:25:24 GMT (envelope-from doug@fledge.watson.org) Date: Tue, 13 Oct 2020 17:25:24 +0000 (UTC) From: doug Reply-To: doug@safeport.com To: wa5qjh cc: freebsd-questions@freebsd.org Subject: Re: service mysql start In-Reply-To: <28048DED-1A4C-41E7-A1D1-582482285629@xmission.com> Message-ID: References: <28048DED-1A4C-41E7-A1D1-582482285629@xmission.com> User-Agent: Alpine 2.21.9999 (BSF 287 2018-06-16) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Rspamd-Queue-Id: 4C9j9d6pkDz3ygk X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of doug@fledge.watson.org has no SPF policy when checking 204.107.128.30) smtp.mailfrom=doug@fledge.watson.org X-Spamd-Result: default: False [0.68 / 15.00]; HAS_REPLYTO(0.00)[doug@safeport.com]; SUBJECT_ENDS_SPACES(0.50)[]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_MEDIUM(-0.57)[-0.566]; NEURAL_HAM_LONG(-0.13)[-0.130]; MIME_GOOD(-0.10)[text/plain]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; DMARC_NA(0.00)[watson.org]; AUTH_NA(1.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.13)[-0.127]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:11288, ipnet:204.107.128.0/24, country:US]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 17:25:26 -0000 On Tue, 13 Oct 2020, wa5qjh wrote: > Prints Starting mysql. > Delays briefly then prints > then: then/endif not found > > And mysql not started. Upon reboot you see in the message > then: then/endif not found > Indeed, in /usr/local/etc/mysql/mysql-server file there are many "then" but no "endif". > And I'm just guessing thats where the problem is. I dont really know > > So, is there a way to start mysql server any other way? > I just ran freebsd-update upgrade -r 12.1 from a zfs based 11.2 installation followed by pkg upgrade -f to hopefully bring the system up to a useable 12.1 system. The first time sinceFreeBSD 1.5 to try this. > > Gary Corell > Ya gotta see time beyond the end of your nose First endif is a csh construct. The local rc.d scripts are written in sh and should start with `#!/bin/sh`. That said use `mysqld --verbose --help` to see how to start mysql manually. `man -k mysql` gives more info. As a last resort: https://dev.mysql.com/doc/ :) From owner-freebsd-questions@freebsd.org Tue Oct 13 17:33:28 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3E282446E52 for ; Tue, 13 Oct 2020 17:33:28 +0000 (UTC) (envelope-from hrisikeshsahu@gmail.com) Received: from mail-ed1-x530.google.com (mail-ed1-x530.google.com [IPv6:2a00:1450:4864:20::530]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9jLv3bTKz40N8 for ; Tue, 13 Oct 2020 17:33:27 +0000 (UTC) (envelope-from hrisikeshsahu@gmail.com) Received: by mail-ed1-x530.google.com with SMTP id o18so332011edq.4 for ; Tue, 13 Oct 2020 10:33:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=dYJh65r6PXT7SKI+xRHhhOGsLsDn77j1bqTW77jxFOc=; b=VBeeD7/Z0GAHYdjXQDhGMgbEeqol+z8s/Vi4ekjaOTZqsQfoD6aZYlvD+T4WGvtv2I VfCK82Eki7wcSXfP/JqJWJH+3bUxt5ao2aRVVH/F7F1ZBcqs8mPWW6qe+iOrPVmIHAsu otF63jIBYd2Xo78tKWe9G90a1Fc6xM6Gc+CR25CJbPBo7r8d2CHV/T08+8Y0cQSX1knQ evyxDvZibUOtc2uLU0p41tuph7IJtgg0Jtl53NNHBTbGivvWck8DHfyebw6nMElKp1bU I2qvav9kELaAsfZ58MD4v0yn77mG4bDHQiVz3F/gwsc5tRvzDZc5X58aVz7HLaegP9ps 62wQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=dYJh65r6PXT7SKI+xRHhhOGsLsDn77j1bqTW77jxFOc=; b=NvjFIi4UOBpuIZW2MTurIn/pz+2hJaFw6EEkso/sA0+JoWfn8h4iH0SK+LZh2ToNDd mE8XQ0j9ZM4db/I68RmdvvN4sXAg+q9bsuHuGuxXybOsHUer6MzD0DZh/7LC7kNC3xx2 JjefxTwFo7CtG9XWhH26SZp1Gv+L9QzfyqBWLCuliiPNLpuQgnSRk5ZsqNHxY1oCB78d jBx1u4ERWnetaKy0c5RnHcmrHAkeTlkQtGFcDE1n6iODptwuB2CEGYQYg7rkfyd/IEBx euGRapA+fDSAte1piUE9CSRfGBabPKijAKLoWkYs9Cvvt68L5cC+e6/TNezmt3WzSHiO u0pA== X-Gm-Message-State: AOAM531nzoW5JgCGB0uvWh3Dl/O5cYRu7eo6h2ce9W4nFSvD29USI5xr Otw6IfTYcJwmufmtUdUpkDx2Pf4SO4YGLmgBPySXmD8kq/0ioQ== X-Google-Smtp-Source: ABdhPJwdK8mznOrV9X4evWec0g079ga9Bq18UASNZdkhVsVYp3CsOGWMNLWuyGaB1nL0Nt0lf+0IjtQwdUbrKMH/AvQ= X-Received: by 2002:a50:88a3:: with SMTP id d32mr696923edd.192.1602610405812; Tue, 13 Oct 2020 10:33:25 -0700 (PDT) MIME-Version: 1.0 References: <201310031732.r93HWkSP011234@fire.js.berklix.net> In-Reply-To: <201310031732.r93HWkSP011234@fire.js.berklix.net> From: hrkesh sahu Date: Tue, 13 Oct 2020 23:03:14 +0530 Message-ID: Subject: Re: FreeBSD routing problem To: FreeBSD questions X-Rspamd-Queue-Id: 4C9jLv3bTKz40N8 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=VBeeD7/Z; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of hrisikeshsahu@gmail.com designates 2a00:1450:4864:20::530 as permitted sender) smtp.mailfrom=hrisikeshsahu@gmail.com X-Spamd-Result: default: False [-2.86 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.98)[-0.978]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; RCVD_TLS_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36:c]; FREEMAIL_FROM(0.00)[gmail.com]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_HAM_LONG(-0.99)[-0.988]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::530:from]; NEURAL_SPAM_SHORT(0.11)[0.109]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 17:33:28 -0000 > > Hi All, > I want to enable and run FreeBSD v9.1 as a DHCPv6 server . Could you please suggest and guide me the steps required to enable DHCPv6 server for FreeBSD? I came across Dibbler 0.8.1 release candidate has added support for FreeBSD. Please help me on this. Regards Hrisikesh From owner-freebsd-questions@freebsd.org Tue Oct 13 17:37:55 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BC125446D63 for ; Tue, 13 Oct 2020 17:37:55 +0000 (UTC) (envelope-from hrisikeshsahu@gmail.com) Received: from mail-ej1-x633.google.com (mail-ej1-x633.google.com [IPv6:2a00:1450:4864:20::633]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9jS25BfDz40cc for ; Tue, 13 Oct 2020 17:37:54 +0000 (UTC) (envelope-from hrisikeshsahu@gmail.com) Received: by mail-ej1-x633.google.com with SMTP id p15so947433ejm.7 for ; Tue, 13 Oct 2020 10:37:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=7HWviet8KUrDtwtiEXYHkvEQA7PSQpC8/w/B5BtUn9c=; b=BPdRa+j9jdnIrQJ21tx9BzSy+Zt34cQpq8gCb0OX3/M0rNkIGnNigKkhQFiQjNppMM vdPj2oMoYrdMF13oC4ce4zRe40/vLcFFk6nDxtABv7mQLuiCvIPkMWse0K5hZVx+ooyU ory4QuTUAitL4ZO9HYZuP6PzGnKBuOHfDldLwrJRLZ4HLVexgYx/8XCaRorfLBNKmAjs vXSzgm4Nth09N9lzTa07igdGZEIdWP8dV0NzTDt8qM7utZ2AJ/Y/GhzFGjb+vJOVnQiL 5MDj+isz2p3mBCyCETeaM3fUars7+kVheulPWd0Mn1/pknkRc9RNgmncKrZRokFQQu2S 3uFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=7HWviet8KUrDtwtiEXYHkvEQA7PSQpC8/w/B5BtUn9c=; b=AoESJiqcgSxTr9ATOLWqENsNfoWTjNf8rAcdUVl76gGT3x1MBdpe1Co4dW3Y2BgGNm O/Lw7cFsYf+3uCNoBX/I6gN4ZTirT+eu2pqrCXmgq0s0HFs5xnBPzmXbQs2RwKpFmAbn HC7p26NfZNDF4R9TQr5vkKYP7b0lj2QcRsrTp+rGXH7kbGtkhxkanlpZndAqGS0uO6L6 6ZLH+LsNuy27t6XhYGIXP1x2JDhq1ySWMRfx+iyzhJaJjhTIQgsAoDDfvLAPH+/fJgx2 5FMZOEDOlCqnwpYw+B1cVtk4likk7jN09v84Si5SkJbZgM0CDTUDmxeb7qRd1xSQsdaB q/jA== X-Gm-Message-State: AOAM532P9hDInlcWLkFFv7IOW4x9ZHdIF1Q/nkmcmLOpLo26ho1StzIO C/XhqDd0Ne0cqSrnQ0lg4Ss6M6Dol2oBCmNNboC6LrnUEMZh9Q== X-Google-Smtp-Source: ABdhPJzLFx53n7th6JOy84RxNeSWFiKw1cxxDBpO0UlFqP7iHfrklhW/JijKf/err/FNlGPnrRSW9l0d/IjDH+akXTY= X-Received: by 2002:a17:906:494:: with SMTP id f20mr833077eja.285.1602610672870; Tue, 13 Oct 2020 10:37:52 -0700 (PDT) MIME-Version: 1.0 References: <201310031732.r93HWkSP011234@fire.js.berklix.net> In-Reply-To: From: hrkesh sahu Date: Tue, 13 Oct 2020 23:07:42 +0530 Message-ID: Subject: FreeBSD As a DHCPv6 server To: FreeBSD questions X-Rspamd-Queue-Id: 4C9jS25BfDz40cc X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=BPdRa+j9; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of hrisikeshsahu@gmail.com designates 2a00:1450:4864:20::633 as permitted sender) smtp.mailfrom=hrisikeshsahu@gmail.com X-Spamd-Result: default: False [-2.86 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.98)[-0.978]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; RCVD_TLS_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36:c]; FREEMAIL_FROM(0.00)[gmail.com]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_HAM_LONG(-0.99)[-0.988]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::633:from]; NEURAL_SPAM_SHORT(0.11)[0.109]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 17:37:55 -0000 Hi All, I want to enable and run FreeBSD v9.1 as a DHCPv6 server . Could you please suggest and guide me the steps required to enable DHCPv6 server for FreeBSD? I came across Dibbler 0.8.1 release candidate has added support for FreeBSD. Please help me on this. Regards Hrisikesh > From owner-freebsd-questions@freebsd.org Tue Oct 13 19:05:41 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 18689448CD6 for ; Tue, 13 Oct 2020 19:05:41 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.131]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9lPJ0s34z47bl for ; Tue, 13 Oct 2020 19:05:39 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.31.121]) by mrelayeu.kundenserver.de (mreue010 [212.227.15.167]) with ESMTPA (Nemesis) id 1M3lsh-1kSgb43C3n-000ru2; Tue, 13 Oct 2020 21:05:37 +0200 Date: Tue, 13 Oct 2020 21:05:37 +0200 From: Polytropon To: hrkesh sahu Cc: FreeBSD questions Subject: Re: FreeBSD As a DHCPv6 server Message-Id: <20201013210537.5d29b6c2.freebsd@edvax.de> In-Reply-To: References: <201310031732.r93HWkSP011234@fire.js.berklix.net> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:u3RDdt2TRyMbJXjTItzpzymRj3yVBNY1zrN3OQK612j7eCLlWk7 2iObSt+MMEwGqSgHNFdzNKuxlyhvbqh13lyhnHhLDTlzVZwGxwIpnYyo+zrjdZtnZbC8ovr AWgdCdbEkRaomlIwQAJDA04Hc3qr42Gk2mCq5PsSw3TUQUnseKeK79z8hO4XDwwjfeUEAlc dMJficjvY6IDn6f6NznJA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:7aSQ/dxXl5Y=:QzlAsZ5XPGhDYyURa6JNq6 dGKjKp0LEmOBjiEWd36ys0Zjk5LtopxMoAG0u9EVsCUi7/yqlVvmv3x/e5b89i9qVf3dz6h7s mjbDHpXZ8nFFREYNZdl7kq0LfDi0DV4M50kOoO7qiyhDbJCgXnM8u+AmZXbyh77O+HhMVXfDl KqV6MmMItz8Ws+vJhUKV9I4Zy8tqhNCj2XGr4yR7HgtVniHbn09CZULCz+wa3Otb97WEJffMS JHm7Xi8hNuDC8GkyxsF43siOZFA0X82+Kxo2EhOUqxPTf7u6p6cvaMx0nOgAF3orhBRcBsTay JWu89DtqcCweMBwuw/fI0RsgPhbJvIgJTg3RKIZsb+HagYHv4ZFp+PjoLYPoJFVuvXmvDfBNZ 2ahAOFVhDaVix0gZ+rowG9Iq8zojgEc6jYnAYPtJpZ7Y7HNul/B91A+PhZLQUgNswHQIONYep CkgmsWfihUGKXaNQQUhD3NhcopJZIRgZFWfBytyeE2NvQpDgZIzPdatqcPq9V0o2Vm3GfoX8i myZtJKY3FKJ4VQEF6Ir/fsFGbyonREaWqTlqrC/S/FkB/4AgNd6vuajg42m3l8lwCIPmN4d+x W2Kv51x0P+NZB1h3xUAjaXua2C2feNORafL0zSoyCi3FkCIsS3Wzg+S7hpndrJjHYj0oKy1JD 2yXCuZ/6Ovstmu99qbKFvJcGNsT38sSRBQkLwHtih+nQx1linQqyGSi+cE+LnoZStWS8VHUrD hsq6XAriwdAUYe8KcxB5K4RHQ6C2dtRlB6orKmXmTjSubJuyfxO1CkoOcNxRd7wwIYy+zVRpL 15BOtOuVXyfWBmoQin9tKThI03G/1yNbvkfx4WD9wYSI9Hx6ond2NMmtGQVpVhhu9KCqHJf X-Rspamd-Queue-Id: 4C9lPJ0s34z47bl X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.126.131) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [2.63 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.02)[-0.020]; RCPT_COUNT_TWO(0.00)[2]; FREEMAIL_TO(0.00)[gmail.com]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.31.121:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.52)[-0.524]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.77)[0.775]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.126.131:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.126.131:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 19:05:41 -0000 On Tue, 13 Oct 2020 23:07:42 +0530, hrkesh sahu wrote: > I want to enable and run FreeBSD v9.1 as a DHCPv6 server . Why do you intend to run an outdated or unsupported version of FreeBSD? Is there a good reason for this? If not, consider using the latest RELEASE version for your preferred platform. > Could you please suggest and guide me the steps required to enable DHCPv6 > server for FreeBSD? Maybe the following resources are helpful to you: https://www.freebsd.org/doc/handbook/network-ipv6.html https://www.freebsd.org/doc/handbook/network-dhcp.html Also see "man 5 dhcpd.conf" for configuration details, especially the EXAMPLES section regarding IPv6, or here: https://www.freebsd.org/cgi/man.cgi?query=dhcpd.conf&sektion=5&apropos=0&manpath=FreeBSD+9.0-RELEASE+and+Ports Or those articles: https://subatomicsolutions.org/8-freebsd/17-ipv4-ipv6-isc-dhcp-server-on-a-dual-stack-network https://subatomicsolutions.org/8-freebsd/13-ipv4-ipv6-client-addresses-via-dhcp https://mmacleod.ca/2011/08/ipv6-part-8-configuring-dns-and-dhcpv6-on-an-ipv6-network/ -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Tue Oct 13 19:39:36 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 16B66449C95 for ; Tue, 13 Oct 2020 19:39:36 +0000 (UTC) (envelope-from byrnejb@harte-lyne.ca) Received: from mx32.harte-lyne.ca (mx32.harte-lyne.ca [216.185.71.32]) (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-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mx32.harte-lyne.ca", Issuer "CA_HLL_ISSUER_2016" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9m8R1tDKz4Bhx for ; Tue, 13 Oct 2020 19:39:35 +0000 (UTC) (envelope-from byrnejb@harte-lyne.ca) Received: from mx32.harte-lyne.ca (localhost [127.0.32.1]) by mx32.harte-lyne.ca (Postfix) with ESMTP id AD132210B3 for ; Tue, 13 Oct 2020 15:39:32 -0400 (EDT) X-Virus-Scanned: amavisd-new at harte-lyne.ca Received: from mx32.harte-lyne.ca ([127.0.32.1]) by mx32.harte-lyne.ca (mx32.harte-lyne.ca [127.0.32.1]) (amavisd-new, port 10024) with ESMTP id FWz0oId66oek for ; Tue, 13 Oct 2020 15:39:30 -0400 (EDT) Received: from webmail.harte-lyne.ca (webmail.hamilton.harte-lyne.ca [216.185.71.106]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx32.harte-lyne.ca (Postfix) with ESMTPSA id A14AD210A8 for ; Tue, 13 Oct 2020 15:39:30 -0400 (EDT) Received: from 216.185.71.41 (SquirrelMail authenticated user byrnejb_hll) by webmail.harte-lyne.ca with HTTP; Tue, 13 Oct 2020 15:39:30 -0400 Message-ID: <61ca53922a7b3d135c31030ca2b0f8e0.squirrel@webmail.harte-lyne.ca> Date: Tue, 13 Oct 2020 15:39:30 -0400 Subject: FreeBSD sound problem From: "James B. Byrne" To: freebsd-questions@freebsd.org Reply-To: byrnejb@harte-lyne.ca User-Agent: SquirrelMail/1.4.23 [SVN] MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal X-Rspamd-Queue-Id: 4C9m8R1tDKz4Bhx X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.82 / 15.00]; HAS_REPLYTO(0.00)[byrnejb@harte-lyne.ca]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:216.185.71.0/26]; REPLYTO_ADDR_EQ_FROM(0.00)[]; RCVD_DKIM_ARC_DNSWL_MED(-0.50)[]; TO_DN_NONE(0.00)[]; RCVD_IN_DNSWL_MED(-0.20)[216.185.71.32:from]; DKIM_TRACE(0.00)[harte-lyne.ca:+]; HAS_X_PRIO_THREE(0.00)[3]; NEURAL_HAM_SHORT(-0.09)[-0.086]; DMARC_POLICY_ALLOW(-0.50)[harte-lyne.ca,quarantine]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:12021, ipnet:216.185.64.0/20, country:CA]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999]; RCVD_COUNT_FIVE(0.00)[5]; R_DKIM_ALLOW(-0.20)[harte-lyne.ca:s=dkim_hll]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.03)[-1.033]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[harte-lyne.ca:dkim]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 19:39:36 -0000 I have a problem with the sound on my workstation. It works fine immediately after booting and then stops. Dmesg shows this: [root@vhost01 ~ (master)]# dmesg | grep pcm pcm0: at nid 4 on hdaa0 pcm1: at nid 5 on hdaa0 pcm2: at nid 20,22,21 and 24,26 on hdaa1 pcm3: at nid 27 and 25 on hdaa1 pcm4: at nid 30 on hdaa1 pcm2: chn_write(): pcm2:virtual:dsp2.vp1: play interrupt timeout, channel dead pcm0: at nid 4 on hdaa0 pcm1: at nid 5 on hdaa0 pcm2: at nid 20,22,21 and 24,26 on hdaa1 pcm3: at nid 27 and 25 on hdaa1 pcm4: at nid 30 on hdaa1 The dead channel corresponds to the audio jack on the back of the system into which my speakers are plugged. It also corresponds to the contents of /dev/sndstat cat /dev/sndstat Installed devices: pcm0: (play) pcm1: (play) pcm2: (play/rec) default pcm3: (play/rec) pcm4: (play) No devices installed from userspace. >From my research this appears to be a recurrent bug but I cannot make any of the suggested remedies work. Any assistance with this is greatly appreciated. Regards, -- *** e-Mail is NOT a SECURE channel *** Do NOT transmit sensitive data via e-Mail Unencrypted messages have no legal claim to privacy Do NOT open attachments nor follow links sent by e-Mail James B. Byrne mailto:ByrneJB@Harte-Lyne.ca Harte & Lyne Limited http://www.harte-lyne.ca 9 Brockley Drive vox: +1 905 561 1241 Hamilton, Ontario fax: +1 905 561 0757 Canada L8E 3C3 From owner-freebsd-questions@freebsd.org Tue Oct 13 19:42:56 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DD12F44987C for ; Tue, 13 Oct 2020 19:42:56 +0000 (UTC) (envelope-from jerry@seibercom.net) Received: from mail-pj1-x102d.google.com (mail-pj1-x102d.google.com [IPv6:2607:f8b0:4864:20::102d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9mDJ13lGz4CRb for ; Tue, 13 Oct 2020 19:42:55 +0000 (UTC) (envelope-from jerry@seibercom.net) Received: by mail-pj1-x102d.google.com with SMTP id az3so529283pjb.4 for ; Tue, 13 Oct 2020 12:42:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=seibercom.net; s=google; h=date:from:to:subject:message-id:reply-to:organization:mime-version; bh=RWwVjTLOil6owrQtcE0sAkWaHl+/EuUUefFs0lLNFH8=; b=aVb61F2Gt8mPsHcXXpkhjXa+UTGWuj2ipIt3BsX7fcQC83RJzgWrv3wZSWNPzu+TbN l3HM+8LOeYdwve7BS770OtQqNmUiQAgYKkkfa4yvew26EoFLGcAitBH/uDXTX52D9o1J ZdW/Ea+q7iatK8KowzfjCio++Cj1eoPsFRdAM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:reply-to :organization:mime-version; bh=RWwVjTLOil6owrQtcE0sAkWaHl+/EuUUefFs0lLNFH8=; b=kndkSzqO78pumLQpuc/OvYTtRz2iVcL/9Bdmfij4d2H5JuDs7CfMqwTQV3E8JSdZti 31r9CGspNi5XuhroI0XTKWip/lh952owSic1jgRb0JMVICPDAG/F/KZCTi3b9G5ov3V4 F+vCVRZqeHWPL6YBf1XUkKF67OhEzdPgVY9rQuu1JYYPsgkKzzuvjbanB2QrVwwUhuBH 5NoyaH0oX+Zphc/zXhhBv3++xGcFFPE32SxVOOu2P6dSjgJBsHfjT7ZY3BeD+FeND2Tr 1z9fW15nCAfNAcmUAPPTNoSR6dFOu1eRJ7XM6sCQ5g4qpKk6hNyqVdtt41rTtssTI5QU JsjQ== X-Gm-Message-State: AOAM532DcmrnL0/eS1yhwR6RTOvFc7C8dYrgmdLuZHy3mPqCMbj3GPb9 85QrFwpIF1198pHPFTmSd15xgpeRQN1t2g== X-Google-Smtp-Source: ABdhPJyNhHtX4D7G0Jv1c0gSnhkXzm2WPc4ST2Zb2T/GJXwynhFHSAcTZRBz8GNJJQXHccJrRnTaVg== X-Received: by 2002:a0c:916d:: with SMTP id q100mr1526795qvq.8.1602617722132; Tue, 13 Oct 2020 12:35:22 -0700 (PDT) Received: from scorpio.seibercom.net (cpe-174-109-231-236.nc.res.rr.com. [174.109.231.236]) by smtp.gmail.com with ESMTPSA id a69sm339954qkg.136.2020.10.13.12.35.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Oct 2020 12:35:21 -0700 (PDT) Received: from localhost (hp-envy.seibercom.net [192.168.1.102]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: jerry@seibercom.net) by scorpio.seibercom.net (Postfix) with ESMTPSA id 4C9m3W6G6Vz1xxd; Tue, 13 Oct 2020 15:35:19 -0400 (EDT) Date: Tue, 13 Oct 2020 15:35:05 -0400 From: Jerry To: freebsd-questions@freebsd.org, hiroo.ono+freebsd@gmail.com Subject: net/py-wsdd Message-ID: <20201013153505.000068b8@seibercom.net> Reply-To: freebsd-questions@freebsd.org Organization: seibercom.net X-Mailer: Claws Mail 3.17.4 (GTK+ 2.24.32; i686-w64-mingw32) MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; boundary="Sig_/beVtT4ICdTEHTs4g3FJx+n5"; protocol="application/pgp-signature" X-Rspamd-Queue-Id: 4C9mDJ13lGz4CRb X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=seibercom.net header.s=google header.b=aVb61F2G; dmarc=none; spf=pass (mx1.freebsd.org: domain of jerry@seibercom.net designates 2607:f8b0:4864:20::102d as permitted sender) smtp.mailfrom=jerry@seibercom.net X-Spamd-Result: default: False [2.11 / 15.00]; HAS_REPLYTO(0.00)[freebsd-questions@freebsd.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; GREYLIST(0.00)[pass,body]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; TO_DN_NONE(0.00)[]; HAS_ORG_HEADER(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; DKIM_TRACE(0.00)[seibercom.net:+]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.30)[-0.304]; FREEMAIL_TO(0.00)[freebsd.org,gmail.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; REPLYTO_EQ_TO_ADDR(5.00)[]; MID_RHS_MATCH_FROM(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.996]; R_DKIM_ALLOW(-0.20)[seibercom.net:s=google]; RECEIVED_SPAMHAUS_PBL(0.00)[174.109.231.236:received]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.99)[-0.986]; TAGGED_RCPT(0.00)[freebsd]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[seibercom.net]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::102d:from]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 19:42:56 -0000 --Sig_/beVtT4ICdTEHTs4g3FJx+n5 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable FreeBSD 11.4-RELEASE-p4 I recently installed net/py-wsdd. I appears to be working correctly with the exception of this error message that keeps appearing in the system log: Oct 13 15:10:40 scorpio daemon[82272]: 2020-10-13 15:10:40,586:wsdd WARNING= (pid 82273): invalid resolve request: address (urn:uuid:564e424e-4d42-3331-= 3457-040e3ce26a94) does not match own one (urn:uuid:ccceb86e-be3a-5e41-80fb= -8d63f97c1277) I was wondering if anyone can tell me what the problem is. It appears to be a harmless one, just a useless warning, but I would like to make sure. --=20 Jerry --Sig_/beVtT4ICdTEHTs4g3FJx+n5 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEEIQb/tTwl6I1ueEVtOHMGOIfexWQFAl+GAW4ACgkQOHMGOIfe xWTOHQf7BspkxSw3/QEeWWqvRnobc9Z3fwt8vGHFcL/8bXMqTF39PhI4aTWy+LnN lPk0xSGfMnh+8ED1O5R9w0hsRVAaOsk6psWGqaTnNafJdJFTm7uBic+gqxCgyuZt abSDLas/v2/RtMBb7m8j5Nhz8jrAfHZ9IMwmSlmcn3+wVmKnLRUrGNOkBx2EWM5F md+8MhlrlTet3zBrNIzqVRqpLpyfX++im0zRGGTDf1uuhSym6zRHlFGaKKANBb8C EIue4CsYuwGGKQuTxBCXOKs9SyZTwW6iu3kv8+UDHSL2upqJSf0u8rbgZUD8nM/c RRoecbXWKIJocB4CCNDYN5mi0txxOw== =GgpR -----END PGP SIGNATURE----- --Sig_/beVtT4ICdTEHTs4g3FJx+n5-- From owner-freebsd-questions@freebsd.org Tue Oct 13 20:13:47 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id EFEB944A93E for ; Tue, 13 Oct 2020 20:13:47 +0000 (UTC) (envelope-from hiroo.ono@gmail.com) Received: from mail-ot1-x335.google.com (mail-ot1-x335.google.com [IPv6:2607:f8b0:4864:20::335]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4C9mvt6tkSz4DlX for ; Tue, 13 Oct 2020 20:13:46 +0000 (UTC) (envelope-from hiroo.ono@gmail.com) Received: by mail-ot1-x335.google.com with SMTP id l4so1271218ota.7 for ; Tue, 13 Oct 2020 13:13:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:reply-to:from:date:message-id :subject:to; bh=hxTlWGcn6zXxWgp7jBnB28tnKM1EzNioBk8LgpDyfSg=; b=Qg8yzFD2esE1dk52oUq1pXNRfmbaglLANs4uqzTQnHhHwRolAtGQBummHhzKPXvM30 OrIAV/tvh44NFk1TjGHlDwzU7e4tOn1HDHa/uBosdNxRNnZrTjUd98xFRW5pCFTps0Yz ukGWOoYLfodFJxyCMTpJVdmDsfiwZuhWXVVh7XlsAV5jGGqhXHU5xriShpasoZgyn6ca z4Ho2K5SCmZ+45Pm526/8q8OPGlr8D0H5H6sog1+Z8lWlJCLkN38ZLqnERQehMw4F4EE AYSkQcrau+fHIyrvQ/C8LFhpVBFN+Cxy/lma+6Cfo9hxfIFYDu+0jysi5ErlX/PaMRWZ 3y5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:reply-to :from:date:message-id:subject:to; bh=hxTlWGcn6zXxWgp7jBnB28tnKM1EzNioBk8LgpDyfSg=; b=C9IX70ticqTxf0VWOzyi9CrWB9jtp8tgwLY2z4qlHwUincrtM498nMZ23frSQpHQ7m 35KzYnu5KSjqDKWr6G+zzRrnOUdQPEjt8b6i6jMOLLcrkJLaj1sq1J9oaW0lCPfe/7Xd uQajwBAC/hxP8Bwn/NGCR1jCnvRCIo46775l1UTH+SEDccceoMbeFaLXWKXBIq1UY2xk xxtAPmJzrTkeCIrxfnkmq4KxC95EdJSU15fW+YkdSL81yv5kupSZK3PTrm2MeXueFu0V wqrNTaQecO7/tVbBrKF68OTS+naPxjNETljxuI8BmdJspdkMFYj/hrNxrEBPpi6Xfhi4 3y1w== X-Gm-Message-State: AOAM532L5ZxviSSkyQwDU8K8ZuIfdCBKweSN896PDGnhPg7kIoPEaOls +4JuDwNvwxlcDw+0/AANFqXNV5qqvqKiY23XwDfqkomRr9c= X-Google-Smtp-Source: ABdhPJyEMEw6smzUQME8m+SOQ/gmrvw7HcEs9aDTgOWhot6MQUhsjjioC64t2u6Ftwvljf2bNKTjR1iILZa9U3G87s0= X-Received: by 2002:a9d:1e85:: with SMTP id n5mr948062otn.246.1602620025362; Tue, 13 Oct 2020 13:13:45 -0700 (PDT) MIME-Version: 1.0 References: <20201013153505.000068b8@seibercom.net> In-Reply-To: <20201013153505.000068b8@seibercom.net> Reply-To: hiroo.ono+freebsd@gmail.com From: =?UTF-8?B?SGlyb28gT25vICjlsI/ph47lr5vnlJ8p?= Date: Wed, 14 Oct 2020 05:13:34 +0900 Message-ID: Subject: Re: net/py-wsdd To: freebsd-questions@freebsd.org X-Rspamd-Queue-Id: 4C9mvt6tkSz4DlX X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=Qg8yzFD2; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of hirooono@gmail.com designates 2607:f8b0:4864:20::335 as permitted sender) smtp.mailfrom=hirooono@gmail.com X-Spamd-Result: default: False [-2.39 / 15.00]; HAS_REPLYTO(0.00)[hiroo.ono+freebsd@gmail.com]; FREEMAIL_FROM(0.00)[gmail.com]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; TO_DN_NONE(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; TAGGED_FROM(0.00)[freebsd]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.96)[-0.962]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.99)[-0.989]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; FREEMAIL_REPLYTO(0.00)[gmail.com]; REPLYTO_DOM_EQ_FROM_DOM(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_SPAM_SHORT(0.57)[0.565]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::335:from]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 20:13:48 -0000 It is harmless. See the explanation here. https://github.com/christgau/wsdd/issues/53 2020=E5=B9=B410=E6=9C=8814=E6=97=A5(=E6=B0=B4) 4:35 Jerry : > FreeBSD 11.4-RELEASE-p4 > > I recently installed net/py-wsdd. I appears to be working correctly > with the exception of this error message that keeps appearing in the > system log: > > Oct 13 15:10:40 scorpio daemon[82272]: 2020-10-13 15:10:40,586:wsdd > WARNING(pid 82273): invalid resolve request: address > (urn:uuid:564e424e-4d42-3331-3457-040e3ce26a94) does not match own one > (urn:uuid:ccceb86e-be3a-5e41-80fb-8d63f97c1277) > > I was wondering if anyone can tell me what the problem is. It appears > to be a harmless one, just a useless warning, but I would like to make > sure. > > -- > Jerry > From owner-freebsd-questions@freebsd.org Wed Oct 14 05:09:42 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 711C942C5F7 for ; Wed, 14 Oct 2020 05:09:42 +0000 (UTC) (envelope-from SRS0=BQzi=DV=mail.sermon-archive.info=doug@sermon-archive.info) Received: from mail.sermon-archive.info (sermon-archive.info [71.177.216.148]) by mx1.freebsd.org (Postfix) with ESMTP id 4CB0pF4vxcz4gsJ for ; Wed, 14 Oct 2020 05:09:41 +0000 (UTC) (envelope-from SRS0=BQzi=DV=mail.sermon-archive.info=doug@sermon-archive.info) Received: from [10.0.1.251] (mini [10.0.1.251]) by mail.sermon-archive.info (Postfix) with ESMTPSA id 4CB0p65X3kz2fjPy for ; Tue, 13 Oct 2020 22:09:34 -0700 (PDT) From: Doug Hardie Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: pf with IP options Message-Id: <1EA79E0D-B66B-44CD-9F9A-14D20B3BA983@mail.sermon-archive.info> Date: Tue, 13 Oct 2020 22:09:34 -0700 To: FreeBSD Mailing List X-Mailer: Apple Mail (2.3445.104.17) X-Virus-Scanned: clamav-milter 0.101.4 at mail X-Virus-Status: Clean X-Rspamd-Queue-Id: 4CB0pF4vxcz4gsJ X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of SRS0=BQzi=DV=mail.sermon-archive.info=doug@sermon-archive.info designates 71.177.216.148 as permitted sender) smtp.mailfrom=SRS0=BQzi=DV=mail.sermon-archive.info=doug@sermon-archive.info X-Spamd-Result: default: False [-2.21 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.96)[-0.959]; FROM_HAS_DN(0.00)[]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[lafn.org: no valid DMARC record]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.95)[-0.954]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.89)[-0.892]; R_SPF_ALLOW(-0.20)[+ip4:71.177.216.148]; FORGED_SENDER(0.30)[bc979@lafn.org,SRS0=BQzi=DV=mail.sermon-archive.info=doug@sermon-archive.info]; RCVD_NO_TLS_LAST(0.10)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:5650, ipnet:71.177.216.0/23, country:US]; FROM_NEQ_ENVFROM(0.00)[bc979@lafn.org,SRS0=BQzi=DV=mail.sermon-archive.info=doug@sermon-archive.info]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 05:09:42 -0000 pf by design drops packets with IP options. I am seeing quite a few of = those packets on one of my systems. Is there a way to tell pf to log = those packets and if so, how do I identify them in the tcpdump output? -- Doug From owner-freebsd-questions@freebsd.org Wed Oct 14 09:04:08 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 6CF8D431E70 for ; Wed, 14 Oct 2020 09:04:08 +0000 (UTC) (envelope-from ml@netfence.it) Received: from soth.netfence.it (net-2-44-121-52.cust.vodafonedsl.it [2.44.121.52]) (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-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mailserver.netfence.it", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CB60l0QYkz4v0h for ; Wed, 14 Oct 2020 09:04:06 +0000 (UTC) (envelope-from ml@netfence.it) Received: from alamar.ventu (alamar.local.netfence.it [10.1.2.18]) (authenticated bits=0) by soth.netfence.it (8.16.1/8.15.2) with ESMTPSA id 09E93vq5006405 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NO) for ; Wed, 14 Oct 2020 11:03:58 +0200 (CEST) (envelope-from ml@netfence.it) X-Authentication-Warning: soth.netfence.it: Host alamar.local.netfence.it [10.1.2.18] claimed to be alamar.ventu From: Andrea Venturoli Subject: A couple of questions about SSDs To: freebsd-questions@freebsd.org Message-ID: Date: Wed, 14 Oct 2020 11:03:57 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:78.0) Gecko/20100101 Thunderbird/78.3.2 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CB60l0QYkz4v0h X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=pass (policy=none) header.from=netfence.it; spf=pass (mx1.freebsd.org: domain of ml@netfence.it designates 2.44.121.52 as permitted sender) smtp.mailfrom=ml@netfence.it X-Spamd-Result: default: False [-3.09 / 15.00]; RCVD_TLS_ALL(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:2.44.121.52]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; HAS_XAW(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.03)[-1.029]; TO_DN_NONE(0.00)[]; NEURAL_HAM_SHORT(-0.30)[-0.298]; DMARC_POLICY_ALLOW(-0.50)[netfence.it,none]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.97)[-0.966]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:30722, ipnet:2.44.0.0/16, country:IT]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 09:04:08 -0000 Hello. I've heard people say that Windows will soon wear an SSD out unless you turn swap off. While I don't believe that 100%, is there any reccomendation wrt to FreeBSD swap in an SSD only install? Is anyone using Poudriere on SSDs? Are there any measures of the impact on wear? bye & Thanks av. From owner-freebsd-questions@freebsd.org Wed Oct 14 09:32:21 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7A641432F71 for ; Wed, 14 Oct 2020 09:32:21 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from slave.jschneider.net (slave.jschneider.net [46.235.226.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CB6dJ4gJLz3TQX for ; Wed, 14 Oct 2020 09:32:20 +0000 (UTC) (envelope-from freebsd@jschneider.net) X-Disposition: Mostly harlmess; Wed, 14 Oct 2020 10:32:04 +0100 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.7\)) Subject: Re: A couple of questions about SSDs From: Jon Schneider In-Reply-To: Date: Wed, 14 Oct 2020 10:32:02 +0100 Cc: freebsd-questions@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: <47D774C9-76A9-431E-8A40-9C6D03D9F56F@jschneider.net> References: To: Andrea Venturoli X-Mailer: Apple Mail (2.3445.9.7) X-Rspamd-Queue-Id: 4CB6dJ4gJLz3TQX X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of freebsd@jschneider.net designates 46.235.226.89 as permitted sender) smtp.mailfrom=freebsd@jschneider.net X-Spamd-Result: default: False [-2.70 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.004]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:46.235.226.89]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[jschneider.net]; NEURAL_HAM_LONG(-0.97)[-0.975]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.92)[-0.922]; RCPT_COUNT_TWO(0.00)[2]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:44684, ipnet:46.235.224.0/21, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 09:32:21 -0000 > I=E2=80=99ve heard people say that Windows will soon wear an SSD out = unless you turn swap off. It depends on the amount of swapping vs. the device=E2=80=99s endurance = obviously. You should see what it does to performance AND monitor the wear through = the smartctl tool or equivalent and decide for yourself. (For Windows (and DragonFlyBSD ?) there=E2=80=99s the ReadyBoost feature = that could work if you have a load of memory sticks kicking about.) Jon From owner-freebsd-questions@freebsd.org Wed Oct 14 09:35:17 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 842B5433653 for ; Wed, 14 Oct 2020 09:35:17 +0000 (UTC) (envelope-from freebsd-questions@m.gmane-mx.org) Received: from ciao.gmane.io (static.214.254.202.116.clients.your-server.de [116.202.254.214]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CB6hh6DHRz3Tpp for ; Wed, 14 Oct 2020 09:35:16 +0000 (UTC) (envelope-from freebsd-questions@m.gmane-mx.org) Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1kSd6j-0006yQ-2P for freebsd-questions@freebsd.org; Wed, 14 Oct 2020 11:30:05 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Ottavio Caruso Subject: Re: A couple of questions about SSDs Date: Wed, 14 Oct 2020 10:29:57 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1 In-Reply-To: Content-Language: en-GB X-Rspamd-Queue-Id: 4CB6hh6DHRz3Tpp X-Spamd-Bar: +++++++ X-Spamd-Result: default: False [7.50 / 15.00]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; ARC_NA(0.00)[]; NEURAL_SPAM_SHORT(0.23)[0.228]; GREYLIST(0.00)[pass,body]; FROM_HAS_DN(0.00)[]; FREEMAIL_FROM(0.00)[yahoo.com]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; NEURAL_HAM_LONG(-0.20)[-0.205]; HFILTER_HOSTNAME_5(3.00)[static.214.254.202.116.clients.your-server.de]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_MEDIUM(-0.52)[-0.523]; RCVD_TLS_LAST(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; DMARC_POLICY_REJECT(2.00)[yahoo.com : SPF not aligned (relaxed), No valid DKIM,reject]; FORGED_SENDER(0.30)[ottavio2006-usenet2012@yahoo.com,freebsd-questions@m.gmane-mx.org]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:24940, ipnet:116.202.0.0/16, country:DE]; FROM_NEQ_ENVFROM(0.00)[ottavio2006-usenet2012@yahoo.com,freebsd-questions@m.gmane-mx.org]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_COUNT_TWO(0.00)[2] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 09:35:17 -0000 On 14/10/2020 10:03, Andrea Venturoli wrote: > Hello. > > I've heard people say that Windows will soon wear an SSD out unless you > turn swap off. > While I don't believe that 100%, is there any reccomendation wrt to > FreeBSD swap in an SSD only install? > > Is anyone using Poudriere on SSDs? Are there any measures of the impact > on wear? Id you have enough RAM, you don't need swap, or you can put swap on a second HDD, where you can also put large files that you don't need often. -- Ottavio Caruso From owner-freebsd-questions@freebsd.org Wed Oct 14 09:36:48 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E3E914336BD for ; Wed, 14 Oct 2020 09:36:48 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CB6kR509Xz3V4Y for ; Wed, 14 Oct 2020 09:36:47 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.19.154]) by mrelayeu.kundenserver.de (mreue009 [212.227.15.167]) with ESMTPA (Nemesis) id 1N0X4e-1kE8fI0kPE-00wSsT; Wed, 14 Oct 2020 11:36:36 +0200 Date: Wed, 14 Oct 2020 11:36:35 +0200 From: Polytropon To: Andrea Venturoli Cc: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-Id: <20201014113635.ce39d02e.freebsd@edvax.de> In-Reply-To: References: Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:9az4S/tS5968YMc9OWqhj5632+kURjptElaXHCq4kiOVGAZaT3S PkSWffhdXSJbcCP0Xs2etijDkSsbNZZGW/00Un8CHuF8RwScpn0ko3eJT/r/DtfLY18TBqG ahWP56rLavB8QFfBH8bzdhppR5eTK3ArWx5cgSObJq5ZoTsu5F16mBs2ATo55kAVQWe6i4T 3ka+mpYghVi1/LRC7NQpw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:VmCpucmdu60=:4eKoevtHyg74OlWgpXAUfW poMj5CVTlbXOxXkEqjtrCZ1xcIS7RYkcw6Z4s7dMK+anlSmNwua2l+3UgPbHR1YM7sNXFcCrd epnuj1bFUPutjhUT+/lZFEHE+0BKJpJV/57NDzkJXK2N1lk83byHirbnnaGWpLGqDYLCU8mNz HH2c4VXAAJjY6TTUMvOmMH6LA9AycYFr9DUbG9X+w3Wc8KzCPhug4kcy9/UljUlQ13mCRGShW QWzEyqfZi525DReHKMPiCbjiuSSBYe+qezvegguYXFuB7Zc9b8fEJRwBvV6/anJmkTMzxCH7N HamG4W46gTUVkkqe3zObn9VAri2g6vB/BBhdaUMC71zzMqlyz84g6qGY8R1QpHa/Ycqynib16 CvD9TtVfUNunscHOf0ujwBvsqYSY49EPRFgaou+K/PlFpETh4W/QM2SSoGpRaMc0TpT8CR1os H8++8gFCsRUhq0vw1+dEoLbAGTEAR5+M3t0mJLbGgTUk89EDDgf/opMoIhUiY7vIm36uZ6CoP PL69ZMP1s/SqB5UkxqRiataC/N5J5rUe68ctsyE2EfpdyrvAVbmQIDGRv2MjPxJ6AJHZ1rstn oe25BVXA2MRWwvBpFqEnqAXRJQePHNbwQNwaLFK66Ic6oPkzIUnLaLR0mgm+ZgptRIbWrC8h9 glDFmjFhCrXaqkyPEF2i4aNR1wDo3J3EsRvQ21KbmmWoUWvlVnsPXlQkiMBDl6nv40FPvfyOl nuf4bZdqTWnFLwaEJywQUkOk9j8P0FZC+hY3LCKVrD0nJcEWiFGaBfwkB0Tf8r1AUfzUj/vdS XjOlo0qGlwg3Fy0bHLpGoAM4LvIixcyVj81G/yjjXPGVDZi8aR1bIoAuh/k1HmCSN4Ix1pr5d +Gr8wXF3pg/nGBKOAqRQqs5PxWe0+Uuup9R5oLKCc= X-Rspamd-Queue-Id: 4CB6kR509Xz3V4Y X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.126.133) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [1.09 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.19.154:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.49)[-0.489]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_SPAM_SHORT(0.02)[0.019]; NEURAL_HAM_LONG(-0.84)[-0.839]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.126.133:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.126.133:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 09:36:48 -0000 On Wed, 14 Oct 2020 11:03:57 +0200, Andrea Venturoli wrote: > I've heard people say that Windows will soon wear an SSD out unless you > turn swap off. > While I don't believe that 100%, is there any reccomendation wrt to > FreeBSD swap in an SSD only install? It's not about swap, it's about write access in general. That write access depends on what programs you run on your machine, or specific to "Windows", what programs MICROS~1 intends to download, install, and run on "your" PC. :-) Regarding swap, using a regular swap partition is not a problem: If nothing writes to it, it won't affect wear. My first experience with a SSD-only install in a laptop was to use a file-backed swap space, again with the advantage that space wasn't allocated and written to until needed. In /etc/rc.local: SWAP="/ssdswap" /bin/rm -f $SWAP /bin/dd if=/dev/zero of=$SWAP bs=16m seek=500 count=0 /sbin/mdconfig -a -t vnode -u 0 -f $SWAP || /bin/sh /bin/chflags nodump $SWAP /bin/rm $SWAP /sbin/swapctl -a /dev/md0 echo -n " swap" And in /etc/rc.shutdown.local: /sbin/swapctl -d /dev/md0 > /dev/null 2>&1 /sbin/mdconfig -d -u 0 echo -n " swap" As this was an older laptop with only 4 GB (or 2 GB?) of RAM, I thought that it wouldn't hurt to have swap available if urgently needed. So far occassional monitoring in htop didn't show any excessive swap usage. Today I'd probably go with a regular swap partition, as SSDs become bigger and cheaper. > Is anyone using Poudriere on SSDs? Are there any measures of the impact > on wear? No, I'm still using rotating rust for that. ;-) But you're absolutely thinking into the right direction: Running poudriere causes a lot of writes, it's not just limited to swap (which gets activated only if RAM is full). During ports building, lots of files are being written, and _that_ probably is the significant question here. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Wed Oct 14 10:15:08 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3179043490C for ; Wed, 14 Oct 2020 10:15:08 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CB7Zg33rSz3Wx0 for ; Wed, 14 Oct 2020 10:15:07 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CB7ZT2Sx4zFpGt for ; Wed, 14 Oct 2020 03:14:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602670497; bh=5F5bU0Uw0BCwCCbyc2U19Be/S/R7v7p0CGVn1tnyvVM=; h=Date:From:To:Subject:In-Reply-To:References:From; b=BWgtYltApac6S0rG2K3G0pczbhAjJJe6xCtSy8wJbNAJhmIlYMr8H20Fm/x7gtEm0 A3Ngw/ONRx3NZxvnusAtYyuUtKXs6AiW3POT1siKNpesAtsho74y/h/sIsACd3XVsE 5Ik5v4oNthP+G2FmCaOyJ3VMCgM+DOO3Q568kMY8= X-Riseup-User-ID: 9DA77FD54996DAEFA4E3B890EDA93041C30E35CBB4FDA989C53B52AB87C99C98 Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4CB7ZS4zm7z8w8c for ; Wed, 14 Oct 2020 03:14:52 -0700 (PDT) Date: Wed, 14 Oct 2020 12:14:42 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201014121442.662e71c4@archlinux> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CB7Zg33rSz3Wx0 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=BWgtYltA; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.39 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.99)[-0.993]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.79)[-0.786]; NEURAL_HAM_LONG(-1.01)[-1.007]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 10:15:08 -0000 On Wed, 14 Oct 2020 11:03:57 +0200, Andrea Venturoli wrote: >I've heard people say that Windows will soon wear an SSD out unless >you turn swap off. >While I don't believe that 100%, is there any reccomendation wrt to >FreeBSD swap in an SSD only install? > >Is anyone using Poudriere on SSDs? Are there any measures of the >impact on wear? Hi, I wonder why I need to read on all computer related mailing list the same questions related to SSDs again and again. For what do we get HDDs or SSDs? We get them for using them. However, there is a very clear answer to your question. Keep the SSD in the original packaging, never use it, this does reduce wear a lot. However, if you decide to use it for read and write operations, you can handle it in the same way as you handle a HDD, just use the trim command from time to time. SSDs don't break after a year, if you use them. They last for years. Non of mine ever failed. Probably SSDs suffer from less wear than HDDs do, time will show us. I'm using HDDs only for backups and to archive data. Handles, light switches, everything wears out. This is the nature of everyday objects, but all those things last for a reasonable time, if you use them. SSDs aren't cheap USB sticks, they are made for modern computers that write and read way more data, than computers did a few years back. Swap is probably never used, but software sizes, picture and video sizes, and other data sizes, professional and home used data increased a lot. What exactly makes you think, that SSDs need gentle treatment? Regards, Ralf From owner-freebsd-questions@freebsd.org Wed Oct 14 10:23:31 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 217DC434A33 for ; Wed, 14 Oct 2020 10:23:31 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CB7mL3sDLz3X9C for ; Wed, 14 Oct 2020 10:23:30 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CB7mF1SRPzFpFN for ; Wed, 14 Oct 2020 03:23:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602671005; bh=Hk9ssed/RpFMBhrxRor35Kg4k+YT+7f383Ppw1QW8Yw=; h=Date:From:To:Subject:In-Reply-To:References:From; b=cpcdv1xTs48BJMzYWoDH0PZQsfk5UTgUnJmeVqZMzbj1O64XvR5xpGtKt+qgC0xp+ 7n5/WBB/Ek03b6kNhni2RFxidEQeIhBdIGrknNGZR87RQFU3U3R5aJP+DmW1Q9xg1C zp9CrM0AIfBYGam7a+IjZ2BI6k35oSmeI4GG5Hrk= X-Riseup-User-ID: E958AF4C89E77929B547671488A96CF35D250765CB54FC71BC7BF16F03FCA7E1 Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4CB7mD3WYSz8vXY for ; Wed, 14 Oct 2020 03:23:24 -0700 (PDT) Date: Wed, 14 Oct 2020 12:23:18 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201014122318.56f4ee4e@archlinux> In-Reply-To: <47D774C9-76A9-431E-8A40-9C6D03D9F56F@jschneider.net> References: <47D774C9-76A9-431E-8A40-9C6D03D9F56F@jschneider.net> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CB7mL3sDLz3X9C X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=cpcdv1xT; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.40 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-1.00)[-0.998]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; R_SPF_ALLOW(-0.20)[+mx:c]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.79)[-0.787]; NEURAL_HAM_LONG(-1.02)[-1.016]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 10:23:31 -0000 On Wed, 14 Oct 2020 10:32:02 +0100, Jon Schneider wrote: >smartctl tool Better use a vendor's tool to do so. The SSD might not be in the smartctl data base at all, or it might not provide correct information. On Linux I'm running the vendor's Linux software, to get smart data, that most likely is correct and to update the firmware, while the SSDs are in use. Mine are cheap Toshiba SSDs. $ sudo ocz-ssd-utility Not all vendor's support FLOSS operating systems, hence I cared for this, before I bought my SSDs. From owner-freebsd-questions@freebsd.org Wed Oct 14 14:27:04 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 8ECDA43B03D for ; Wed, 14 Oct 2020 14:27:04 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: from mail-wm1-x32f.google.com (mail-wm1-x32f.google.com [IPv6:2a00:1450:4864:20::32f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBF9M5sk5z43pf for ; Wed, 14 Oct 2020 14:27:03 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: by mail-wm1-x32f.google.com with SMTP id f21so2482976wml.3 for ; Wed, 14 Oct 2020 07:27:03 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ueY87fw7MmGTzNxparj8OPNU7nQD68VDB0hBE9pTOsU=; b=Oj/uEvgMErc5m1jjuLQemywXmixnmHJKTlRLTqO19Aiqc9mmXVYuYC4qsG2n7ZBUDe xLUQvrRSvPkuR1Wn58OwLIEk5UcqvCT4lkJZn4W9Giumikk4DojOt+iFg2Tc5QTKPqa7 iZY/E0kIiQZ0s7lqC5VTxBdV2e1WNT0o4znJELJJHAV2adzpdaOjjxm8Hc+TLH9cvpuW HZcKMntTjs0wsG8c1Cy2TBGU3FKGw9b98NtNrwGsWBjPT1AH/TED1Mpc3uRUgtWL6sRh huP1cTiFp5z1oUyKOcD6Q7qoA4t+QAHfOFWhh2S1UQ43eEsT9IMjIMum6l9ZIWFa4W6T qEww== X-Gm-Message-State: AOAM531jI8xiOk1xGoWCci5FxsyiAra3IoI0QVcXGI0BOx6IVLBF5PcV aI/jqJCx0DxRK2Nyjzvp1c66EIHzJSjM3w== X-Google-Smtp-Source: ABdhPJwXhfGzOggSfq5e86U5KziMu5wXjTx71fREQuJX+jhA+LaEfManHyMfZ1N0h70KS89UDvIE0Q== X-Received: by 2002:a05:600c:228a:: with SMTP id 10mr3723635wmf.123.1602685621778; Wed, 14 Oct 2020 07:27:01 -0700 (PDT) Received: from gumby.homeunix.com ([2.121.231.131]) by smtp.gmail.com with ESMTPSA id n3sm4099820wmn.28.2020.10.14.07.26.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Oct 2020 07:27:00 -0700 (PDT) Date: Wed, 14 Oct 2020 15:26:57 +0100 From: RW To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201014152657.31e26ece@gumby.homeunix.com> In-Reply-To: <20201014113635.ce39d02e.freebsd@edvax.de> References: <20201014113635.ce39d02e.freebsd@edvax.de> X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; amd64-portbld-freebsd12.1) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBF9M5sk5z43pf X-Spamd-Bar: -- X-Spamd-Result: default: False [-2.60 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; FREEMAIL_FROM(0.00)[googlemail.com]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[googlemail.com:+]; DMARC_POLICY_ALLOW(-0.50)[googlemail.com,quarantine]; RECEIVED_SPAMHAUS_PBL(0.00)[2.121.231.131:received]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[googlemail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; DWL_DNSWL_NONE(0.00)[googlemail.com:dkim]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.97)[-0.973]; R_DKIM_ALLOW(-0.20)[googlemail.com:s=20161025]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.04)[-1.035]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_SPAM_SHORT(0.41)[0.412]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::32f:from]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 14:27:04 -0000 On Wed, 14 Oct 2020 11:36:35 +0200 Polytropon wrote: > > Is anyone using Poudriere on SSDs? Are there any measures of the > > impact on wear? > > No, I'm still using rotating rust for that. ;-) > > But you're absolutely thinking into the right direction: > Running poudriere causes a lot of writes, it's not just > limited to swap (which gets activated only if RAM is full). > During ports building, lots of files are being written, > and _that_ probably is the significant question here. For any port building I do I have the work directory on tmpfs backed by swap. With enough memory this eliminates the non-essential writes to the drive leaving just the install or package writes. I don't know whether it's sensible to do this with poudiere. I gather it relies on ZFS snapshots for efficiency. From owner-freebsd-questions@freebsd.org Wed Oct 14 15:47:57 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E257843C979 for ; Wed, 14 Oct 2020 15:47:57 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.187]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBGyh5K48z49M5 for ; Wed, 14 Oct 2020 15:47:56 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.19.154]) by mrelayeu.kundenserver.de (mreue010 [212.227.15.167]) with ESMTPA (Nemesis) id 1MCsgS-1kbYgv254a-008sj0; Wed, 14 Oct 2020 17:47:49 +0200 Date: Wed, 14 Oct 2020 17:47:49 +0200 From: Polytropon To: Ralf Mardorf Cc: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-Id: <20201014174749.6df7572a.freebsd@edvax.de> In-Reply-To: <20201014121442.662e71c4@archlinux> References: <20201014121442.662e71c4@archlinux> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:i+kwQWTjzDJwCT7oLOhEDi1x6Ua5kSNN/um609In8vwwVF2Zj8T K/yg+zGwARk+Od/5EIY8DcIlPyg2ZQ9zgE4XSTzryDoZoso2iMc+1yeBuUJgxfLoGNA+Z8o FodofHLyFIAlb5R8oU9dkYgrXxMWU2aTk+7SvEL4l4d/6AX7GdLNOSX4qfM+ojl60VwcKIy 8FxEUZOO2cH4eo5fYAdxg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:VpaUrB180zY=:D2fFMBSKVCeGflmnSU8cDH pdjadiq1+4Di1lG6PvZrVczqRF3XLVs81q+z9sweifSZhcURZONVFsXqNtlSUQIKm/HjQ/ksi pyoUto+1U1GS/hrjSHKU6GvAWq5bxmxTEcUNslU1m8p8La5luKeYk9UH87bwiwIITFwiewQ9e tX/GRXhUEzgQcickZhMpMfDj54fxT9N6vQpONO5blClmGHUY/qDn7HDmabCsBtHJTiAxsycq0 StMVtgQnMiK7KpIQasjpYbltRDeDLSPdv0OvKpc6e9MRxdGC7BCFRnPLF7Di/X+4gHvpwgw2S i05+3zfc2COJIgZlvqilLKTEFdo+k96/Q/oGnZYRlxUsKVngyvwKkZg6GOBw3+4R+NobV+q9a xVqN+NRvzkHhgWSEW3Jcfl16e5rYiGo9aEwz4wntg/9aeAOHgSRroqcUgIWMf X-Rspamd-Queue-Id: 4CBGyh5K48z49M5 X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.126.187) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [0.33 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-0.37)[-0.370]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.19.154:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.86)[-0.863]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.84)[-0.838]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.126.187:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.126.187:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 15:47:57 -0000 On Wed, 14 Oct 2020 12:14:42 +0200, Ralf Mardorf wrote: > I wonder why I need to read on all computer related mailing list the > same questions related to SSDs again and again. > > For what do we get HDDs or SSDs? We get them for using them. However, > there is a very clear answer to your question. Keep the SSD in the > original packaging, never use it, this does reduce wear a lot. It actually does - and you don't have to deal with firmware updates. :-) Well, The primary consideration is: Will the wear due to writing to the SSD have significant impact _before_ or _after_ the SSD, maybe along with the system it is installed in, is due for decommissioning? In other words: Will wear make the SSD unusable before its natural "end of life date"? My guess (and it's really just a guess due to my personal lack of any important data and experience) is that the SSD will work until it is replaced by a bigger one, or the whole system it is installed in will be replaced with a faster one. So there is nothing to worry about. If you _really_ want to worry about something, ask the manufacturer if they made the firmware brick the whole thing when a certain write count is reached so you cannot even _read_ your data anymore. :-) > However, if you decide to use it for read and write operations, you can > handle it in the same way as you handle a HDD, just use the trim command > from time to time. UFS supports this. > SSDs don't break after a year, if you use them. They > last for years. Non of mine ever failed. Probably SSDs suffer from less > wear than HDDs do, time will show us. I'm using HDDs only for backups > and to archive data. Quite similar usage here - different SSDs are in use for a few years now, not a single sign of problems so far. > Handles, light switches, everything wears out. This is the > nature of everyday objects, but all those things last for a reasonable > time, if you use them. As long as the light switch doesn't suddenly shout "I've been used 1500 times now, I'm kaputt, please buy a new one!" everything should be okay within the limits of reality. > SSDs aren't cheap USB sticks, they are made for modern computers that > write and read way more data, than computers did a few years back. Swap > is probably never used, but software sizes, picture and video sizes, > and other data sizes, professional and home used data increased a lot. For the case of using lots of "throwaway files" (i. e. stuff you only need as files during ports builds), you can always use a RAM disk, if your system has enough RAM. And swap space that you don't write to doesn't add any wear. > What exactly makes you think, that SSDs need gentle treatment? It's probably the limit on write cycles, but I'm not sure how this compares to general lifetime calculations compared to regular hard disks... -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Wed Oct 14 18:22:24 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2B19543FF66 for ; Wed, 14 Oct 2020 18:22:24 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBLNv1gWhz4Kbn for ; Wed, 14 Oct 2020 18:22:22 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CBLNj1yfnzDsZj for ; Wed, 14 Oct 2020 11:22:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602699733; bh=nvq5UDTsSOTH8isxmrBEFdZ0dyNJfys/5uEI7/ffv68=; h=Date:From:To:Subject:In-Reply-To:References:From; b=Q/W8WfrWAgB4iOOnEq96ZkBxEsUA2VZZs0JhBZo7Dq9O4vihe4hGh1/mD/M+CnNe1 urr3if1XGRurIAjirDZ0GExLrVzZQ8iRC+amSGVyaoJrvzuPHifWGyWNrjumF5P5HI DF2JTYqnnsP/0rqneusdcRzV9o0e8zAuTfcbxKLI= X-Riseup-User-ID: F9A2F3557620BEEE51EE69811187BA7B1FEDCCE25146A2BCB11902ACA6D0CD19 Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4CBLNh4R8wz8trr for ; Wed, 14 Oct 2020 11:22:12 -0700 (PDT) Date: Wed, 14 Oct 2020 20:22:06 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201014202206.7c7886d0@archlinux> In-Reply-To: <20201014174749.6df7572a.freebsd@edvax.de> References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 4CBLNv1gWhz4Kbn X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=Q/W8WfrW; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.03 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.99)[-0.986]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.42)[-0.424]; NEURAL_HAM_LONG(-1.02)[-1.016]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 18:22:24 -0000 On Wed, 14 Oct 2020 17:47:49 +0200, Polytropon wrote: >My guess (and it's really just a guess due to my personal lack >of any important data and experience) is that the SSD will work >until it is replaced by a bigger one, or the whole system it is >installed in will be replaced with a faster one. So there is >nothing to worry about. If you _really_ want to worry about >something, ask the manufacturer if they made the firmware brick >the whole thing when a certain write count is reached so you >cannot even _read_ your data anymore. :-) In my desktop PC are 5 SSDs. Four are connected to the mobos SATA 3 connectors and one is connected to a SATA 2 connector. Four are 223.57 GiB sized and one is 447.13 GiB sized. I'm to lazy to check how old each of them is, but IIRC the oldest is around 3=C2=BD years old and the vendor's software mentions that the "health" is at 64%, the system drive is one of the newer SSDs, maybe around 2 years old, "health" 57%. In my experiences HDDs last for around 2 years, if you turn the computer on and off very often and for around 7 years, if the computer runs more or less 24/7. It depends on several factors ;). I don't know for how long external backup and archive HDDs do last. Probably for way longer than 7 years. However, my guess is, due to a lack of experiences with SSDs, that they last for as long as HDDs do last. However, I suspect I will replace one by another with more sized SSDs already before they fail. I became a digital photographer a few weeks ago and noticed, that I was mistaken a while ago, when we talked about storage space. Nowadays I tend to make one or two photos more, than I've done, when I needed to pay for 35 mm film ;). Due to a lack of money, I put together two new 2 external 2 TB HDDs with USB enclosures, to reorganize my current internal SSDs and my current external backup and archive HDDs. Btw. I've done this today. As soon as I've got enough money again, I will get also more external storage space. Maybe I'll continue using USB (/eSATA) enclosures, maybe I'll get a swap bay. I've got no experiences with NAS. It seems to be too expensive. However, a starting point would be to replace my 1 and 2 TB external HDDs with 4 TB HDDs. The used enclosures are suitable for HDDs up to 4 TB. >As long as the light switch doesn't suddenly shout "I've been >used 1500 times now, I'm kaputt, please buy a new one!" everything >should be okay within the limits of reality. If my SSDs should do this after 4 or 7 years, I could accept it. Btw. my iPad 2 is way older than 3 years and the internal 32 TB drive was used to it's limits, but still works. My new iPad has a build in 1 TB drive for good reasons. >For the case of using lots of "throwaway files" (i. e. stuff you >only need as files during ports builds), you can always use a >RAM disk, if your system has enough RAM. And swap space that you >don't write to doesn't add any wear. FreeBSD might work better, maybe the Linux of other users does, too. If I exceed tmpfs size with my Linux, when building packages, swap isn't used. Build aborts with a "no space left on device" error. >> What exactly makes you think, that SSDs need gentle treatment? =20 > >It's probably the limit on write cycles, but I'm not sure how >this compares to general lifetime calculations compared to >regular hard disks... Neither do I, but it seems likely that they last as long, as HDDs do. Most file systems are ext4 (on the old HDDs it probably was ext3), journaling enabled, some use relatime, some use noatime. The noatime option isn't used to reduce write cycles of a SSD, it's a leftover from the times when my computers used HDDs for audio production and should help to achieve better performance. From owner-freebsd-questions@freebsd.org Wed Oct 14 18:34:16 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E1FAF43FE3A for ; Wed, 14 Oct 2020 18:34:16 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBLfc1HXgz4L9Y for ; Wed, 14 Oct 2020 18:34:15 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CBLfV5GbnzFpSb for ; Wed, 14 Oct 2020 11:34:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602700450; bh=LoFuHAXfd5WlUmkw0QQjtbQTDcULZc6sOxJPAjJ1obI=; h=Date:From:To:Subject:In-Reply-To:References:From; b=Kyh4FZf0IKQJNY9uGvI2Cuw6UZTednwIvi+s4B+DCg+By4yp6HyY/NWRnRjuacJRo yAJSLCOPkGglbYN1uex7owWqsLLZl99xWoEA9LI8PwZ3JEH4rMH/UaXIvJqLcaMfrG 96ImFMwPwzPeP3uFKICVS42AMCS44aSy1iS0Z+CA= X-Riseup-User-ID: 6657CDC45D840DB0D74C58B7E770FC03D3358F8350DD3BC1269D7818DBD054A8 Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CBLfV0T9FzJrtS for ; Wed, 14 Oct 2020 11:34:09 -0700 (PDT) Date: Wed, 14 Oct 2020 20:34:03 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201014203403.643590e6@archlinux> In-Reply-To: <20201014202206.7c7886d0@archlinux> References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBLfc1HXgz4L9Y X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=Kyh4FZf0; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.03 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.99)[-0.985]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.43)[-0.426]; NEURAL_HAM_LONG(-1.02)[-1.017]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 18:34:16 -0000 On Wed, 14 Oct 2020 20:22:06 +0200, Ralf Mardorf wrote: >Btw. my iPad 2 is way older than 3 years and the internal 32 TB >drive was used to it's limits This should read "32 GB" ;). It actually mentions 27.7 GB capacity. Dunno how the things inside of iPads compare to SSDs. I suspect it's more or less the same. From owner-freebsd-questions@freebsd.org Wed Oct 14 21:56:57 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9E51E443834 for ; Wed, 14 Oct 2020 21:56:57 +0000 (UTC) (envelope-from 4250.82.1d4c5000384a4d8.7b5c53180c5a20207d11261cf3a16fa7@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBR8S5ZwDz4VGY for ; Wed, 14 Oct 2020 21:56:56 +0000 (UTC) (envelope-from 4250.82.1d4c5000384a4d8.7b5c53180c5a20207d11261cf3a16fa7@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602712615; x=1605304615; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:to:from:date:x-thread-info; bh=EnlXhh8IHIx8Vw/ZM+3pF3c6p0Tqyd8KWzEezglqf4A=; b=DhWYbx70Q90a65VmJlYYlPbBwzfcAfzbOjRvuaYZClYn9snBB2hrl8jfGeQPYCe7NvX2vum+6ooOjxn9FAGoOmGYhjWFmooEQixCi4V3HxiOgtl0AL+alo6r7UKqiZzRtj7Kmd5+es1lRwUsu+fAz8BN7wQSJLkGY3chxJH80mM= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDM4NGE0ZDguZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r1.us-east-2.aws.in.socketlabs.com (r1.us-east-2.aws.in.socketlabs.com [142.0.189.1]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Wed, 14 Oct 2020 17:56:51 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r1.us-east-2.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Wed, 14 Oct 2020 17:57:07 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kSolO-000E9g-KR for freebsd-questions@freebsd.org; Wed, 14 Oct 2020 22:56:50 +0100 Date: Wed, 14 Oct 2020 22:56:50 +0100 From: Steve O'Hara-Smith To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-Id: <20201014225650.9d8d32231a7d6a8e7b1acd28@sohara.org> In-Reply-To: <20201014202206.7c7886d0@archlinux> References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4CBR8S5ZwDz4VGY X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=DhWYbx70; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c5000384a4d8.7b5c53180c5a20207d11261cf3a16fa7@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c5000384a4d8.7b5c53180c5a20207d11261cf3a16fa7@email-od.com X-Spamd-Result: default: False [-1.65 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-0.99)[-0.988]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[sohara.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-0.998]; RCVD_COUNT_THREE(0.00)[4]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; DKIM_TRACE(0.00)[email-od.com:+]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; NEURAL_SPAM_SHORT(0.03)[0.031]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c5000384a4d8.7b5c53180c5a20207d11261cf3a16fa7@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c5000384a4d8.7b5c53180c5a20207d11261cf3a16fa7@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Oct 2020 21:56:57 -0000 On Wed, 14 Oct 2020 20:22:06 +0200 Ralf Mardorf wrote: > As soon as I've got enough money again, I will get also more external > storage space. Maybe I'll continue using USB (/eSATA) enclosures, maybe > I'll get a swap bay. I've got no experiences with NAS. It seems to be > too expensive. However, a starting point would be to replace my 1 and 2 > TB external HDDs with 4 TB HDDs. The used enclosures are suitable for > HDDs up to 4 TB. A NAS is just a computer with a lot of storage serving it up over the network by NFS and/or SMB. A FreeBSD NAS is usually ZFS based with either mirrors (better performance, faster resilver) or some level of RAIDZ (better storage efficiency). No matter what level of redundancy in the NAS you still want a backup which adds up. I currently use a refurbished 1U server[1] with eight second hand 3.5" 2TB SAS drives[2] arranged as four mirrors for my NAS (it cost about £500 all in a couple of years ago) and an old Atom box with four hot swap SATA bays set up as a RAIDZ for the backup[3]. [1] Half the cores turned off and the clock locked to minimum brings the power consumption and fan noise down to sane levels while still being able to saturate the dual LAN from encrypted drives. [2] By data centre standards these are slow low power drives so they got used for nearline, backup and low load servers, they get very low usage before being retired by age policy. By home user standards they're fast high quality drives. One of the better storage bargains. [3] Yes the backup has less capacity than the main NAS, I'll need to worry about that in a few years time at current usage growth rates. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Thu Oct 15 06:06:43 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id CA9AB433F18 for ; Thu, 15 Oct 2020 06:06:43 +0000 (UTC) (envelope-from jacques+freebsd@foucry.net) Received: from mail.foucry.net (mail.foucry.net [IPv6:2a01:4f9:4a:1fd8::17]) (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 4CBf1Z5D51z43B1 for ; Thu, 15 Oct 2020 06:06:42 +0000 (UTC) (envelope-from jacques+freebsd@foucry.net) Received: from mail.foucry.net (unknown [192.168.12.17]) by mail.foucry.net (Postfix) with ESMTP id D5E5E1C884 for ; Thu, 15 Oct 2020 06:06:33 +0000 (UTC) X-Virus-Scanned: amavisd-new at foucry.net Received: from mail.foucry.net ([192.168.12.17]) by mail.foucry.net (mail.foucry.net [192.168.12.17]) (amavisd-new, port 10024) with ESMTP id Rr4DbcEyFMdN for ; Thu, 15 Oct 2020 06:06:19 +0000 (UTC) Received: by mail.foucry.net (Postfix, from userid 58) id 97B501C864; Thu, 15 Oct 2020 06:06:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=foucry.net; s=dkim; t=1602741979; bh=hsQ5wHT1HtLXElnVY91ExpDkhMno6tKkRoTnq0t5YJ4=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=niOdfOi419oc+91ApzrDFO6sCLnbraD3N8uPYg1R+50ycg7MxhUNtaC+3m8Edoipj AXuBqjsyJ6waqeNldL64mBua+nvi4DxBdh9Kpjc72ddkLPRN9TaQgMCYjC5gueqsV6 s/KyIUi335ccHFJN41lBQMZCVv8OVvUL2cp2SJ5c= Received: from mithril.localdomain (unknown [37.171.24.114]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.foucry.net (Postfix) with ESMTPSA id B37E01C85C; Thu, 15 Oct 2020 06:06:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=foucry.net; s=dkim; t=1602741977; bh=hsQ5wHT1HtLXElnVY91ExpDkhMno6tKkRoTnq0t5YJ4=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=Zz9U5ht9Pfjc5BiFwh/HzyDSlWYoE8z2EobGJDktEXjiYiCthfQHcJE7cad9cqIAa IWsL3FyOYO0DD1eu1KqM40pHXCGuoJMQYTzL8aP8jx477aAq+hZIPkPqEIxvv2kIzy CjgGpuEJ0JvwdCo8r4kmqJkBE6setoh/8brEB95c= Received: from mithril (localhost [IPv6:::1]) by mithril.localdomain (Postfix) with ESMTP id 6A7F1190E2; Thu, 15 Oct 2020 08:06:15 +0200 (CEST) Date: Thu, 15 Oct 2020 08:06:15 +0200 From: Jacques Foucry To: Ralf Mardorf Cc: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201015060615.GJ22063@mithril> Mail-Followup-To: Ralf Mardorf , freebsd-questions@freebsd.org References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20201014202206.7c7886d0@archlinux> X-Rspamd-Queue-Id: 4CBf1Z5D51z43B1 X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=foucry.net header.s=dkim header.b=niOdfOi4; dkim=pass header.d=foucry.net header.s=dkim header.b=Zz9U5ht9; dmarc=pass (policy=none) header.from=foucry.net; spf=pass (mx1.freebsd.org: domain of jacques@foucry.net designates 2a01:4f9:4a:1fd8::17 as permitted sender) smtp.mailfrom=jacques@foucry.net X-Spamd-Result: default: False [-3.36 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; RCVD_COUNT_FIVE(0.00)[6]; R_DKIM_ALLOW(-0.20)[foucry.net:s=dkim]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; NEURAL_HAM_LONG(-0.98)[-0.984]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_HAM_MEDIUM(-1.00)[-0.998]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[foucry.net:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[foucry.net,none]; NEURAL_HAM_SHORT(-0.87)[-0.874]; MID_RHS_NOT_FQDN(0.50)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:24940, ipnet:2a01:4f8::/29, country:DE]; TAGGED_FROM(0.00)[freebsd]; MAILMAN_DEST(0.00)[freebsd-questions]; RECEIVED_SPAMHAUS_PBL(0.00)[37.171.24.114:received] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 06:06:43 -0000 Le mercredi 14 oct. 2020 à 20:22:06 (+0200), Ralf Mardorf à écrit: > On Wed, 14 Oct 2020 17:47:49 +0200, Polytropon wrote: > >My guess (and it's really just a guess due to my personal lack > >of any important data and experience) is that the SSD will work > >until it is replaced by a bigger one, or the whole system it is > >installed in will be replaced with a faster one. So there is > >nothing to worry about. If you _really_ want to worry about > >something, ask the manufacturer if they made the firmware brick > >the whole thing when a certain write count is reached so you > >cannot even _read_ your data anymore. :-) > > In my desktop PC are 5 SSDs. Four are connected to the mobos SATA 3 > connectors and one is connected to a SATA 2 connector. Four are 223.57 > GiB sized and one is 447.13 GiB sized. I'm to lazy to check how old > each of them is, but IIRC the oldest is around 3½ years old and the > vendor's software mentions that the "health" is at 64%, the system > drive is one of the newer SSDs, maybe around 2 years old, "health" 57%. > > In my experiences HDDs last for around 2 years, if you turn the computer > on and off very often and for around 7 years, if the computer runs more > or less 24/7. It depends on several factors ;). I don't know for how > long external backup and archive HDDs do last. Probably for way longer > than 7 years. > > However, my guess is, due to a lack of experiences with SSDs, that they > last for as long as HDDs do last. However, I suspect I will replace one > by another with more sized SSDs already before they fail. > > I became a digital photographer a few weeks ago and noticed, that I > was mistaken a while ago, when we talked about storage space. Nowadays I > tend to make one or two photos more, than I've done, when I needed to > pay for 35 mm film ;). > > Due to a lack of money, I put together two new 2 external 2 TB HDDs > with USB enclosures, to reorganize my current internal SSDs and my > current external backup and archive HDDs. Btw. I've done this today. > > As soon as I've got enough money again, I will get also more external > storage space. Maybe I'll continue using USB (/eSATA) enclosures, maybe > I'll get a swap bay. I've got no experiences with NAS. It seems to be > too expensive. However, a starting point would be to replace my 1 and 2 > TB external HDDs with 4 TB HDDs. The used enclosures are suitable for > HDDs up to 4 TB. > > >As long as the light switch doesn't suddenly shout "I've been > >used 1500 times now, I'm kaputt, please buy a new one!" everything > >should be okay within the limits of reality. > > If my SSDs should do this after 4 or 7 years, I could accept it. Btw. > my iPad 2 is way older than 3 years and the internal 32 TB > drive was used to it's limits, but still works. My new iPad has a build > in 1 TB drive for good reasons. > > >For the case of using lots of "throwaway files" (i. e. stuff you > >only need as files during ports builds), you can always use a > >RAM disk, if your system has enough RAM. And swap space that you > >don't write to doesn't add any wear. > > FreeBSD might work better, maybe the Linux of other users does, too. If > I exceed tmpfs size with my Linux, when building packages, swap isn't > used. Build aborts with a "no space left on device" error. > > >> What exactly makes you think, that SSDs need gentle treatment? > > > >It's probably the limit on write cycles, but I'm not sure how > >this compares to general lifetime calculations compared to > >regular hard disks... > > Neither do I, but it seems likely that they last as long, as HDDs do. > Most file systems are ext4 (on the old HDDs it probably was ext3), > journaling enabled, some use relatime, some use noatime. The noatime > option isn't used to reduce write cycles of a SSD, it's a leftover from > the times when my computers used HDDs for audio production and should > help to achieve better performance. > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" I use a SSD on my latptop (1TB) わith 8GB of swap, 256K used. For my Backup and other services I use a HP Proliant Micre server Gen10 with FreeNAS and a jail with nextcloud. It work like a charm! My NAS run with 4 disks, 2 of 3TB in mirror and 2 of 8TB in mirror two. The freenas-boot zpool is on a USB key mirrored (64G each with is to big). Just for information. Have a nice day! -- Jacques Foucry From owner-freebsd-questions@freebsd.org Thu Oct 15 06:26:45 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2C5334343CD for ; Thu, 15 Oct 2020 06:26:45 +0000 (UTC) (envelope-from ml@netfence.it) Received: from soth.netfence.it (net-2-44-121-52.cust.vodafonedsl.it [2.44.121.52]) (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-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mailserver.netfence.it", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBfSh1LtLz43jv for ; Thu, 15 Oct 2020 06:26:43 +0000 (UTC) (envelope-from ml@netfence.it) Received: from alamar.ventu (alamar.local.netfence.it [10.1.2.18]) (authenticated bits=0) by soth.netfence.it (8.16.1/8.15.2) with ESMTPSA id 09F6Qddd012216 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NO) for ; Thu, 15 Oct 2020 08:26:39 +0200 (CEST) (envelope-from ml@netfence.it) X-Authentication-Warning: soth.netfence.it: Host alamar.local.netfence.it [10.1.2.18] claimed to be alamar.ventu Subject: Re: A couple of questions about SSDs To: freebsd-questions@freebsd.org References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> From: Andrea Venturoli Message-ID: Date: Thu, 15 Oct 2020 08:26:39 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:78.0) Gecko/20100101 Thunderbird/78.3.2 MIME-Version: 1.0 In-Reply-To: <20201014202206.7c7886d0@archlinux> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4CBfSh1LtLz43jv X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=pass (policy=none) header.from=netfence.it; spf=pass (mx1.freebsd.org: domain of ml@netfence.it designates 2.44.121.52 as permitted sender) smtp.mailfrom=ml@netfence.it X-Spamd-Result: default: False [-2.67 / 15.00]; RCVD_TLS_ALL(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:2.44.121.52]; MIME_GOOD(-0.10)[text/plain]; HAS_XAW(0.00)[]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.03)[-1.029]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_SPAM_SHORT(0.11)[0.110]; DMARC_POLICY_ALLOW(-0.50)[netfence.it,none]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.95)[-0.948]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:30722, ipnet:2.44.0.0/16, country:IT]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 06:26:45 -0000 On 10/14/20 8:22 PM, Ralf Mardorf wrote: > In my desktop PC are 5 SSDs. Four are connected to the mobos SATA 3 > connectors and one is connected to a SATA 2 connector. Four are 223.57 > GiB sized and one is 447.13 GiB sized. I'm to lazy to check how old > each of them is, but IIRC the oldest is around 3½ years old and the > vendor's software mentions that the "health" is at 64%, the system > drive is one of the newer SSDs, maybe around 2 years old, "health" 57%. So your SSDs seems to last 4-6 years. > In my experiences HDDs last for around 2 years, if you turn the computer > on and off very often and for around 7 years, if the computer runs more > or less 24/7. I'm currently typing on a box running on 13 years old HDs. They've been used on a server (so always on) for maybe 5-6 years, then demoted to a desktop machine and they've been cycle-powered daily for at least other 6. I even have older, still working, rust around. When an HD gets to small/slow for its purpose, I replace it with a bigger shinier one, but I just move the old one to a less demanding use, backups/archive being the lower step in their life. > However, my guess is, due to a lack of experiences with SSDs, that they > last for as long as HDDs do last. Seems not, then. bye & Thanks av. From owner-freebsd-questions@freebsd.org Thu Oct 15 06:43:39 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 973BF434AD1 for ; Thu, 15 Oct 2020 06:43:39 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBfrB5nssz44wk for ; Thu, 15 Oct 2020 06:43:38 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CBfr21ZMPzFs5Y for ; Wed, 14 Oct 2020 23:43:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602744210; bh=P+9qHkHi8+VivWl5qljY2UkGdpDeb/x8kkssW4Um/UQ=; h=Date:From:To:Subject:In-Reply-To:References:From; b=m4yGh74slaAtfKAYQ9pioeoXtINcapZFaW6N/ab+Y3+X8ebM9sfBSJnGlMJ2FBo/3 MxH+juPDWc5dF3VCfMLaQrIlnyMZYeIZrvTdo9FBdi/wycCAdLXCSkritq8eD7JpbH aXoLHYMk685Z6bkTo80qesnvKli5WUH2NR13Mtew= X-Riseup-User-ID: ED703227874477C31CDCFDF43763A492C09B5F3D20F3922FD2752D274C8D9DE7 Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CBfr13vf0zJmlS for ; Wed, 14 Oct 2020 23:43:29 -0700 (PDT) Date: Thu, 15 Oct 2020 08:43:10 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201015084311.5fa2156c@archlinux> In-Reply-To: <20201015060615.GJ22063@mithril> References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> <20201015060615.GJ22063@mithril> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBfrB5nssz44wk X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=m4yGh74s; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.34 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-1.03)[-1.032]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.70)[-0.697]; NEURAL_HAM_LONG(-1.01)[-1.007]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 06:43:39 -0000 Maybe HDD are more fragile than SSD. On Tuesday I got two HDD handed over in a dpd parcel shop, actually it's a kiosk. They were packaged as shown by the image at https://i.imgur.com/1hSKGRe.jpg . Everything inside the package wasn't viewable damaged. One of the drives is way louder and also beeping at a frequency around 1.4 KHz and already suffered from a superblock issue, which is gone now. I probably should have refused to accept. I wonder, if my dealer is willing to replace the drive and I wonder, if I should ask to replace the other drive, too. The other drive still isn't partitioned. However, it sounds ok, so it's likely not damaged, but you never know. That at least one drive is fishy, might be unrelated to the package's treatment. OTOH it's reasonable to assume that it is related. I suspect a SSD is more shockproof than a HDD even with parked heads. From owner-freebsd-questions@freebsd.org Thu Oct 15 07:23:07 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id EA12D43584E for ; Thu, 15 Oct 2020 07:23:07 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBgjl0CBMz46gD for ; Thu, 15 Oct 2020 07:23:06 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CBgjd3PCMzFs70 for ; Thu, 15 Oct 2020 00:23:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602746581; bh=CmhOnA0sRwsLWTHEUo/OFqnjkkWbXvO/X63Nv6MkGVU=; h=Date:From:To:Subject:In-Reply-To:References:From; b=jeKHJ3et33+gXjn5BLgMvSF00PAFzWEneqgEYr96jRHwsRQMd1OZ5JAByzqGv1r2a M8r1DohV8g03OWs2xU9MO4rYXkICdusAAwPJ+x2/Whzjt9d0XjR+N2fDZZ4xRCB/To +nd9L3ksZOawQFLerOMS+sBSqt2q0hM4kPNR1jGo= X-Riseup-User-ID: C937F2687EB5333D8CEE9985F1DE18F26A07CD69EEF8A70405A538390E92E647 Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CBgjc5gfDzJmgZ for ; Thu, 15 Oct 2020 00:23:00 -0700 (PDT) Date: Thu, 15 Oct 2020 09:22:44 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201015092244.211f2370@archlinux> In-Reply-To: References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 4CBgjl0CBMz46gD X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=jeKHJ3et; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.76 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-1.03)[-1.034]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-1.11)[-1.109]; NEURAL_HAM_LONG(-1.02)[-1.017]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 07:23:08 -0000 On Thu, 15 Oct 2020 08:26:39 +0200, Andrea Venturoli wrote: >> In my desktop PC are 5 SSDs. Four are connected to the mobos SATA 3 >> connectors and one is connected to a SATA 2 connector. Four are >> 223.57 GiB sized and one is 447.13 GiB sized. I'm to lazy to check >> how old each of them is, but IIRC the oldest is around 3=C2=BD years old >> and the vendor's software mentions that the "health" is at 64%, the >> system drive is one of the newer SSDs, maybe around 2 years old, >> "health" 57%. =20 > >So your SSDs seems to last 4-6 years. Probably for 4-7 years. My HDDs tend to last for 2-7 years. Indeed, some of my HDDs are way older than 7 years, but either from aged small sized technology, 1 GiB or even 40 MiB or relatively modern, but seldom used drives, since they are external backup and/or archive drives. From owner-freebsd-questions@freebsd.org Thu Oct 15 13:18:14 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 68D1043EA17 for ; Thu, 15 Oct 2020 13:18:14 +0000 (UTC) (envelope-from galtsev@kicp.uchicago.edu) Received: from kicp.uchicago.edu (kicp.uchicago.edu [128.135.20.70]) by mx1.freebsd.org (Postfix) with ESMTP id 4CBqbT4dcDz4T8v for ; Thu, 15 Oct 2020 13:18:13 +0000 (UTC) (envelope-from galtsev@kicp.uchicago.edu) Received: from ray (unknown [172.58.140.242]) (Authenticated sender: galtsev) by kicp.uchicago.edu (Postfix) with ESMTPSA id 560274E65E for ; Thu, 15 Oct 2020 08:08:47 -0500 (CDT) Date: Thu, 15 Oct 2020 08:08:45 -0500 From: Valeri Galtsev To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201015080845.560d8af7@ray> In-Reply-To: <20201015084311.5fa2156c@archlinux> References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> <20201015060615.GJ22063@mithril> <20201015084311.5fa2156c@archlinux> X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBqbT4dcDz4T8v X-Spamd-Bar: +++++++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=uchicago.edu (policy=none); spf=none (mx1.freebsd.org: domain of galtsev@kicp.uchicago.edu has no SPF policy when checking 128.135.20.70) smtp.mailfrom=galtsev@kicp.uchicago.edu X-Spamd-Result: default: False [7.44 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; RECEIVED_SPAMHAUS_XBL(5.00)[172.58.140.242:received]; RECEIVED_SPAMHAUS_PBL(0.00)[172.58.140.242:received]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; GREYLIST(0.00)[pass,body]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_SPAM_MEDIUM(0.87)[0.866]; RCPT_COUNT_ONE(0.00)[1]; MID_RHS_NOT_FQDN(0.50)[]; NEURAL_SPAM_SHORT(0.15)[0.154]; NEURAL_SPAM_LONG(0.82)[0.823]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:160, ipnet:128.135.0.0/16, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions]; DMARC_POLICY_SOFTFAIL(0.10)[uchicago.edu : No valid SPF, No valid DKIM,none] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 13:18:14 -0000 On Thu, 15 Oct 2020 08:43:10 +0200 Ralf Mardorf wrote: > Maybe HDD are more fragile than SSD. On Tuesday I got two HDD handed > over in a dpd parcel shop, actually it's a kiosk. They were packaged > as shown by the image at https://i.imgur.com/1hSKGRe.jpg . Everything > inside the package wasn't viewable damaged. One of the drives is way > louder and also beeping at a frequency around 1.4 KHz and already > suffered from a superblock issue, which is gone now. I probably should > have refused to accept. I wonder, if my dealer is willing to replace > the drive and I wonder, if I should ask to replace the other drive, > too. The other drive still isn't partitioned. However, it sounds ok, > so it's likely not damaged, but you never know. That at least one > drive is fishy, might be unrelated to the package's treatment. OTOH > it's reasonable to assume that it is related. I suspect a SSD is more > shockproof than a HDD even with parked heads. SSD is just shockproof. Indeed, how much acceleration do you have to subject it to have lightweight circuit board with ICs (Intergated Circuits) to subject for something to crack? On the other hand, everyone have seen interior mechanical design of hard drive. to brake it will take much less acceleration. Valeri > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to > "freebsd-questions-unsubscribe@freebsd.org" -- ++++++++++++++++++++++++++++++++++++++++ Valeri Galtsev Sr System Administrator Department of Astronomy and Astrophysics Kavli Institute for Cosmological Physics University of Chicago Phone: 773-702-4247 ++++++++++++++++++++++++++++++++++++++++ From owner-freebsd-questions@freebsd.org Thu Oct 15 13:36:07 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2BEBF43EF3D for ; Thu, 15 Oct 2020 13:36:07 +0000 (UTC) (envelope-from 4250.82.1d4c5000396c3ac.03e92704a2df49d9b32690f416336fa3@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBr061VRkz4VMt for ; Thu, 15 Oct 2020 13:36:05 +0000 (UTC) (envelope-from 4250.82.1d4c5000396c3ac.03e92704a2df49d9b32690f416336fa3@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602768965; x=1605360965; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:to:from:date:x-thread-info; bh=yN7aU3lT9wdW8/xMpJpbg4CvmEIVI+bVvQj3pPf7tQo=; b=TT3aMF8yh8Yr0XdyHzqI2+UEyCLXVQmCpScDdziHQdvhSLQqEMT2yULU1IfsHkdzxvnNXxlfDFzGDu2AAwkJIlzeJ0Qz4TcKkPmCAL+zUOjXCTCArwWHCN+GDvR/b5Cq3EI7z0+L1BEPNO4URJqdVktol0TUaGcRBN4Zn92WsUU= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDM5NmMzYWMuZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r2.h.in.socketlabs.com (r2.h.in.socketlabs.com [142.0.180.12]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Thu, 15 Oct 2020 09:35:54 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r2.h.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Thu, 15 Oct 2020 09:35:56 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kT3QA-000BRO-Gu for freebsd-questions@freebsd.org; Thu, 15 Oct 2020 14:35:54 +0100 Date: Thu, 15 Oct 2020 14:35:54 +0100 From: Steve O'Hara-Smith To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-Id: <20201015143554.c82cd365eb4ae5dbd967793c@sohara.org> In-Reply-To: <20201015084311.5fa2156c@archlinux> References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> <20201015060615.GJ22063@mithril> <20201015084311.5fa2156c@archlinux> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBr061VRkz4VMt X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=TT3aMF8y; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c5000396c3ac.03e92704a2df49d9b32690f416336fa3@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c5000396c3ac.03e92704a2df49d9b32690f416336fa3@email-od.com X-Spamd-Result: default: False [-1.68 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-0.96)[-0.962]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[sohara.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.002]; RCVD_COUNT_THREE(0.00)[4]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; DKIM_TRACE(0.00)[email-od.com:+]; NEURAL_HAM_SHORT(-0.02)[-0.017]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c5000396c3ac.03e92704a2df49d9b32690f416336fa3@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c5000396c3ac.03e92704a2df49d9b32690f416336fa3@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 13:36:07 -0000 On Thu, 15 Oct 2020 08:43:10 +0200 Ralf Mardorf wrote: > Maybe HDD are more fragile than SSD. Of course they are, hard discs are complex mechanical systems operating at ludicrous precision. The astonishing thing is that they're as robust as they are. The first PC hard disc I ever saw (and helped install in a Torch prototype) was a 5Mb drive in full height 5 1/4" format - it came in a large wooden box and was suspended in the middle by a set of springs to the corners. The mounting instructions were long and full of dire warnings. Modern hard discs can be thrown and caught (dropping is inadvisable) which I find impressive. SSDs are ... well solid and won't be bothered by being dropped a few feet. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Thu Oct 15 13:50:03 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7970343F49A for ; Thu, 15 Oct 2020 13:50:03 +0000 (UTC) (envelope-from galtsev@kicp.uchicago.edu) Received: from kicp.uchicago.edu (kicp.uchicago.edu [128.135.20.70]) by mx1.freebsd.org (Postfix) with ESMTP id 4CBrJB5Fcjz4WG8 for ; Thu, 15 Oct 2020 13:50:02 +0000 (UTC) (envelope-from galtsev@kicp.uchicago.edu) Received: from ray (unknown [172.58.140.242]) (Authenticated sender: galtsev) by kicp.uchicago.edu (Postfix) with ESMTPSA id 5162D4E65E for ; Thu, 15 Oct 2020 08:50:02 -0500 (CDT) Date: Thu, 15 Oct 2020 08:50:00 -0500 From: Valeri Galtsev To: freebsd-questions@freebsd.org Subject: Re: A couple of questions about SSDs Message-ID: <20201015085000.27c523b0@ray> In-Reply-To: References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> <20201014202206.7c7886d0@archlinux> X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 4CBrJB5Fcjz4WG8 X-Spamd-Bar: +++++++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=uchicago.edu (policy=none); spf=none (mx1.freebsd.org: domain of galtsev@kicp.uchicago.edu has no SPF policy when checking 128.135.20.70) smtp.mailfrom=galtsev@kicp.uchicago.edu X-Spamd-Result: default: False [7.39 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; RECEIVED_SPAMHAUS_XBL(5.00)[172.58.140.242:received]; RECEIVED_SPAMHAUS_PBL(0.00)[172.58.140.242:received]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; GREYLIST(0.00)[pass,meta]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_SPAM_MEDIUM(0.86)[0.863]; RCPT_COUNT_ONE(0.00)[1]; MID_RHS_NOT_FQDN(0.50)[]; NEURAL_SPAM_SHORT(0.11)[0.105]; NEURAL_SPAM_LONG(0.82)[0.819]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:160, ipnet:128.135.0.0/16, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions]; DMARC_POLICY_SOFTFAIL(0.10)[uchicago.edu : No valid SPF, No valid DKIM,none] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 13:50:03 -0000 On Thu, 15 Oct 2020 08:26:39 +0200 Andrea Venturoli wrote: > On 10/14/20 8:22 PM, Ralf Mardorf wrote: >=20 > > In my desktop PC are 5 SSDs. Four are connected to the mobos SATA 3 > > connectors and one is connected to a SATA 2 connector. Four are > > 223.57 GiB sized and one is 447.13 GiB sized. I'm to lazy to check > > how old each of them is, but IIRC the oldest is around 3=C2=BD years old > > and the vendor's software mentions that the "health" is at 64%, the > > system drive is one of the newer SSDs, maybe around 2 years old, > > "health" 57%. =20 >=20 > So your SSDs seems to last 4-6 years. >=20 >=20 >=20 > > In my experiences HDDs last for around 2 years, if you turn the > > computer on and off very often and for around 7 years, if the > > computer runs more or less 24/7. =20 >=20 > I'm currently typing on a box running on 13 years old HDs. > They've been used on a server (so always on) for maybe 5-6 years, > then demoted to a desktop machine and they've been cycle-powered > daily for at least other 6. > I even have older, still working, rust around. >=20 I first must confess: I always was very picky about choice of hard drives. And I did manage to stick with most reliable ones. That said, I do have machines in the server room running for 10 years, always up, except for occasional reboot (Linux kernel or glibc update...). All still with original drives. Of each 10-20 drives during this time only 1-2 failed (or exhausted badblock reallocation table) and have been replaced. Incidentally, always up is the least demanding use of spinning drive. Well manufactured that is, and positioned horizontally (with axis of platters vertical). If the above observed, the limiting factor will be the number of spin downs or power offs when spring loaded arm let loose and hits the post being stopped at "parking track". SSDs have their use when you need really high speed (or reading), so we still use them for the purpose, even realizing they may loose in durability department. Valeri > When an HD gets to small/slow for its purpose, I replace it with a=20 > bigger shinier one, but I just move the old one to a less demanding > use, backups/archive being the lower step in their life. >=20 >=20 >=20 > > However, my guess is, due to a lack of experiences with SSDs, that > > they last for as long as HDDs do last. =20 >=20 > Seems not, then. >=20 >=20 >=20 > bye & Thanks > av. > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to > "freebsd-questions-unsubscribe@freebsd.org" --=20 ++++++++++++++++++++++++++++++++++++++++ Valeri Galtsev Sr System Administrator Department of Astronomy and Astrophysics Kavli Institute for Cosmological Physics University of Chicago Phone: 773-702-4247 ++++++++++++++++++++++++++++++++++++++++ From owner-freebsd-questions@freebsd.org Thu Oct 15 14:23:53 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2DBCB44002B for ; Thu, 15 Oct 2020 14:23:53 +0000 (UTC) (envelope-from sl8ixw@rp.postal.labs.k.io) Received: from mx94.labs.k.io (mx94.labs.k.io [IPv6:2a03:2800:300::94]) (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 4CBs3D3JHCz4Y5Z for ; Thu, 15 Oct 2020 14:23:52 +0000 (UTC) (envelope-from sl8ixw@rp.postal.labs.k.io) Resent-Sender: sl8ixw@rp.postal.labs.k.io DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=email.sirportly.com; s=postal-QEE0Jp; t=1602771831; bh=oqWuAs13Lbabo/MKxXpbqofkRPJuV3C9H9gxSyLYO38=; h=date:from:to:message-id:subject:mime-version:content-type:content-transfer-encoding; b=W2p/p6LaOGbXqe8CYHJ/BtPauAM4hLlBbzeVM4kiSp2uOKOraDBtfHa9FmGDm2U2E8PN3u6GwXHOvGyNE3K0ZMzUhixAkWsAAtWOpYLnyfnc61Vqei+Yvx1mSxWy+xE2E4iqc5NLA87b8F6cagZXy3z7gz+jY/RFc+QgCcRv/AM= X-Postal-MsgID: EmVbzoG21OYD Received: from app.sirportly.com (::ffff:185.22.211.51 [::ffff:185.22.211.51]) by postal.labs.k.io with SMTP; Thu, 15 Oct 2020 14:23:51 -0000 Date: Thu, 15 Oct 2020 15:23:51 +0100 From: Twingly Customer Support To: freebsd-questions@freebsd.org Message-ID: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> Subject: FreeBSD using swap even though there's a lot of free memory Mime-Version: 1.0 X-Mailer: Sirportly/5.16.2 X-Rspamd-Queue-Id: 4CBs3D3JHCz4Y5Z X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email.sirportly.com header.s=postal-QEE0Jp header.b=W2p/p6La; dmarc=none; spf=pass (mx1.freebsd.org: domain of sl8ixw@rp.postal.labs.k.io designates 2a03:2800:300::94 as permitted sender) smtp.mailfrom=sl8ixw@rp.postal.labs.k.io X-Spamd-Result: default: False [-1.72 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.96)[-0.959]; R_DKIM_ALLOW(-0.20)[email.sirportly.com:s=postal-QEE0Jp]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a03:2800:300::/64:c]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[twingly.com]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.01)[-1.012]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DKIM_TRACE(0.00)[email.sirportly.com:+]; NEURAL_HAM_SHORT(-0.05)[-0.050]; FORGED_SENDER(0.30)[team@twingly.com,sl8ixw@rp.postal.labs.k.io]; MIME_TRACE(0.00)[0:+,1:+,2:~]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:12488, ipnet:2a03:2800::/29, country:GB]; FROM_NEQ_ENVFROM(0.00)[team@twingly.com,sl8ixw@rp.postal.labs.k.io]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 14:23:53 -0000 Hi, We have a server running FreeBSD 12.1-RELEASE-p10. We currently have a problem where FreeBSD starting to swap when running ZFS scrub, even though we have ~70G of free memory. This did not happen before when running FreeBSD 11.3 for example. It started happening at approximately the time we upgraded from 12.1-RELEASE-p5 to 12.1-RELEASE-p6, but if the upgrade is the cause of the problem is unclear, though FreeBSD never swapped for us before that. "Laundry" memory was not something we saw before either, it started to appear at the same time as FreeBSD started swapping. Eventually, after scrubbing a few times, the swap becomes full and we start seeing "swap_pager_getswapspace(24): failed" etc. in dmesg. This is the memory usage a while after scrubbing, note the values for Mem/Free and Swap: ``` % top | head -n 7 last pid: 8112; load averages: 1.82, 1.77, 1.73 up 6+01:37:42 10:53:48 35 processes: 1 running, 34 sleeping CPU: 4.9% user, 0.0% nice, 4.2% system, 0.2% interrupt, 90.7% idle Mem: 110G Active, 27G Inact, 5413M Laundry, 39G Wired, 68G Free ARC: 34G Total, 28G MFU, 4101M MRU, 53M Anon, 1317M Header, 225M Other 30G Compressed, 53G Uncompressed, 1.77:1 Ratio Swap: 8192M Total, 6434M Used, 1757M Free, 78% Inuse ``` We are running MySQL, which has been configured to use ~50% of the total amount memory (using innodb_buffer_pool_size=127748M) ZFS ARC has been configured to use 25% of the total memory (using vfs.zfs.arc_max="63874M") We have tried raising both vfs.zfs.arc_max and innodb_buffer_pool_size, but this did not make any change to the total memory usage, the free memory stays at around 70G and FreeBSD still started swapping. It's as if the memory is capped at around 180G for some reason. Are there any configuration values that could cause FreeBSD to swap even though there's free memory? Are there any config values one could try to change in order to get FreeBSD to use the remaining ~70G of free memory instead of swapping? Let me know if there's any more details you want me to provide and I'll attach those. Thanks! // Mattias From owner-freebsd-questions@freebsd.org Thu Oct 15 15:30:15 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 56BCD4411EA for ; Thu, 15 Oct 2020 15:30:15 +0000 (UTC) (envelope-from news@mips.inka.de) Received: from mail.inka.de (mail.inka.de [IPv6:2a04:c9c7:0:1073:217:a4ff:fe3b:e77c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBtWp05dsz4cMv for ; Thu, 15 Oct 2020 15:30:13 +0000 (UTC) (envelope-from news@mips.inka.de) Received: from mips.inka.de (news@[127.0.0.1]) by mail.inka.de with uucp (rmailwrap 0.5) id 1kT5Ce-008VHj-QA; Thu, 15 Oct 2020 17:30:04 +0200 Received: from lorvorc.mips.inka.de (localhost [127.0.0.1]) by lorvorc.mips.inka.de (8.16.1/8.16.1) with ESMTP id 09FFQWFL073549 for ; Thu, 15 Oct 2020 17:26:32 +0200 (CEST) (envelope-from news@lorvorc.mips.inka.de) Received: (from news@localhost) by lorvorc.mips.inka.de (8.16.1/8.16.1/Submit) id 09FFQWdo073548 for freebsd-questions@freebsd.org; Thu, 15 Oct 2020 17:26:32 +0200 (CEST) (envelope-from news) To: freebsd-questions@freebsd.org From: Christian Weisgerber Newsgroups: list.freebsd.questions Subject: Re: A couple of questions about SSDs Date: Thu, 15 Oct 2020 15:26:32 -0000 (UTC) Message-ID: References: <20201014121442.662e71c4@archlinux> <20201014174749.6df7572a.freebsd@edvax.de> User-Agent: slrn/1.0.3 (FreeBSD) X-Rspamd-Queue-Id: 4CBtWp05dsz4cMv X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of news@mips.inka.de has no SPF policy when checking 2a04:c9c7:0:1073:217:a4ff:fe3b:e77c) smtp.mailfrom=news@mips.inka.de X-Spamd-Result: default: False [2.27 / 15.00]; RCVD_TLS_LAST(0.00)[]; ARC_NA(0.00)[]; FREEFALL_USER(0.00)[news]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(0.31)[0.311]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; AUTH_NA(1.00)[]; RCPT_COUNT_ONE(0.00)[1]; RCVD_COUNT_THREE(0.00)[3]; DMARC_NA(0.00)[inka.de]; NEURAL_SPAM_MEDIUM(0.30)[0.301]; NEURAL_SPAM_LONG(0.46)[0.460]; R_SPF_NA(0.00)[no SPF record]; FORGED_SENDER(0.30)[naddy@mips.inka.de,news@mips.inka.de]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:202113, ipnet:2a04:c9c7::/32, country:DE]; FROM_NEQ_ENVFROM(0.00)[naddy@mips.inka.de,news@mips.inka.de]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 15:30:15 -0000 On 2020-10-14, Polytropon wrote: >> What exactly makes you think, that SSDs need gentle treatment? > > It's probably the limit on write cycles, but I'm not sure how > this compares to general lifetime calculations compared to > regular hard disks... I don't remember when this started, but nowadays hard drives also come with an explicitly specified workload rating, e.g. "Ultrastar hard drives are designed with a workload rating up to 550TB per year" https://documents.westerndigital.com/content/dam/doc-library/en_us/assets/public/western-digital/product/data-center-drives/general-docs/data-sheet-ultrastar-sata-series-2879-810017.pdf -- Christian "naddy" Weisgerber naddy@mips.inka.de From owner-freebsd-questions@freebsd.org Thu Oct 15 16:05:08 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 90E60441D2C for ; Thu, 15 Oct 2020 16:05:08 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from slave.jschneider.net (slave.jschneider.net [46.235.226.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBvJ33VSvz4fF4 for ; Thu, 15 Oct 2020 16:05:07 +0000 (UTC) (envelope-from freebsd@jschneider.net) X-Disposition: Mostly harlmess; Thu, 15 Oct 2020 17:04:52 +0100 To: freebsd-questions@freebsd.org From: Jon Schneider Subject: geom list mode Message-ID: <2c602f65-9be4-08ef-174a-3ecddbb4cbd8@jschneider.net> Date: Thu, 15 Oct 2020 17:04:44 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBvJ33VSvz4fF4 X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of freebsd@jschneider.net designates 46.235.226.89 as permitted sender) smtp.mailfrom=freebsd@jschneider.net X-Spamd-Result: default: False [-1.30 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.29)[-0.291]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:46.235.226.89]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[jschneider.net]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.58)[-0.581]; NEURAL_HAM_SHORT(-0.12)[-0.123]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:44684, ipnet:46.235.224.0/21, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 16:05:08 -0000 geom list gives stuff like Mode: r1w1e1 for devices. What is it and how would I find out from documentation (that is without interweb or asking) ? Jon From owner-freebsd-questions@freebsd.org Thu Oct 15 16:21:25 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 6E632441EF6 for ; Thu, 15 Oct 2020 16:21:25 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from slave.jschneider.net (slave.jschneider.net [46.235.226.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CBvfr6JFpz4fy3 for ; Thu, 15 Oct 2020 16:21:24 +0000 (UTC) (envelope-from freebsd@jschneider.net) X-Disposition: Mostly harlmess; Thu, 15 Oct 2020 17:21:22 +0100 Subject: Re: FreeBSD using swap even though there's a lot of free memory To: freebsd-questions@freebsd.org, Twingly Customer Support References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> From: Jon Schneider Message-ID: Date: Thu, 15 Oct 2020 17:21:14 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.12.1 MIME-Version: 1.0 In-Reply-To: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CBvfr6JFpz4fy3 X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of freebsd@jschneider.net designates 46.235.226.89 as permitted sender) smtp.mailfrom=freebsd@jschneider.net X-Spamd-Result: default: False [-3.20 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.02)[-1.016]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:46.235.226.89]; NEURAL_HAM_LONG(-0.98)[-0.978]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[jschneider.net]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.90)[-0.903]; RCPT_COUNT_TWO(0.00)[2]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:44684, ipnet:46.235.224.0/21, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 16:21:25 -0000 top -w -oswap seems to report the right thing. Would be interesting if it's _not_ MySQL. Jon On 15/10/2020 15:23, Twingly Customer Support wrote: > Hi, > > We have a server running FreeBSD 12.1-RELEASE-p10. We currently have a problem where FreeBSD starting to swap when running ZFS scrub, even though we have ~70G of free memory. > This did not happen before when running FreeBSD 11.3 for example. It started happening at approximately the time we upgraded from 12.1-RELEASE-p5 to 12.1-RELEASE-p6, but if the upgrade is the cause of the problem is unclear, though FreeBSD never swapped for us before that. "Laundry" memory was not something we saw before either, it started to appear at the same time as FreeBSD started swapping. > > Eventually, after scrubbing a few times, the swap becomes full and we start seeing "swap_pager_getswapspace(24): failed" etc. in dmesg. > This is the memory usage a while after scrubbing, note the values for Mem/Free and Swap: > > ``` > % top | head -n 7 > last pid: 8112; load averages: 1.82, 1.77, 1.73 up 6+01:37:42 10:53:48 > 35 processes: 1 running, 34 sleeping > CPU: 4.9% user, 0.0% nice, 4.2% system, 0.2% interrupt, 90.7% idle > Mem: 110G Active, 27G Inact, 5413M Laundry, 39G Wired, 68G Free > ARC: 34G Total, 28G MFU, 4101M MRU, 53M Anon, 1317M Header, 225M Other > 30G Compressed, 53G Uncompressed, 1.77:1 Ratio > Swap: 8192M Total, 6434M Used, 1757M Free, 78% Inuse > ``` > > We are running MySQL, which has been configured to use ~50% of the total amount memory (using innodb_buffer_pool_size=127748M) > ZFS ARC has been configured to use 25% of the total memory (using vfs.zfs.arc_max="63874M") > > We have tried raising both vfs.zfs.arc_max and innodb_buffer_pool_size, but this did not make any change to the total memory usage, the free memory stays at around 70G and FreeBSD still started swapping. > It's as if the memory is capped at around 180G for some reason. > > Are there any configuration values that could cause FreeBSD to swap even though there's free memory? Are there any config values one could try to change in order to get FreeBSD to use the remaining ~70G of free memory instead of swapping? > > Let me know if there's any more details you want me to provide and I'll attach those. > > Thanks! > > // Mattias > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" > From owner-freebsd-questions@freebsd.org Thu Oct 15 16:45:38 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D16AB442735 for ; Thu, 15 Oct 2020 16:45:38 +0000 (UTC) (envelope-from kuku@kukulies.org) Received: from mail.kukulies.org (mail.kukulies.org [116.203.115.43]) by mx1.freebsd.org (Postfix) with ESMTP id 4CBwBn6vfmz3SYF for ; Thu, 15 Oct 2020 16:45:37 +0000 (UTC) (envelope-from kuku@kukulies.org) Received: from localhost (localhost [127.0.0.1]) by mail.kukulies.org (Postfix) with ESMTP id 61B3810276A for ; Thu, 15 Oct 2020 18:45:31 +0200 (CEST) Received: from mail.kukulies.org ([127.0.0.1]) by localhost (mail.kukulies.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9IHqPMR_SY91 for ; Thu, 15 Oct 2020 18:45:31 +0200 (CEST) Received: from christophs-macbook-pro.fritz.box (p57a1f9fb.dip0.t-ipconnect.de [87.161.249.251]) by mail.kukulies.org (Postfix) with ESMTPSA id 11AC4102769 for ; Thu, 15 Oct 2020 18:45:31 +0200 (CEST) From: Christoph Kukulies Content-Type: multipart/signed; boundary="Apple-Mail=_D08CA096-C312-4F42-8E11-CB5B71412D02"; protocol="application/pkcs7-signature"; micalg=sha-256 Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.4\)) Subject: Which ports to install to compile gnu binutils? Message-Id: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> Date: Thu, 15 Oct 2020 18:45:30 +0200 To: RW via freebsd-questions X-Mailer: Apple Mail (2.3608.120.23.2.4) X-Rspamd-Queue-Id: 4CBwBn6vfmz3SYF X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of kuku@kukulies.org has no SPF policy when checking 116.203.115.43) smtp.mailfrom=kuku@kukulies.org X-Spamd-Result: default: False [1.44 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; MV_CASE(0.50)[]; HAS_ATTACHMENT(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.54)[-0.542]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:24940, ipnet:116.203.0.0/16, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[87.161.249.251:received]; ARC_NA(0.00)[]; FREEFALL_USER(0.00)[kuku]; FROM_HAS_DN(0.00)[]; SIGNED_SMIME(-2.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[kukulies.org]; AUTH_NA(1.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_SPAM_MEDIUM(0.67)[0.667]; MIME_TRACE(0.00)[0:+,1:+,2:~]; NEURAL_SPAM_LONG(0.91)[0.912]; R_SPF_NA(0.00)[no SPF record]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 16:45:38 -0000 --Apple-Mail=_D08CA096-C312-4F42-8E11-CB5B71412D02 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 I=E2=80=99m in need to compile gnu-binutils (actually an older vintage = version) and I=E2=80=99m wondering what would be required to add in ports/packages? FreeBSD-12.1 ist the system. =E2=80=94 Christoph --Apple-Mail=_D08CA096-C312-4F42-8E11-CB5B71412D02 Content-Disposition: attachment; filename=smime.p7s Content-Type: application/pkcs7-signature; name=smime.p7s Content-Transfer-Encoding: base64 MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgEFADCABgkqhkiG9w0BBwEAAKCCCc0w ggSQMIIDeKADAgECAggYVYMhomAL1zANBgkqhkiG9w0BAQsFADBmMQswCQYDVQQGEwJERTEzMDEG A1UECgwqREdOIERldXRzY2hlcyBHZXN1bmRoZWl0c25ldHogU2VydmljZSBHbWJIMSIwIAYDVQQD DBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBFOlBOMB4XDTIwMDUxNjE1Mjc1OVoXDTIxMDUxNjE1Mjc1 OVowbzELMAkGA1UEBhMCREUxITAfBgNVBAUTGDQwMDAwMDAwNWVjMDA4ZGQzNzNhZDhlYzEbMBkG A1UEAwwSQ2hyaXN0b3BoIEt1a3VsaWVzMSAwHgYJKoZIhvcNAQkBFhFrdWt1QGt1a3VsaWVzLm9y ZzCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKug1655hQWRmOtGAShZLbMwDtrm7rAH 7p1oPtE/5KpTpJZe8LHPxxvW0EAd2JcLtEhdvAi7smhZ/giJ3IBK7OYmdaCvuQ6MFvJpkmLkQ9TO 4+RLW+PkBk8nFIUe+PQG+VurpWc8pbU4IRsWS3pEUgov9+LF6VtyYBHKD2HZwe46YBwUq7l0EHxc aa98ewCMO43XznlqjE+oKxwaS2nl1rL/SPVlfGmKqHkdSKEKl6yR1LCcI3J3HP56kqmIrvtySr7q UZVsibA+D6vArqklO99WKQmt0b4IX6TXouvAA6bNoF1FhYUyihm4omMWZkdTs7Gv5rr1fzPWXcev cMfJdtUCAwEAAaOCATcwggEzMB0GA1UdDgQWBBSQh9N17gCH/igJy5ftrVaJNm6SCTAMBgNVHRMB Af8EAjAAMB8GA1UdIwQYMBaAFOnGk9HVDwZkcupqlj66EPJUVLJ5MFYGA1UdIARPME0wSwYMKwYB BAH7KwIBAwIIMDswOQYIKwYBBQUHAgEWLWh0dHA6Ly9zZWM1LmRnbnNlcnZpY2UuZGUvcG9saWNp ZXMvaW5kZXguaHRtbDA+BgNVHR8ENzA1MDOgMaAvhi1odHRwOi8vc2VjNS5kZ25zZXJ2aWNlLmRl L2NybC9jcmwyLXR5cGUtZS5jcmwwDgYDVR0PAQH/BAQDAgSwMB0GA1UdJQQWMBQGCCsGAQUFBwMC BggrBgEFBQcDBDAcBgNVHREEFTATgRFrdWt1QGt1a3VsaWVzLm9yZzANBgkqhkiG9w0BAQsFAAOC AQEALUBRNzLAUiPi29LLATqWmrUlyacMVAtjdROQMd/AVPj0mUqTMoDO+YoWICOSEn/nEyb2Lrrz JNGqC6KO0CNROaWcEhFadKx4qtp9t26Qe/EkO0XbXexIfBxFl1ynQA54D0qtPb/SUZvTy0tq8oBt FdsIU+cXAzigEz2Z9nziHBMqThoKzAZSrk/sPvxT6MNMC/BMGlHGl0DV//wwI5vlzJiKS8iXFyxf 5VrN1IwgRyqXD8JsgF1BuEqcloSJ3JnWUGQCTURFasZDJlP0f/KJS8odUpEWDKnn6tt0RjBk0jUN i7z42ozzPn/o154AgXC2cNmROxC0gnvd+V/yIuAryDCCBTUwggQdoAMCAQICCFUcStdmrSX2MA0G CSqGSIb3DQEBCwUAMGExCzAJBgNVBAYTAkRFMTMwMQYDVQQKDCpER04gRGV1dHNjaGVzIEdlc3Vu ZGhlaXRzbmV0eiBTZXJ2aWNlIEdtYkgxHTAbBgNVBAMMFGRnbnNlcnZpY2UgUm9vdCA3OlBOMB4X DTE2MTAyNjA5MjI0MVoXDTI0MTAyNjA5MjI0MVowZjELMAkGA1UEBhMCREUxMzAxBgNVBAoMKkRH TiBEZXV0c2NoZXMgR2VzdW5kaGVpdHNuZXR6IFNlcnZpY2UgR21iSDEiMCAGA1UEAwwZZGduc2Vy dmljZSBDQSAyIFR5cGUgRTpQTjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBANyl8pQ/ dMejR9KXZs5ro81tFwNhloThlXe8sat79Tjjk6xFqE5E94//0vifJxMrp9RrCkNOo5oPG1djGOgk 0L0ucpHFUH9SQF/SHbm83QvWJXgqEJpjxOKZXTPbJRKVvY25niB0FTr2omRqypiP4A/w5xA6jSJ2 P02vV6WgcPfaLQkM+SEGPxV/pzpvuY3KfzJ9li9mXPNXaJD9y+jqIUvHbCAbuYKQ5nwEAcYMXDpP RQgDQGTrRiFExHEjsZeMzEFADZj9deg/h29AMO0w2YrSvkNReh/zvDZutdy25DZvjE3AUgStWgBC 7x+2ddOb2I61o6xbIsxlfq/mzNpAGoECAwEAAaOCAeowggHmMBIGA1UdEwEB/wQIMAYBAf8CAQAw HwYDVR0jBBgwFoAUAQwWG3Ry0zwU7iZ3t0kUU9j7ixswWwYIKwYBBQUHAQEETzBNMEsGCCsGAQUF BzABhj9odHRwOi8vcm9jc3AtZGduLmRnbnNlcnZpY2UuZGU6ODA4MC9lamJjYS9wdWJsaWN3ZWIv c3RhdHVzL29jc3AwagYDVR0gBGMwYTBfBgwrBgEEAfsrAgEEAgEwTzBNBggrBgEFBQcCARZBaHR0 cDovL3d3dy5kZ25zZXJ2aWNlLmRlL3RydXN0Y2VudGVyL3B1YmxpYy9kZ25zZXJ2aWNlL2luZGV4 Lmh0bWwwgZkGA1UdHwSBkTCBjjCBi6CBiKCBhYaBgmxkYXA6Ly9sZGFwLmRnbnNlcnZpY2UuZGU6 Mzg5L0NOPUNSTC0xLE89REdOJTIwU2VydmljZSUyMEdtYkgsQz1ERT9jZXJ0aWZpY2F0ZVJldm9j YXRpb25MaXN0P2Jhc2U/b2JqZWN0Q2xhc3M9Y1JMRGlzdHJpYnV0aW9uUG9pbnQwHQYDVR0OBBYE FOnGk9HVDwZkcupqlj66EPJUVLJ5MA4GA1UdDwEB/wQEAwIBBjAbBgkrBgEEAcBtAwUEDjAMBgor BgEEAcBtAwUBMA0GCSqGSIb3DQEBCwUAA4IBAQCrvDn6Rcn7/FNq3SOJNfgYNfkdR5CiGoC4sZ+i 0dypCqqMXwbpRQjSriLS2eEe2V2Fms0E4SuBOEaxOg1nVjYafQVGtytRT0ueFIzB3VcnQl7oRFJ0 SHi9d/xjElAZkk8I8lytuWG57SabA72duEp7AaCWG3lVZIdNLy+rkNrfNvEUbqUh0TrZXgqpwwCL JjYF8vyC4I+xxNaXm3EmuNvgQ2j2dGp3Oxc0QbfLLOCbK/rOdDikaBN7kTqpfHls7pcIOhQrgrPV LzY/NHqG9zEpmjuQora63YHdu7BTzGp/DvcQwfyKa/gtb9LHn3AoSUqOKOMd02sUb/AxGhsNjMzJ MYIDFDCCAxACAQEwcjBmMQswCQYDVQQGEwJERTEzMDEGA1UECgwqREdOIERldXRzY2hlcyBHZXN1 bmRoZWl0c25ldHogU2VydmljZSBHbWJIMSIwIAYDVQQDDBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBF OlBOAggYVYMhomAL1zANBglghkgBZQMEAgEFAKCCAXMwGAYJKoZIhvcNAQkDMQsGCSqGSIb3DQEH ATAcBgkqhkiG9w0BCQUxDxcNMjAxMDE1MTY0NTMwWjAvBgkqhkiG9w0BCQQxIgQgZs1hHrxeKygA 0/chJljDMQxdC1BrrM2ghSIO2R4vsp8wgYEGCSsGAQQBgjcQBDF0MHIwZjELMAkGA1UEBhMCREUx MzAxBgNVBAoMKkRHTiBEZXV0c2NoZXMgR2VzdW5kaGVpdHNuZXR6IFNlcnZpY2UgR21iSDEiMCAG A1UEAwwZZGduc2VydmljZSBDQSAyIFR5cGUgRTpQTgIIGFWDIaJgC9cwgYMGCyqGSIb3DQEJEAIL MXSgcjBmMQswCQYDVQQGEwJERTEzMDEGA1UECgwqREdOIERldXRzY2hlcyBHZXN1bmRoZWl0c25l dHogU2VydmljZSBHbWJIMSIwIAYDVQQDDBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBFOlBOAggYVYMh omAL1zANBgkqhkiG9w0BAQEFAASCAQAeuZP+o/Z2we5OIgghLS5/VK+YZGjOdKuxOQ4DgY2OzGdF yn1mqYQG1+m39haCSois1vjoiaC7qW8Qqj7FB9e3EWKlg/2TkyPhuxsxQfUgzLIOPKi4MP9DmrPl EJcXETW/Sp6/+6H9EJRdYxvo2erIF2iETAzaOd7KlSHu83Evn/1a4AMpdpUdMUoJS6EzER6/6PFf y2O5gOHTu0ND10rZudQP0xRAnt5XREbiBNdFjTuVA3yDEMqn3xZ3vOqcEsnZLYkgPifUsv38QfiC maZYPES3gGFVHWZiF/lk6PRj1LM5PKIHCAumafHeqOJwqYAuttnVYO9vGe7ty4I1OUaTAAAAAAAA --Apple-Mail=_D08CA096-C312-4F42-8E11-CB5B71412D02-- From owner-freebsd-questions@freebsd.org Thu Oct 15 21:48:03 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0D5884480BC for ; Thu, 15 Oct 2020 21:48:03 +0000 (UTC) (envelope-from merlyn@geeks.org) Received: from mail.geeks.org (mail.geeks.org [IPv6:2001:4980:3333:1::1]) (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 4CC2vk21Hlz446t for ; Thu, 15 Oct 2020 21:48:02 +0000 (UTC) (envelope-from merlyn@geeks.org) Received: from mail.geeks.org (localhost [127.0.0.1]) by after-clamsmtpd.geeks.org (Postfix) with ESMTP id 94251932AA for ; Thu, 15 Oct 2020 16:47:55 -0500 (CDT) Received: by mail.geeks.org (Postfix, from userid 1003) id 7865A932A9; Thu, 15 Oct 2020 16:47:55 -0500 (CDT) Date: Thu, 15 Oct 2020 16:47:55 -0500 From: Doug McIntyre To: RW via freebsd-questions Subject: Re: Which ports to install to compile gnu binutils? Message-ID: <20201015214755.GB26691@geeks.org> References: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> X-Virus-Scanned: ClamAV using ClamSMTP X-Rspamd-Queue-Id: 4CC2vk21Hlz446t X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of merlyn@geeks.org designates 2001:4980:3333:1::1 as permitted sender) smtp.mailfrom=merlyn@geeks.org X-Spamd-Result: default: False [-1.09 / 15.00]; RCVD_TLS_LAST(0.00)[]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ptr]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[geeks.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.99)[-0.986]; RCVD_COUNT_THREE(0.00)[3]; NEURAL_HAM_MEDIUM(-0.78)[-0.777]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.02)[-0.022]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:7753, ipnet:2001:4980::/32, country:US]; SUBJECT_ENDS_QUESTION(1.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Oct 2020 21:48:03 -0000 On Thu, Oct 15, 2020 at 06:45:30PM +0200, Christoph Kukulies wrote: > I’m in need to compile gnu-binutils (actually an older vintage version) and I’m wondering what would be required to add > in ports/packages? > > FreeBSD-12.1 ist the system. It is already there? devel/binutils https://www.freshports.org/devel/binutils/ From owner-freebsd-questions@freebsd.org Fri Oct 16 00:40:07 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7F67B44AAC5 for ; Fri, 16 Oct 2020 00:40:07 +0000 (UTC) (envelope-from roberthuff@rcn.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 4CC6kH2H1mz4D91 for ; Fri, 16 Oct 2020 00:40:07 +0000 (UTC) (envelope-from roberthuff@rcn.com) Received: by mailman.nyi.freebsd.org (Postfix) id 4E2D744AC23; Fri, 16 Oct 2020 00:40:07 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4DF6344ACA5 for ; Fri, 16 Oct 2020 00:40:07 +0000 (UTC) (envelope-from roberthuff@rcn.com) Received: from smtp.rcn.com (smtp.rcn.com [69.168.97.78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CC6kG1wX5z4D90 for ; Fri, 16 Oct 2020 00:40:06 +0000 (UTC) (envelope-from roberthuff@rcn.com) DKIM-Signature: v=1; a=rsa-sha1; d=rcn.com; s=20180516; c=relaxed/simple; q=dns/txt; i=@rcn.com; t=1602808805; h=From:Subject:Date:To:MIME-Version:Content-Type; bh=H9yu7tjMQcBTKAS/Qxhu7iG5oaI=; b=VnGf5HmTYF/TRepBXpepgImBFpSO4uqwNLzyv6kBI/UHApHZrgJ9EmAfnj+K5CCe TPsGChOS9/z0mE/4i/+bJsLyejbVtZ0jQg9XnOFMbiCPYtwkI9pQ1JmnntNrY1rm Ce1lpJwckV6h83M8dJwUZ/YMq7DPnxCcM9ayedpWWmR618EakSWLkSGp3u5QTEK8 7ayGYR1Jevukqcjsdfoa1bUT3+NBKd7hO4s84WoSq7r/qW1QFrWTwssJJu9RoI3B Bqs32eZTDbzTxIa97CooDAO92lj9rP6ZXY0u73TtN0lHqG2h8mZYI6gsezSPbbl5 tHFASEGgHs7cuFXqt7+/OQ==; X_CMAE_Category: , , X-CNFS-Analysis: v=2.3 cv=L5BjvNb8 c=1 sm=1 tr=0 cx=a_idp_x a=9TgA2UwI6Wy+6BV4wQM/cQ==:117 a=9TgA2UwI6Wy+6BV4wQM/cQ==:17 a=KGjhK52YXX0A:10 a=kj9zAlcOel0A:10 a=XRQyMpdBKAEA:10 a=afefHYAZSVUA:10 a=48faUk6PgeAA:10 a=HP1cehN_gl0mIuz3DNEA:9 a=CjuIK1q_8ugA:10 X-CM-Score: 0 X-Scanned-by: Cloudmark Authority Engine X-Authed-Username: cm9iZXJ0aHVmZkByY24uY29t Received: from [209.6.230.48] ([209.6.230.48:61071] helo=jerusalem.litteratus.org.litteratus.org) by smtp.rcn.com (envelope-from ) (ecelerity 3.6.25.56547 r(Core:3.6.25.0)) with ESMTPSA (cipher=AES256-GCM-SHA384) id F3/94-64897-4EBE88F5; Thu, 15 Oct 2020 20:40:05 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <24456.60388.135834.43951@jerusalem.litteratus.org> Date: Thu, 15 Oct 2020 20:40:04 -0400 From: Robert Huff To: questions@freebsd.org Subject: sh scripting question X-Mailer: VM 8.2.0b under 27.1 (amd64-portbld-freebsd13.0) X-Rspamd-Queue-Id: 4CC6kG1wX5z4D90 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=rcn.com header.s=20180516 header.b=VnGf5HmT; dmarc=pass (policy=none) header.from=rcn.com; spf=pass (mx1.freebsd.org: domain of roberthuff@rcn.com designates 69.168.97.78 as permitted sender) smtp.mailfrom=roberthuff@rcn.com X-Spamd-Result: default: False [-4.19 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[rcn.com:s=20180516]; RCVD_IN_DNSWL_LOW(-0.10)[69.168.97.78:from]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:69.168.97.0/24]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; NEURAL_HAM_LONG(-1.01)[-1.005]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[rcn.com:dkim]; RWL_MAILSPIKE_POSSIBLE(0.00)[69.168.97.78:from]; NEURAL_HAM_MEDIUM(-0.95)[-0.953]; DKIM_TRACE(0.00)[rcn.com:+]; DMARC_POLICY_ALLOW(-0.50)[rcn.com,none]; NEURAL_HAM_SHORT(-0.13)[-0.127]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:36271, ipnet:69.168.97.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[questions]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 00:40:07 -0000 I have a file ("files.list") with a list of filenames, similar to /path A/path B/FreeBSD is great.txt (note the embedded spaces) If I use for FILE in `cat files.list` FILE will be set to "/path". How do I get it to read the entire string? Or am I using the wrong tool? Respectfully, Robert Huff From owner-freebsd-questions@freebsd.org Fri Oct 16 01:06:19 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7C06B44B631 for ; Fri, 16 Oct 2020 01:06:19 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4CC7JW1c8jz4FjL for ; Fri, 16 Oct 2020 01:06:19 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id 355C744B804; Fri, 16 Oct 2020 01:06:19 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3519F44B4B9 for ; Fri, 16 Oct 2020 01:06:19 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05olkn2013.outbound.protection.outlook.com [40.92.91.13]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "GlobalSign Organization Validation CA - SHA256 - G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CC7JV07V5z4FXH for ; Fri, 16 Oct 2020 01:06:17 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gKAtXfUOldcOdeRgBf3/kzQnbvQ+dOr8cQUOa2yD9LkGbUQ95XdlbU4TPO4uSTzdPGK4kUdntXH0xPBIzHgNiwdXVlJvnIpj6WG19sXR+Dsl0ene6YI7gmMHE+p7P4Gb8OxvakO9DOhbF5oN0qH/rWQ0ClI1kbQ1yGxsmC6XCx4oZbKsoJt04byQZBi1ADgE4lNNu3MFqrAZHN4MfCElOBZEWkNb28nTMoxsis4Gc1C+vzSqe93qffEogFtPF5lzmpJy7+DLWVDaQhBX7B4PALRm+0Rpy+KT6fLHCytqIP4PzGAssIDffHMol/YGp8sZa8nZ9Khf9/GkUxdw5SvHlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XXWGnFKJlRqn2B335Svc0x3PWhwKuJGgDVcAEjMwKrE=; b=CbUjLxcdHNDsWcwgUnU1m59Moj+h5UnxcOdQ3C5t7+AxoH3WBo5d4gUzqcxQ9CyY5dWmcOn1MU+kKdRpV/GVmUIeodik49ca8y6NsGuRINPVWLsB7vRkEAPVjKgVWuIlgT6ks8oxF19cXBO1KNQkMT1GrZvFXFvmuM/dajnPvJD+gKiIvY1ofqDrHc04mqu6JcJEWBrbTYaylXTtu2y/3QaAb7mDOWZ2ZdtIeLF/Xt8ZlJ6Gk6QTWldnvklqEjHvAIjjfsKI5rX4m06y6pyc261jLgaX3HI6cJzjapWJL1cHXQxYVpYKkkXYWjIYBNijEOtuVqoiF9cbkv+zeqoVyQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XXWGnFKJlRqn2B335Svc0x3PWhwKuJGgDVcAEjMwKrE=; b=DuNpeZ30mHe9PT4VSQfH5erTy063wFAziFoJm6vziAvlhEEbEfhYD6ikETlQaM0OnsXIETfQByNFHy8BKkwVWi1bVnS2Oag9PLYyudmXlK5nkMk6WEcfzhqiNZXrkzghI9OycGtMHDt5kAPYWs9SFnDa4i1kRsZZbxwkHuE5Ud4nxsuIAYHiK7KPpCEup/RV/GoigK55hlOD/8cqt3j38miyGBdN2u71wxs7UcJrB7EaVhrmcqM3sRgm2oZsulpyDvt6IcOpdY9WHs77u8iRhG4dXU8KS9q1RuWIbGg1tgyz8frQHQ0LurZTVEVoHzS41OJQPzBb2AfanWST7p673A== Received: from VI1EUR05FT027.eop-eur05.prod.protection.outlook.com (2a01:111:e400:fc12::4f) by VI1EUR05HT158.eop-eur05.prod.protection.outlook.com (2a01:111:e400:fc12::384) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.23; Fri, 16 Oct 2020 00:50:14 +0000 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com (2a01:111:e400:fc12::43) by VI1EUR05FT027.mail.protection.outlook.com (2a01:111:e400:fc12::209) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 00:50:14 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:AB48780FC5FE06B234A506E6759841B67B278DC35B5602760C61D22ADAAF046B; UpperCasedChecksum:C4303F30C0CD37D89F54754E4A9DE8768FB1C2AE07F14037ED34A2B90D214A55; SizeAsReceived:8647; Count:47 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f]) by DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f%9]) with mapi id 15.20.3477.023; Fri, 16 Oct 2020 00:50:13 +0000 Subject: Re: sh scripting question To: Robert Huff , questions@freebsd.org References: <24456.60388.135834.43951@jerusalem.litteratus.org> From: Manish Jain Message-ID: Date: Fri, 16 Oct 2020 06:20:05 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 In-Reply-To: <24456.60388.135834.43951@jerusalem.litteratus.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-TMN: [KDgfld3zN/XuD7vdONSQCBaVDymiU1NoeRkEwD5C65c=] X-ClientProxiedBy: BM1PR01CA0135.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:40::29) To DB8PR06MB6442.eurprd06.prod.outlook.com (2603:10a6:10:126::7) X-Microsoft-Original-Message-ID: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.2] (103.195.202.206) by BM1PR01CA0135.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:40::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 00:50:12 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: aff7bc13-a9de-4432-0706-08d8716d7101 X-MS-TrafficTypeDiagnostic: VI1EUR05HT158: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: owxGcVemWok2aHJaICbRiAjCS5++Ss06Om6ol6avfE4myTELp09JmbUxxiMJ5dUhQEcP3GMiNXa2Sm09EYC/XMrbazP3YsUKt8fj4b5IiGc7YjpA/cKzxubB4WDBIYdAAoupny0tnGn0Cg6U5oXAJ+2xw0oxGo8Gk+RU4K9QjLsX7rC6ivBFIjM96K9g5/+B/ZjN6ZxjH4gokzHJVLR0bzlPkVo6xJFbbv7RzgigcolA1Ax5230jo2yeQz2SiAXc X-MS-Exchange-AntiSpam-MessageData: RziQECc7GzthhgUb4x41TTRE3DS8qo1lUdZqikcicoRvleE7LOF1gQEyI0nhdoaooUnZpuIUKhBelkODyxYg7AiiHhOi8/TpMlifhm4OoIHpUM3ggJzf6MOkRGaEQNg4EHlTu/88GrNG2CEOErHzcQ== X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-Network-Message-Id: aff7bc13-a9de-4432-0706-08d8716d7101 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 00:50:13.8801 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: VI1EUR05FT027.eop-eur05.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1EUR05HT158 X-Rspamd-Queue-Id: 4CC7JV07V5z4FXH X-Spamd-Bar: +++++++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=DuNpeZ30; dmarc=pass (policy=none) header.from=hotmail.com; spf=pass (mx1.freebsd.org: domain of bourne.identity@hotmail.com designates 40.92.91.13 as permitted sender) smtp.mailfrom=bourne.identity@hotmail.com X-Spamd-Result: default: False [7.19 / 15.00]; TO_DN_SOME(0.00)[]; FREEMAIL_FROM(0.00)[hotmail.com]; R_SPF_ALLOW(0.00)[+ip4:40.92.0.0/15]; DKIM_TRACE(0.00)[hotmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(0.00)[hotmail.com,none]; NEURAL_HAM_SHORT(-0.39)[-0.394]; RECEIVED_SPAMHAUS_PBL(0.00)[103.195.202.206:received]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; ASN(0.00)[asn:8075, ipnet:40.80.0.0/12, country:US]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; ARC_ALLOW(0.00)[microsoft.com:s=arcselector9901:i=1]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; RECEIVED_SPAMHAUS_XBL(5.00)[103.195.202.206:received]; R_DKIM_ALLOW(0.00)[hotmail.com:s=selector1]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_MEDIUM(-0.30)[-0.299]; MIME_GOOD(-0.10)[text/plain]; BAD_REP_POLICIES(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.39)[0.387]; RCVD_IN_DNSWL_NONE(0.00)[40.92.91.13:from]; RWL_MAILSPIKE_POSSIBLE(0.00)[40.92.91.13:from]; GREYLIST(0.00)[pass,body]; MAILMAN_DEST(0.00)[questions] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 01:06:19 -0000 Hi Robert, Try : for FILE in "`cat files.list`" Good luck, Manish Jain On 2020-10-16 06:10, Robert Huff wrote: > > I have a file ("files.list") with a list of filenames, similar to > > /path A/path B/FreeBSD is great.txt > > (note the embedded spaces) > If I use > > for FILE in `cat files.list` > > FILE will be set to "/path". > How do I get it to read the entire string? > Or am I using the wrong tool? > > > Respectfully, > > > Robert Huff > > > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" > From owner-freebsd-questions@freebsd.org Fri Oct 16 01:31:08 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id DD0F044BD85 for ; Fri, 16 Oct 2020 01:31:08 +0000 (UTC) (envelope-from vrwmiller@gmail.com) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4CC7s84rb0z4GMQ for ; Fri, 16 Oct 2020 01:31:08 +0000 (UTC) (envelope-from vrwmiller@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id A35F444BD84; Fri, 16 Oct 2020 01:31:08 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A1F8C44BB2A for ; Fri, 16 Oct 2020 01:31:08 +0000 (UTC) (envelope-from vrwmiller@gmail.com) Received: from mail-il1-x12a.google.com (mail-il1-x12a.google.com [IPv6:2607:f8b0:4864:20::12a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CC7s74qhYz4GMP for ; Fri, 16 Oct 2020 01:31:07 +0000 (UTC) (envelope-from vrwmiller@gmail.com) Received: by mail-il1-x12a.google.com with SMTP id j13so864279ilc.4 for ; Thu, 15 Oct 2020 18:31:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=f+s/qEPIT2CB025IyGI4s/7eF24bDGsh/sWvFd/uU1o=; b=eGJwVxLTg0VQYZyapwFFUyx4NhZB7CUb2P7TB0d+5u1Xib5v6CG3cKyVHXY1mj7FiO BIKC7y1ih5MtHDbKsaX1MprdD1Ig93CUjmdhd5p4bl1OznNd2kFI4amT1tHCRG5+Lc2Y u+qVnhu0iJqdpbs5T4PxP0awvbSqNewFRa3ypSHs7hMIiGADrN3BJ9ApeLGhPQHqHSkb 6euCmlzK7FprFDY2/pOYN1i+QWWmqfEyfjEfY379UVqQR1+ERkM2Qpg5ll/PMNmMjwpV EMDsn2beAqffYWOoi/bh2H9wDjzbd0ukyM0+sw8Q+shuhH36bftoLMmsbQfBwbpvuIAy nliw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=f+s/qEPIT2CB025IyGI4s/7eF24bDGsh/sWvFd/uU1o=; b=lgARMiq9qbQIOHhEANTyGb8qldzuJoC8IJHCwIOVvvhIRNhYKufIdeiK4OCTfpC3S1 CHDvVh5w4S8X2DEAN9Qqe4bQcuBOlhLsBTWIfJ79u5+g/7ygkdspkQuVaS5ckrgyijLT v2lQddR56gEuwzInAGYenbV/BGuqzwrxQYjhB9N3ZLM2MOdpQSa5m6SK57G17R6SR0sd A8rzsj6An1wUQN8e9i1p6iCM89KaCF2kXD48gTidbwJdDB0729K096SaQr1KGzBsfSkP kqE+0bGdrS1aMA+pYLCjsltaRxLQb2TpZLHorPjzSTMMGIhpTk9zwauO37mBmaS7WUqm Gdjw== X-Gm-Message-State: AOAM530e3XUZpTROdeT4yqGaeAX2JSZGJr0WCCAKxZ0OJDQhrn6IRvSg U6L/m4UIOBace5uciu0P4RFZdyXkle0PheWzqis= X-Google-Smtp-Source: ABdhPJw+RLcKfTHHOg/wxNzs+Im0tl469PO1yuXxbdu31iNch8i+zJ/xKWdqQoj4NX0xcis4Ipp/hTdeEM1RVrAUMBU= X-Received: by 2002:a92:c04d:: with SMTP id o13mr901785ilf.218.1602811866492; Thu, 15 Oct 2020 18:31:06 -0700 (PDT) MIME-Version: 1.0 References: <24456.60388.135834.43951@jerusalem.litteratus.org> In-Reply-To: <24456.60388.135834.43951@jerusalem.litteratus.org> From: Rick Miller Date: Thu, 15 Oct 2020 21:30:54 -0400 Message-ID: Subject: Re: sh scripting question To: Robert Huff Cc: FreeBSD questions X-Rspamd-Queue-Id: 4CC7s74qhYz4GMP X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=eGJwVxLT; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of vrwmiller@gmail.com designates 2607:f8b0:4864:20::12a as permitted sender) smtp.mailfrom=vrwmiller@gmail.com X-Spamd-Result: default: False [-3.49 / 15.00]; RCVD_TLS_ALL(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; NEURAL_HAM_MEDIUM(-1.04)[-1.041]; FROM_HAS_DN(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[questions@freebsd.org]; NEURAL_HAM_LONG(-1.00)[-1.001]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::12a:from]; NEURAL_HAM_SHORT(-0.45)[-0.446]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[questions]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 01:31:08 -0000 On Thu, Oct 15, 2020 at 8:40 PM Robert Huff wrote: > > I have a file ("files.list") with a list of filenames, similar to > > /path A/path B/FreeBSD is great.txt > > (note the embedded spaces) > If I use > > for FILE in `cat files.list` > > FILE will be set to "/path". > How do I get it to read the entire string? > Or am I using the wrong tool? > $ cat f.in /path A/path B/FreeBSD is great.txt /path T/path Q/FreeBSD rocks.txt $ while read line; do > echo $line > done < f.in /path A/path B/FreeBSD is great.txt /path T/path Q/FreeBSD rocks.txt -- Take care Rick Miller From owner-freebsd-questions@freebsd.org Fri Oct 16 02:40:18 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 90AC944CC62 for ; Fri, 16 Oct 2020 02:40:18 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-oln040092066011.outbound.protection.outlook.com [40.92.66.11]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "GlobalSign Organization Validation CA - SHA256 - G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CC9Nx1RSHz4KFn for ; Fri, 16 Oct 2020 02:40:16 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=maIeQKPg0sZ00xIeABKTqI6vKHO4vwqq28i/ma/YBwhR+odorAzn5fINB60TTk9/gCdWSu4A6doHpA8KYFCUCFa7Qpl/+n3jQqCfsgZkBDCmnRCPnDDfbfnomAVG6/gR0gvssiwZe2vDZEn6wD8I7NKjpgjPJxYLqYcwn7PLlDW0VhBIL8IJcpH3Ol1afVHyvC0jh6L9bUDPX522f0m+lmrnrHYaEIvKoVV6Rnh1v+AQElG6nNg4iUSeB5O/TfLnbrEV4h4a0Zvu0/k9ZQCe2alb6JiiEyP44vWkqGXL5EtkhZ0oXp6GQKeRxzHHmCaDqYmsL3ZuhDWd4+D5K93KUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=yFzZ2SEISl7Bp2pn0StJFNmOgSPlbtVsPVt3+4WiSz8=; b=NzvJ9pC/oloagVrU541CvQqMtMXauxVgyKNcXpiUGTDpoJc17Rr9Jj2CFoTKmOAupKCWex1X4K5mpHuxrLfoOQpOxSCT0uY3GhZQLzngzW7CwNtsdgY1Ub4Dq1C3VcdNxAJSV4ZKUdJCS5TWOlLTThUlufPZVtKxSIa5VmjoqMg5Ik3vhd/IJDffvowLZ2t0Nwa2bf4z5WKwZSogE1T/6+44IertSACFVX8l7ECNp2HdfoxasrVE8+xVDVg6sq8IRuLd/qhFI1py48iO5WG3Z9A5+th4U37ycKaTwQgdhpwSKZOOgIY1uLNdrNMbrjAw54L83ZWtpa72JJeZZzhyYg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=yFzZ2SEISl7Bp2pn0StJFNmOgSPlbtVsPVt3+4WiSz8=; b=Y3T2MNf/T0mdzIRHoTQUDqb45kbuS4RuMlHZXHgg0+BNJpo5TAdKXhsZ7yKk+ZhEYaGpwSirffDdhMrTQdk9Fj/0i4iIdgvL+pLJBjN3sWUiKARYedzYOE48V8MLOoYTsChXxlYV74r6YtZnmEx7mI3RJWOxOCtFCA+f0vslBiah/M+FZhnZNJQPJsxKXiPsViN9IGMbSPNb5W1dxBrs43TCB/s5vCoB7Qfx27Z8NA+PC+iQRehLUdlaMBKM1zLVma9Q9W9J3v0COsGKmfOTWH9mQTlf2ujvBgrE8o0s8gfieoQDyCiIWGQztmXYXUQJrVU8QKlb4Ooto7Ctr3GwPg== Received: from HE1EUR01FT058.eop-EUR01.prod.protection.outlook.com (2a01:111:e400:7e18::42) by HE1EUR01HT029.eop-EUR01.prod.protection.outlook.com (2a01:111:e400:7e18::341) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21; Fri, 16 Oct 2020 02:40:14 +0000 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com (2a01:111:e400:7e18::4e) by HE1EUR01FT058.mail.protection.outlook.com (2a01:111:e400:7e18::218) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 02:40:14 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:21730E68069DC30E050E126FF1C609213B8CBF22C965477772CA521E7B7FD7FE; UpperCasedChecksum:B8D0B68BE60D40873AD15F8337EBD35646CB2B8825E13EDA3A491D362A0FD143; SizeAsReceived:8854; Count:47 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f]) by DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f%9]) with mapi id 15.20.3477.023; Fri, 16 Oct 2020 02:40:14 +0000 Subject: Re: sh scripting question From: Manish Jain To: Robert Huff , FreeBSD References: <24456.60388.135834.43951@jerusalem.litteratus.org> <24456.61612.942942.811357@jerusalem.litteratus.org> <3aab3608-c9be-a944-77a4-6d0e3ac34c5b@hotmail.com> Message-ID: Date: Fri, 16 Oct 2020 08:10:07 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 In-Reply-To: <3aab3608-c9be-a944-77a4-6d0e3ac34c5b@hotmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 8bit X-TMN: [w1AAu/ZkX0y3Jc00TPRAXiCzXrj8qkrFOfpwhak8YtY=] X-ClientProxiedBy: BM1PR01CA0152.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:68::22) To DB8PR06MB6442.eurprd06.prod.outlook.com (2603:10a6:10:126::7) X-Microsoft-Original-Message-ID: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.2] (103.195.202.206) by BM1PR01CA0152.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:68::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 02:40:13 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: 0e82ba51-3709-4113-8b6c-08d8717ccf9c X-MS-TrafficTypeDiagnostic: HE1EUR01HT029: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: no6stN1OHn7WOZeSeM28dH4XCTi39K9T28d9qEDkABJRe6fE+IR2GK33dVTfuZbQHaVHDINxdC079sUtpJaVRMyB/XLy6ZWAprPcMciFvNCIP/aaj5CMoxVdWmN6GoJdLDzQvrWyvjPqJWuYcWdXdBJrI2+2kiJDemE3gwMGSkBz8rSZVbIDo6S/5zgVUNjlXNYSXaix5hTcx/2B4JaR8A== X-MS-Exchange-AntiSpam-MessageData: DfmsWZHDvqdOl95hLQlqwQqFXvYjZYczocxmD0AxcRkBcKaMKHzCAPFzFi0UMu8heUPnlqyKZqlsZ5kLw27irxWuYQjzbF6IXkfAnDBLTxb6DQrOV11hxmP4ZB+VkpiLTxyQSnjTsf2KRAP9GFTAEw== X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0e82ba51-3709-4113-8b6c-08d8717ccf9c X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 02:40:14.8092 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: HE1EUR01FT058.eop-EUR01.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1EUR01HT029 X-Rspamd-Queue-Id: 4CC9Nx1RSHz4KFn X-Spamd-Bar: ++++++++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=Y3T2MNf/; dmarc=pass (policy=none) header.from=hotmail.com; spf=pass (mx1.freebsd.org: domain of bourne.identity@hotmail.com designates 40.92.66.11 as permitted sender) smtp.mailfrom=bourne.identity@hotmail.com X-Spamd-Result: default: False [8.34 / 15.00]; FREEMAIL_FROM(0.00)[hotmail.com]; R_SPF_ALLOW(0.00)[+ip4:40.92.0.0/15]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[hotmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(0.00)[hotmail.com,none]; NEURAL_HAM_SHORT(-0.10)[-0.095]; RECEIVED_SPAMHAUS_PBL(0.00)[103.195.202.206:received]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; ASN(0.00)[asn:8075, ipnet:40.80.0.0/12, country:US]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; ARC_ALLOW(0.00)[microsoft.com:s=arcselector9901:i=1]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; RECEIVED_SPAMHAUS_XBL(5.00)[103.195.202.206:received]; R_DKIM_ALLOW(0.00)[hotmail.com:s=selector1]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_MEDIUM(0.22)[0.215]; BAD_REP_POLICIES(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.72)[0.715]; RCVD_IN_DNSWL_NONE(0.00)[40.92.66.11:from]; RWL_MAILSPIKE_POSSIBLE(0.00)[40.92.66.11:from]; GREYLIST(0.00)[pass,meta]; MAILMAN_DEST(0.00)[freebsd-questions] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 02:40:18 -0000 Corrections: the backslash on the third line is wrong: > oldifs="$IFS" > IFS=$’\n’ > for f in "`cat files.list`" \ > #stuff > done > IFS="$oldifs" So that should be : oldifs="$IFS" IFS=$’\n’ for f in "`cat files.list`" #stuff done IFS="$oldifs" Sorry for the typo, Manish Jain On 2020-10-16 08:02, Manish Jain wrote: > > > On 2020-10-16 06:30, Robert Huff wrote: >> >> Hello: >> >>>    Try : >>>    for FILE in "`cat files.list`" >> >>     That's better ... but sets FILE to the entire content of >> files.list. >>     I'm trying to pick off one line at a time for further processing. >>     (I feel like I've done this before - successfully - and for some >> reason now it's not working.  ) > > Hi Huff, > > > You have to set/reset IFS : > > oldifs="$IFS" > IFS=$’\n’ > for f in "`cat files.list`" \ > #stuff > done > IFS="$oldifs" > > Regards, > Manish Jain From owner-freebsd-questions@freebsd.org Fri Oct 16 02:48:34 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 011CD44D063 for ; Fri, 16 Oct 2020 02:48:34 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-oln040092069089.outbound.protection.outlook.com [40.92.69.89]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "GlobalSign Organization Validation CA - SHA256 - G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CC9ZS6TDVz4Kfb for ; Fri, 16 Oct 2020 02:48:32 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=H8mFIXCc8Cfcn7Qm2t+EUbQrZU7F7XDW1O3eAoCbtvuccgKwD4cC/359vZ/hpLTsKpeubtq8h3LkmiSH+lcWg7ZMTkeAY8WTI28HcPJHPnlD6tDt0yFfzXALVIQEppDYzYys5n8qkUolXy/9GPma14jwaQ0elvKzFT1XWYQ6vaFlusfXHv9spXLuYEIjONT9voLpvTemU44kR5D8fY2qVGGVBqHt0WgXiCBALC1cD8/NUnG+F3Tad6J+HOiU3/iM/DqyPbLvVhnrE/IE6EDAw/Yi+meY6bqwsY7sZLcsYomOIYOakaL+eh2KO+eIw1CxgA1jZfFUeF2ctdJcX5LALA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=J0vV0zDUPcU0SQaDWV3BYQQQCRLlds/DxOtuErBJ2iY=; b=IN9Zs/1VQ8+MjBInauAVgKT8EackKNj93eLzgfK+D7fwBdiw/pGD1bihzlAZzoD9W2J9yQ/28dggHslmBG9nu1KCx1WQTsgQklSI2hlqiELq6JBtoqh4rUpaCYql+BsH+oBjziYzVN1FtOvlHU6MqNr7wXtIlOtCcRQe+y2PS6VksTMDVcgyd3QZzgesANKMUTOhJrwZwgH4kdcv+6gPqPlllpzfCnsqJNoC+M2VvFOMYKlVDQ38xu3S+oA6nokuHr7W5yhand5dNesMf0tfOyPVkw1fkbJXzOBO+Byy3+fEzSY7A7oDzNc4B5aOHWT7ur/aoDBmU1MYbHJ97x0Zhg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=J0vV0zDUPcU0SQaDWV3BYQQQCRLlds/DxOtuErBJ2iY=; b=p7i7gYg8a4Wv8BpWH9WxsI1NHNN+x76IKQg2DxEIb97R0DHVomNi6EMu3fc17jU9SIIl+AnfQxKsFQmU2uXtUYz2DjIuSpm5UNLqCr0DBRFXRI1zZJoQ4CYySyF2i7OcKs/h2i5mWNcuVQVXiH55Tzy65/+5zjzUHeEmEsrt6ekjJKi7MktjiPpJTVkQKe3/f1tFheryB6RHFkYgvR/GtfQD02Yv3fpdGXZxf+rbRIh/Qg1r8krT8YBjCnZjTL6q2FpQOM7cKbeRq/qsgz4sCqpiumxAYp1lrCmE54ORaoAHAzN6Tr3WxvI7C3MlQvrkOPLKFckI0MWf6k2kC6Yg+Q== Received: from HE1EUR02FT012.eop-EUR02.prod.protection.outlook.com (2a01:111:e400:7e1d::47) by HE1EUR02HT133.eop-EUR02.prod.protection.outlook.com (2a01:111:e400:7e1d::332) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21; Fri, 16 Oct 2020 02:32:48 +0000 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com (2a01:111:e400:7e1d::40) by HE1EUR02FT012.mail.protection.outlook.com (2a01:111:e400:7e1d::75) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 02:32:48 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:2B96ACC03ABDC7326340EE0C3C3044ADCFD95A314ACA4CA466B3FF9ED624156B; UpperCasedChecksum:A6388399D52D4304F676E235265CDF01B65740297B2E10AE1E13B0D7F32E6730; SizeAsReceived:8794; Count:47 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f]) by DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f%9]) with mapi id 15.20.3477.023; Fri, 16 Oct 2020 02:32:48 +0000 Subject: Re: sh scripting question To: Robert Huff , FreeBSD References: <24456.60388.135834.43951@jerusalem.litteratus.org> <24456.61612.942942.811357@jerusalem.litteratus.org> From: Manish Jain Message-ID: Date: Fri, 16 Oct 2020 08:02:41 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 In-Reply-To: <24456.61612.942942.811357@jerusalem.litteratus.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 8bit X-TMN: [mYUZVoQ/4Fj3iLDdaW/U/psJCrX1OFqSgFgoLsf2aKA=] X-ClientProxiedBy: BM1PR01CA0143.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:68::13) To DB8PR06MB6442.eurprd06.prod.outlook.com (2603:10a6:10:126::7) X-Microsoft-Original-Message-ID: <3aab3608-c9be-a944-77a4-6d0e3ac34c5b@hotmail.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.2] (103.195.202.206) by BM1PR01CA0143.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:68::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.20 via Frontend Transport; Fri, 16 Oct 2020 02:32:48 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: 7ec667e0-2511-4656-a1b3-08d8717bc5c5 X-MS-TrafficTypeDiagnostic: HE1EUR02HT133: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: FI4j3dZyMU0HIianWCz3w18PX0r38ynHv8UVTUh7x8BYwnzS1uzFlhWZeZbOiQIR77i/VpEaI6sygJ9RgNj5peDgLbPMrsStprrXZBpOBfeEB9SPPlZQY3ddd2yFhG1d+fJWj49pSh4N3qjSs1WZ0A7tfT7WtEOKltckNuV61A7NzSlr+Pv95dzUJSuN6Bc54nKFIhPDX0IsqntiksLpUw== X-MS-Exchange-AntiSpam-MessageData: FYiWuhzXGDpIJixulbK3bkO2jPwaFpdQUYAJzhjo+fOwEF+MipPdBRdngeTLO4+irCZotEqfbBbGRGh1uNmJh3RoWEP/UmZklx3CiUouMowIgrWDU1JMCfi9zuAkbdGWCDnHvEDZevBptMxsnRgj0w== X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7ec667e0-2511-4656-a1b3-08d8717bc5c5 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 02:32:48.8015 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: HE1EUR02FT012.eop-EUR02.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1EUR02HT133 X-Rspamd-Queue-Id: 4CC9ZS6TDVz4Kfb X-Spamd-Bar: +++++++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=p7i7gYg8; dmarc=pass (policy=none) header.from=hotmail.com; spf=pass (mx1.freebsd.org: domain of bourne.identity@hotmail.com designates 40.92.69.89 as permitted sender) smtp.mailfrom=bourne.identity@hotmail.com X-Spamd-Result: default: False [7.88 / 15.00]; FREEMAIL_FROM(0.00)[hotmail.com]; R_SPF_ALLOW(0.00)[+ip4:40.92.0.0/15]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[hotmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(0.00)[hotmail.com,none]; NEURAL_HAM_SHORT(-0.30)[-0.303]; RECEIVED_SPAMHAUS_PBL(0.00)[103.195.202.206:received]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; ASN(0.00)[asn:8075, ipnet:40.80.0.0/12, country:US]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; FROM_EQ_ENVFROM(0.00)[]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; RECEIVED_SPAMHAUS_XBL(5.00)[103.195.202.206:received]; R_DKIM_ALLOW(0.00)[hotmail.com:s=selector1]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; ARC_ALLOW(0.00)[microsoft.com:s=arcselector9901:i=1]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_MEDIUM(0.09)[0.087]; BAD_REP_POLICIES(0.10)[]; RCVD_IN_DNSWL_LOW(-0.10)[40.92.69.89:from]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.69)[0.693]; RWL_MAILSPIKE_POSSIBLE(0.00)[40.92.69.89:from]; GREYLIST(0.00)[pass,body]; MAILMAN_DEST(0.00)[freebsd-questions] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 02:48:34 -0000 On 2020-10-16 06:30, Robert Huff wrote: > > Hello: > >> Try : >> >> for FILE in "`cat files.list`" > > That's better ... but sets FILE to the entire content of > files.list. > I'm trying to pick off one line at a time for further processing. > (I feel like I've done this before - successfully - and for some > reason now it's not working. ) Hi Huff, You have to set/reset IFS : oldifs="$IFS" IFS=$’\n’ for f in "`cat files.list`" \ #stuff done IFS="$oldifs" Regards, Manish Jain From owner-freebsd-questions@freebsd.org Fri Oct 16 03:05:13 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 29A4444D970 for ; Fri, 16 Oct 2020 03:05:13 +0000 (UTC) (envelope-from bob@proulx.com) Received: from havoc.proulx.com (havoc.proulx.com [96.88.95.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CC9xh1fznz4MCy for ; Fri, 16 Oct 2020 03:05:11 +0000 (UTC) (envelope-from bob@proulx.com) Received: from joseki.proulx.com (localhost [127.0.0.1]) by havoc.proulx.com (Postfix) with ESMTP id ADD5F59E for ; Thu, 15 Oct 2020 21:05:04 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proulx.com; s=dkim2048; t=1602817504; bh=FEwfeW6kQRh5nINek0hgdIQ7CK3m4dwhSeGyxFqSjvU=; h=Date:From:To:Subject:References:In-Reply-To:From; b=LIWGZZBKKF28PbYs64q1+PUTDMifp0k+sHIWch7tpVZvzufbHxC1kaEl50YFF2aGQ TCiVRJKlasNjDckvDfX0y0aUKVEXFnMdZYcCXJEnljgeBRgPGbJRpYkjg/YohuGANp n7Q9FF+2cbczvetH7HgCEApLE6soWgXkPWEwfqeyNgUiJG14RokHZTe6oEd5uenjRh fPOqJtb5Tm6xNprH/LKqpIUT+RZeMpUP6/deIt6qHGx1uqyUs5MOzUDP2sUyxyUjyV rt1G+Kn/cR6r+mWYfB3rey2oMDM6ExMIPsUUjU2UihHDOKbBWDSBCBTmMwHCMwCLHu tJVJZmikvkZGw== Received: from hysteria.proulx.com (hysteria.proulx.com [192.168.230.119]) by joseki.proulx.com (Postfix) with ESMTP id 89A6121D63 for ; Thu, 15 Oct 2020 21:05:04 -0600 (MDT) Received: by hysteria.proulx.com (Postfix, from userid 1000) id 778062DC9D; Thu, 15 Oct 2020 21:05:04 -0600 (MDT) Date: Thu, 15 Oct 2020 21:05:04 -0600 From: Bob Proulx To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201015204226099763897@bob.proulx.com> References: <24456.60388.135834.43951@jerusalem.litteratus.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <24456.60388.135834.43951@jerusalem.litteratus.org> X-Rspamd-Queue-Id: 4CC9xh1fznz4MCy X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=proulx.com header.s=dkim2048 header.b=LIWGZZBK; dmarc=pass (policy=none) header.from=proulx.com; spf=pass (mx1.freebsd.org: domain of bob@proulx.com designates 96.88.95.61 as permitted sender) smtp.mailfrom=bob@proulx.com X-Spamd-Result: default: False [-4.08 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.997]; R_DKIM_ALLOW(-0.20)[proulx.com:s=dkim2048]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+a]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.01)[-1.013]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[proulx.com:+]; DMARC_POLICY_ALLOW(-0.50)[proulx.com,none]; NEURAL_HAM_SHORT(-1.07)[-1.065]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7922, ipnet:96.64.0.0/11, country:US]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 03:05:13 -0000 Robert Huff wrote: > I have a file ("files.list") with a list of filenames, similar to > /path A/path B/FreeBSD is great.txt > (note the embedded spaces) Oh you are tormenting us now. :-) There are some subtle issues here. > If I use > > for FILE in `cat files.list` > > FILE will be set to "/path". > How do I get it to read the entire string? > Or am I using the wrong tool? For the pedantic you want to temporarily set IFS and you want to use the -r option. It probably won't matter with you exact specific case above because you want the entire line and you do not have leading or trailing spaces and you are not using any escapes in your file names. But if you did then it would matter. First see the sh man page and see this passage. Backslashes are treated specially, unless the -r option is specified. If a backslash is followed by a newline, the backslash and the newline will be deleted. If a backslash is followed by any other character, the backslash will be deleted and the following character will be treated as though it were not in IFS, even if it is. If your brains are not yet leaking out your ears then go here: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_06_05 And see this line: 2. If the value of IFS is null, no field splitting shall be performed. That is why setting IFS= (same as IFS="" with the useless "" part) turns off word splitting. It's a special case. If IFS= the empty string then no field splitting is performed. (The standard is much more clear and forceful on this topic than the man page.) And therefore both are needed to completely handle a data line with potential spaces and backslashes in it. If file1 contains: /path A/path B/FreeBSD is great.txt /path A/path C/FreeBSD is fun.txt Then we can read it with both IFS= and read -r this way. while IFS= read -r line; do printf "|%s|\n" "$line" done < file1 |/path A/path B/FreeBSD is great.txt| |/path A/path C/FreeBSD is fun.txt| And if there are leading or trailing spaces in file1 then those spaces will be brought through verbatim without trimming. And maybe these test cases that poke at the corners will make things a little more clear. $ printf "%s\n" " foo \t bar " | while read line; do printf "|%s|\n" "$line"; done |foo t bar| $ printf "%s\n" " foo \t bar " | while read -r line; do printf "|%s|\n" "$line"; done |foo \t bar| $ printf "%s\n" " foo \t bar " | while IFS= read -r line; do printf "|%s|\n" "$line"; done | foo \t bar | Another hint is that the shell handles for and while loops in a pipeline by creating a subshell for them. Which means that variables can't be set in the parent shell. That's why it is good and convenient to use a pipeline on the command line, it prevents setting variables in the command line shell. But in a script usually it is better to use a "... done < file1" redirection so that it is invoked within the currently existing shell process so that variables can be set in the parent shell. Hope this helps! :-) Bob From owner-freebsd-questions@freebsd.org Fri Oct 16 03:14:18 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 158A344DCCB for ; Fri, 16 Oct 2020 03:14:18 +0000 (UTC) (envelope-from kh@panix.com) Received: from mailbackend.panix.com (mailbackend.panix.com [166.84.1.89]) (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 4CCB893195z4MR7 for ; Fri, 16 Oct 2020 03:14:17 +0000 (UTC) (envelope-from kh@panix.com) Received: from rain.home (pool-173-48-64-3.bstnma.fios.verizon.net [173.48.64.3]) by mailbackend.panix.com (Postfix) with ESMTPSA id 4CCB885p8dzVnN for ; Thu, 15 Oct 2020 23:14:16 -0400 (EDT) Subject: Re: sh scripting question To: freebsd-questions@freebsd.org References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> From: Kurt Hackenberg Message-ID: Date: Thu, 15 Oct 2020 23:14:13 -0400 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 MIME-Version: 1.0 In-Reply-To: <20201015204226099763897@bob.proulx.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCB893195z4MR7 X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of kh@panix.com designates 166.84.1.89 as permitted sender) smtp.mailfrom=kh@panix.com X-Spamd-Result: default: False [-1.36 / 15.00]; RCVD_TLS_ALL(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[166.84.1.89:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:166.84.0.0/16]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.01)[-0.012]; ARC_NA(0.00)[]; RCVD_IN_DNSWL_MED(-0.20)[166.84.1.89:from]; NEURAL_HAM_SHORT(-0.30)[-0.300]; DMARC_NA(0.00)[panix.com]; NEURAL_HAM_MEDIUM(-0.55)[-0.546]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:2033, ipnet:166.84.0.0/16, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions]; RECEIVED_SPAMHAUS_PBL(0.00)[173.48.64.3:received] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 03:14:18 -0000 On 2020-10-15 23:05, Bob Proulx wrote: > Oh you are tormenting us now. :-) There are some subtle issues here. Maybe a shell is the wrong tool. From owner-freebsd-questions@freebsd.org Fri Oct 16 03:48:21 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7AB3C44E93C for ; Fri, 16 Oct 2020 03:48:21 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCBvS583Jz4Nmy for ; Fri, 16 Oct 2020 03:48:20 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCBvG6WzpzDsyh for ; Thu, 15 Oct 2020 20:48:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602820090; bh=shHO+yDi7Hg9M080Em/DdVFp4baTSgevWQEQqbh1ylY=; h=Date:From:To:Subject:In-Reply-To:References:From; b=lmF/Lh+ydX+vTYwIlJpgcn0GhZLam3IC2Bw1B2AQA9PWh/9i+VviwmFO8YhabN8pX aeETvZaxWCVbiZb/qAOZZH2Th2kdNixxf5E5a50Xypy/rqD778R6z1UMjMj2C1NL3H DoQ97VyucoK59pBCgM9qEANF8PS+6eWtyG4Qk+1Y= X-Riseup-User-ID: CBA2FE826F596E7E627F51E0B72D36995F6862A952E43E463EAEBD1F2C83972D Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CCBvG1djbzJmq1 for ; Thu, 15 Oct 2020 20:48:10 -0700 (PDT) Date: Fri, 16 Oct 2020 05:47:57 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016054735.33ad768e@archlinux> In-Reply-To: <20201015204226099763897@bob.proulx.com> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCBvS583Jz4Nmy X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=lmF/Lh+y; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.62 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.98)[-0.978]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-1.03)[-1.025]; NEURAL_HAM_LONG(-1.02)[-1.018]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 03:48:21 -0000 On Thu, 15 Oct 2020 21:05:04 -0600, Bob Proulx wrote: >leading or trailing spaces Hi, IMO our scripts should not waste resources to work around insane path and/or file names such as $ touch " ; && || \\ .txt # " or other issues, unless a third party could misuse missing workarounds. In some real world corner cases, you better don't use a script at all, see https://lists.claws-mail.org/pipermail/users/2020-October/027113.html , where the scrip impossibly can work around the "issue" in the first place. Scripts are useful tools, but they cannot be used for everything. A script used to handle paths and files on our own machines, run by us, should be written to handle sane path and file names, since we should use only sane path and file names, period. To me already "FreeBSD is great.txt" isn't a good file name, I would name it "freebsd_is_great.txt", but that's just me. However, naming it " FreeBSD is great.txt ", would be just stupid. 2 Cents, Ralf From owner-freebsd-questions@freebsd.org Fri Oct 16 04:11:11 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9E57644F0A6 for ; Fri, 16 Oct 2020 04:11:11 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCCPp60QRz4PCq for ; Fri, 16 Oct 2020 04:11:10 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCCPj1jNDzFcv3 for ; Thu, 15 Oct 2020 21:11:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602821465; bh=KiEanPgRZVG2eQ3qcNNyhagSPJV7jYgLzXmnjlRaBXs=; h=Date:From:To:Subject:In-Reply-To:References:From; b=kOOoGZXZ4NEIPxYkIMgH8UY0PyiXRMxdayVwlCmH6TOnZyIYPDClSbmHhAtYJGc7U jhWjxjjA3CTwVzkinrmIsO34jJRYuS8XcBfB1YUOopG5Tl4oYaWJyUjOnFvCvowLL1 vJw/aW3hXHaKJlpvXch+qWI+D4wL23pPZ1SkS/y4= X-Riseup-User-ID: B8DB63AF19124AE9C1DF9AAAF412B150A6D25E7730A0C763402EFE881CCD24CC Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4CCCPh3vjsz8tq0 for ; Thu, 15 Oct 2020 21:11:04 -0700 (PDT) Date: Fri, 16 Oct 2020 06:10:55 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016061055.6b1354b5@archlinux> In-Reply-To: <20201016054735.33ad768e@archlinux> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016054735.33ad768e@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 4CCCPp60QRz4PCq X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=kOOoGZXZ; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.56 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.98)[-0.980]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.96)[-0.964]; NEURAL_HAM_LONG(-1.02)[-1.019]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 04:11:11 -0000 On Fri, 16 Oct 2020 05:47:57 +0200, Ralf Mardorf wrote: >On Thu, 15 Oct 2020 21:05:04 -0600, Bob Proulx wrote: >>leading or trailing spaces =20 File names that contain chars, that could invoke a (sub)shell, function, ..., e.g. recursively executing itself, or even simple commands, should be read as file names by scripts, but humans make mistakes and those file names accidentally could be executed, when writing and testing a script. Using just a common delimiter only, is not that dangerous, but why using a common delimiter, such as a space? I even wouldn't use the whole set of UTF-8 chars. Usage isn't dangerous, but could become very annoying. $ touch "=F0=9F=98=B0 =F0=9F=98=B1 =F0=9F=98=B2 =F0=9F=98=B3 =F0=9F=98=B4 = =F0=9F=98=B5 =F0=9F=98=B6 =F0=9F=98=B7 =F0=9F=98=B8 =F0=9F=98=B9 =F0=9F=98= =BA =F0=9F=98=BB =F0=9F=98=BC =F0=9F=98=BD =F0=9F=98=BE " From owner-freebsd-questions@freebsd.org Fri Oct 16 04:32:30 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 908C144F59A for ; Fri, 16 Oct 2020 04:32:30 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCCtP61kSz4Qmw for ; Fri, 16 Oct 2020 04:32:29 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCCtJ21NGzDsmZ for ; Thu, 15 Oct 2020 21:32:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602822744; bh=AQvfGs0KerkrwJv4MsxVcFwHxlo9kHMskxJTabqwOMs=; h=Date:From:To:Subject:In-Reply-To:References:From; b=F2yq1136XjqmQK3brlnb3qa/WET0jYASXgiwpd2ESVw/EICWskmsiidSBFg1UQOY2 sc0BOt23CRtjhCcqPtYz9b0CI4LBz0Asd87gXa2SpAC7WDoFx0zX1VLasugt51bhnW SiEhhxPqvdFrOccHcMi8qSI6Vh2iSfZN/5Puh4f0= X-Riseup-User-ID: 0F2855BD2B6DF0353EC6927FC72356CB3177FDAEA78F52ECDCC6FBFD5EB0A705 Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CCCtH3yjhzJmkd for ; Thu, 15 Oct 2020 21:32:23 -0700 (PDT) Date: Fri, 16 Oct 2020 06:32:11 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016063211.2f8b3a74@archlinux> In-Reply-To: References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCCtP61kSz4Qmw X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=F2yq1136; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.59 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.98)[-0.981]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.99)[-0.989]; NEURAL_HAM_LONG(-1.02)[-1.020]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 04:32:30 -0000 On Thu, 15 Oct 2020 23:14:13 -0400, Kurt Hackenberg wrote: >On 2020-10-15 23:05, Bob Proulx wrote: > >> Oh you are tormenting us now. :-) There are some subtle issues >> here. > > >Maybe a shell is the wrong tool. Exactly! Scripts are useful to handle tasks, such as dealing with reasonable file names. A script should work around reasonable tricky file names, but at some point bothering with really freakish file names isn't worth the effort. Actually file names should be compatible with shell, if they are intended to be used with shell scripts. To some extent we could use shell scripts, to write little programs, that probably better should be written in a programming language. At some extent a programming language is required, a shell script can't do the job at all or at best it could do the job, but not with reasonable effort. From owner-freebsd-questions@freebsd.org Fri Oct 16 04:41:44 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 8AC4444F8B9 for ; Fri, 16 Oct 2020 04:41:44 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCD533yWgz4QtV for ; Fri, 16 Oct 2020 04:41:43 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCD4y14WszFf2t for ; Thu, 15 Oct 2020 21:41:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602823298; bh=kDD91sTcJ5E1YNFpLDnTwNJpZxV1MJGTgumrDKtONow=; h=Date:From:To:Subject:In-Reply-To:References:From; b=Iocliv8bi4S61fLx4ACpUiT/hQkFZGWZr8TBfSQuXaxOd7qz6UikgvSCn9rocttv1 0qADMNpBs+yeG9keF6CAc3zKcBzperon9ONrS2JL2CJLIUa4ZW4KNKHrEdkkjx2TdT +ejr304ROJPoBg10OPGsDBlr1+KW/6HMOuknlO7c= X-Riseup-User-ID: C51A8CC36B3F03960FAACD6B7AD5E04A6FC4CBEA6A58CC47EEEFD731B2A3DBC9 Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CCD4x3GSLzJmkd for ; Thu, 15 Oct 2020 21:41:33 -0700 (PDT) Date: Fri, 16 Oct 2020 06:41:07 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016064107.260811df@archlinux> In-Reply-To: <20201016063211.2f8b3a74@archlinux> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016063211.2f8b3a74@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCD533yWgz4QtV X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=Iocliv8b; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.44 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.96)[-0.957]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.86)[-0.864]; NEURAL_HAM_LONG(-1.02)[-1.018]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 04:41:44 -0000 $ touch " \" \" \" \";.txt \"" From owner-freebsd-questions@freebsd.org Fri Oct 16 04:58:40 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A728044FF04 for ; Fri, 16 Oct 2020 04:58:40 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCDSb6mdMz4RR6 for ; Fri, 16 Oct 2020 04:58:39 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCDSQ0ppVzFpT8 for ; Thu, 15 Oct 2020 21:58:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602824310; bh=f8gYhnFjQQ8tr9yJFbUd2grGrrMRnKy8G4fM83cipVw=; h=Date:From:To:Subject:In-Reply-To:References:From; b=OqCbz4ra5Klwo2N2x/5kiqFQ/ttew4j5trn5JkbQuMCU0UGGXCNMu4ItXhLDRahfr txBkOu592i57Z/cEd+JsVihrzWS1a3H2asYAPXhbqaiLs++oWzrF5dbObUANBBWHi4 KhkQGmW8qUsUYGqVvADYTk5zH9ahOjN+guo7HG8I= X-Riseup-User-ID: AD0FFA70D157860BDDF6975A527366C71895AC04A56C9AE1870B8DB04D458886 Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4CCDSP32Nfz8vXL for ; Thu, 15 Oct 2020 21:58:29 -0700 (PDT) Date: Fri, 16 Oct 2020 06:58:20 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016065820.7e143385@archlinux> In-Reply-To: <20201016061055.6b1354b5@archlinux> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016054735.33ad768e@archlinux> <20201016061055.6b1354b5@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCDSb6mdMz4RR6 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=OqCbz4ra; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.63 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.98)[-0.977]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-1.03)[-1.030]; NEURAL_HAM_LONG(-1.02)[-1.019]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 04:58:40 -0000 On Fri, 16 Oct 2020 06:10:55 +0200, Ralf Mardorf wrote: >even simple commands I take this claim back. Naming a file "rm", "ls" etc. is reasonable. My apologies for the traffic. From owner-freebsd-questions@freebsd.org Fri Oct 16 07:17:13 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BA9BA42A528 for ; Fri, 16 Oct 2020 07:17:13 +0000 (UTC) (envelope-from kuku@kukulies.org) Received: from mail.kukulies.org (mail.kukulies.org [116.203.115.43]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCHXS4dYZz4XYy for ; Fri, 16 Oct 2020 07:17:12 +0000 (UTC) (envelope-from kuku@kukulies.org) Received: from localhost (localhost [127.0.0.1]) by mail.kukulies.org (Postfix) with ESMTP id 6B4F610276A; Fri, 16 Oct 2020 09:17:11 +0200 (CEST) Received: from mail.kukulies.org ([127.0.0.1]) by localhost (mail.kukulies.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AS23mx_G-bUk; Fri, 16 Oct 2020 09:17:11 +0200 (CEST) Received: from christophs-mbp.fritz.box (p57a1f9fb.dip0.t-ipconnect.de [87.161.249.251]) by mail.kukulies.org (Postfix) with ESMTPSA id CB7BA102769; Fri, 16 Oct 2020 09:17:10 +0200 (CEST) From: Christoph Kukulies Message-Id: <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> Content-Type: multipart/signed; boundary="Apple-Mail=_A795626F-9DBF-44F9-B041-1615BAB3C5C0"; protocol="application/pkcs7-signature"; micalg=sha-256 Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.4\)) Subject: Re: Which ports to install to compile gnu binutils? Date: Fri, 16 Oct 2020 09:17:09 +0200 In-Reply-To: <20201015214755.GB26691@geeks.org> Cc: RW via freebsd-questions To: Doug McIntyre References: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> <20201015214755.GB26691@geeks.org> X-Mailer: Apple Mail (2.3608.120.23.2.4) X-Rspamd-Queue-Id: 4CCHXS4dYZz4XYy X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of kuku@kukulies.org has no SPF policy when checking 116.203.115.43) smtp.mailfrom=kuku@kukulies.org X-Spamd-Result: default: False [0.53 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; MV_CASE(0.50)[]; HAS_ATTACHMENT(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_DN_ALL(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:24940, ipnet:116.203.0.0/16, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[87.161.249.251:received]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.20)[-0.198]; FREEFALL_USER(0.00)[kuku]; FROM_HAS_DN(0.00)[]; SIGNED_SMIME(-2.00)[]; NEURAL_SPAM_SHORT(0.25)[0.249]; MIME_GOOD(-0.20)[multipart/signed,multipart/alternative,text/plain]; MIME_TRACE(0.00)[0:+,1:+,2:+,3:~,4:~]; DMARC_NA(0.00)[kukulies.org]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.07)[0.074]; R_SPF_NA(0.00)[no SPF record]; MAILMAN_DEST(0.00)[freebsd-questions] X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 07:17:13 -0000 --Apple-Mail=_A795626F-9DBF-44F9-B041-1615BAB3C5C0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Thanks. I gave up resp. I abandoned. It is too difficult (to me at = least) to figure out, how to configure binutils to build = gcc-arm-none-eabi-4_9-2015q1-20150306-src.tar.bz2 = (md5 = )=20 from it. =20 =E2=80=94 Christoph > Am 15.10.2020 um 23:47 schrieb Doug McIntyre : >=20 > On Thu, Oct 15, 2020 at 06:45:30PM +0200, Christoph Kukulies wrote: >> I=E2=80=99m in need to compile gnu-binutils (actually an older = vintage version) and I=E2=80=99m wondering what would be required to add >> in ports/packages? >>=20 >> FreeBSD-12.1 ist the system. >=20 > It is already there? >=20 > devel/binutils >=20 > https://www.freshports.org/devel/binutils/ >=20 >=20 >=20 > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to = "freebsd-questions-unsubscribe@freebsd.org" --Apple-Mail=_A795626F-9DBF-44F9-B041-1615BAB3C5C0 Content-Disposition: attachment; filename=smime.p7s Content-Type: application/pkcs7-signature; name=smime.p7s Content-Transfer-Encoding: base64 MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgEFADCABgkqhkiG9w0BBwEAAKCCCc0w ggSQMIIDeKADAgECAggYVYMhomAL1zANBgkqhkiG9w0BAQsFADBmMQswCQYDVQQGEwJERTEzMDEG A1UECgwqREdOIERldXRzY2hlcyBHZXN1bmRoZWl0c25ldHogU2VydmljZSBHbWJIMSIwIAYDVQQD DBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBFOlBOMB4XDTIwMDUxNjE1Mjc1OVoXDTIxMDUxNjE1Mjc1 OVowbzELMAkGA1UEBhMCREUxITAfBgNVBAUTGDQwMDAwMDAwNWVjMDA4ZGQzNzNhZDhlYzEbMBkG A1UEAwwSQ2hyaXN0b3BoIEt1a3VsaWVzMSAwHgYJKoZIhvcNAQkBFhFrdWt1QGt1a3VsaWVzLm9y ZzCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKug1655hQWRmOtGAShZLbMwDtrm7rAH 7p1oPtE/5KpTpJZe8LHPxxvW0EAd2JcLtEhdvAi7smhZ/giJ3IBK7OYmdaCvuQ6MFvJpkmLkQ9TO 4+RLW+PkBk8nFIUe+PQG+VurpWc8pbU4IRsWS3pEUgov9+LF6VtyYBHKD2HZwe46YBwUq7l0EHxc aa98ewCMO43XznlqjE+oKxwaS2nl1rL/SPVlfGmKqHkdSKEKl6yR1LCcI3J3HP56kqmIrvtySr7q UZVsibA+D6vArqklO99WKQmt0b4IX6TXouvAA6bNoF1FhYUyihm4omMWZkdTs7Gv5rr1fzPWXcev cMfJdtUCAwEAAaOCATcwggEzMB0GA1UdDgQWBBSQh9N17gCH/igJy5ftrVaJNm6SCTAMBgNVHRMB Af8EAjAAMB8GA1UdIwQYMBaAFOnGk9HVDwZkcupqlj66EPJUVLJ5MFYGA1UdIARPME0wSwYMKwYB BAH7KwIBAwIIMDswOQYIKwYBBQUHAgEWLWh0dHA6Ly9zZWM1LmRnbnNlcnZpY2UuZGUvcG9saWNp ZXMvaW5kZXguaHRtbDA+BgNVHR8ENzA1MDOgMaAvhi1odHRwOi8vc2VjNS5kZ25zZXJ2aWNlLmRl L2NybC9jcmwyLXR5cGUtZS5jcmwwDgYDVR0PAQH/BAQDAgSwMB0GA1UdJQQWMBQGCCsGAQUFBwMC BggrBgEFBQcDBDAcBgNVHREEFTATgRFrdWt1QGt1a3VsaWVzLm9yZzANBgkqhkiG9w0BAQsFAAOC AQEALUBRNzLAUiPi29LLATqWmrUlyacMVAtjdROQMd/AVPj0mUqTMoDO+YoWICOSEn/nEyb2Lrrz JNGqC6KO0CNROaWcEhFadKx4qtp9t26Qe/EkO0XbXexIfBxFl1ynQA54D0qtPb/SUZvTy0tq8oBt FdsIU+cXAzigEz2Z9nziHBMqThoKzAZSrk/sPvxT6MNMC/BMGlHGl0DV//wwI5vlzJiKS8iXFyxf 5VrN1IwgRyqXD8JsgF1BuEqcloSJ3JnWUGQCTURFasZDJlP0f/KJS8odUpEWDKnn6tt0RjBk0jUN i7z42ozzPn/o154AgXC2cNmROxC0gnvd+V/yIuAryDCCBTUwggQdoAMCAQICCFUcStdmrSX2MA0G CSqGSIb3DQEBCwUAMGExCzAJBgNVBAYTAkRFMTMwMQYDVQQKDCpER04gRGV1dHNjaGVzIEdlc3Vu ZGhlaXRzbmV0eiBTZXJ2aWNlIEdtYkgxHTAbBgNVBAMMFGRnbnNlcnZpY2UgUm9vdCA3OlBOMB4X DTE2MTAyNjA5MjI0MVoXDTI0MTAyNjA5MjI0MVowZjELMAkGA1UEBhMCREUxMzAxBgNVBAoMKkRH TiBEZXV0c2NoZXMgR2VzdW5kaGVpdHNuZXR6IFNlcnZpY2UgR21iSDEiMCAGA1UEAwwZZGduc2Vy dmljZSBDQSAyIFR5cGUgRTpQTjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBANyl8pQ/ dMejR9KXZs5ro81tFwNhloThlXe8sat79Tjjk6xFqE5E94//0vifJxMrp9RrCkNOo5oPG1djGOgk 0L0ucpHFUH9SQF/SHbm83QvWJXgqEJpjxOKZXTPbJRKVvY25niB0FTr2omRqypiP4A/w5xA6jSJ2 P02vV6WgcPfaLQkM+SEGPxV/pzpvuY3KfzJ9li9mXPNXaJD9y+jqIUvHbCAbuYKQ5nwEAcYMXDpP RQgDQGTrRiFExHEjsZeMzEFADZj9deg/h29AMO0w2YrSvkNReh/zvDZutdy25DZvjE3AUgStWgBC 7x+2ddOb2I61o6xbIsxlfq/mzNpAGoECAwEAAaOCAeowggHmMBIGA1UdEwEB/wQIMAYBAf8CAQAw HwYDVR0jBBgwFoAUAQwWG3Ry0zwU7iZ3t0kUU9j7ixswWwYIKwYBBQUHAQEETzBNMEsGCCsGAQUF BzABhj9odHRwOi8vcm9jc3AtZGduLmRnbnNlcnZpY2UuZGU6ODA4MC9lamJjYS9wdWJsaWN3ZWIv c3RhdHVzL29jc3AwagYDVR0gBGMwYTBfBgwrBgEEAfsrAgEEAgEwTzBNBggrBgEFBQcCARZBaHR0 cDovL3d3dy5kZ25zZXJ2aWNlLmRlL3RydXN0Y2VudGVyL3B1YmxpYy9kZ25zZXJ2aWNlL2luZGV4 Lmh0bWwwgZkGA1UdHwSBkTCBjjCBi6CBiKCBhYaBgmxkYXA6Ly9sZGFwLmRnbnNlcnZpY2UuZGU6 Mzg5L0NOPUNSTC0xLE89REdOJTIwU2VydmljZSUyMEdtYkgsQz1ERT9jZXJ0aWZpY2F0ZVJldm9j YXRpb25MaXN0P2Jhc2U/b2JqZWN0Q2xhc3M9Y1JMRGlzdHJpYnV0aW9uUG9pbnQwHQYDVR0OBBYE FOnGk9HVDwZkcupqlj66EPJUVLJ5MA4GA1UdDwEB/wQEAwIBBjAbBgkrBgEEAcBtAwUEDjAMBgor BgEEAcBtAwUBMA0GCSqGSIb3DQEBCwUAA4IBAQCrvDn6Rcn7/FNq3SOJNfgYNfkdR5CiGoC4sZ+i 0dypCqqMXwbpRQjSriLS2eEe2V2Fms0E4SuBOEaxOg1nVjYafQVGtytRT0ueFIzB3VcnQl7oRFJ0 SHi9d/xjElAZkk8I8lytuWG57SabA72duEp7AaCWG3lVZIdNLy+rkNrfNvEUbqUh0TrZXgqpwwCL JjYF8vyC4I+xxNaXm3EmuNvgQ2j2dGp3Oxc0QbfLLOCbK/rOdDikaBN7kTqpfHls7pcIOhQrgrPV LzY/NHqG9zEpmjuQora63YHdu7BTzGp/DvcQwfyKa/gtb9LHn3AoSUqOKOMd02sUb/AxGhsNjMzJ MYIDFDCCAxACAQEwcjBmMQswCQYDVQQGEwJERTEzMDEGA1UECgwqREdOIERldXRzY2hlcyBHZXN1 bmRoZWl0c25ldHogU2VydmljZSBHbWJIMSIwIAYDVQQDDBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBF OlBOAggYVYMhomAL1zANBglghkgBZQMEAgEFAKCCAXMwGAYJKoZIhvcNAQkDMQsGCSqGSIb3DQEH ATAcBgkqhkiG9w0BCQUxDxcNMjAxMDE2MDcxNzA5WjAvBgkqhkiG9w0BCQQxIgQgCpUjRmSEMbtF YFyejCRbFrmM7fHlWxzBb1Q9Fhhd6HcwgYEGCSsGAQQBgjcQBDF0MHIwZjELMAkGA1UEBhMCREUx MzAxBgNVBAoMKkRHTiBEZXV0c2NoZXMgR2VzdW5kaGVpdHNuZXR6IFNlcnZpY2UgR21iSDEiMCAG A1UEAwwZZGduc2VydmljZSBDQSAyIFR5cGUgRTpQTgIIGFWDIaJgC9cwgYMGCyqGSIb3DQEJEAIL MXSgcjBmMQswCQYDVQQGEwJERTEzMDEGA1UECgwqREdOIERldXRzY2hlcyBHZXN1bmRoZWl0c25l dHogU2VydmljZSBHbWJIMSIwIAYDVQQDDBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBFOlBOAggYVYMh omAL1zANBgkqhkiG9w0BAQEFAASCAQBgxzkKN1ObH4Vw/1na8VvYe7MRaBHJ/vm+EuSyXPtPlPbp zOOELKEshREMsTbP6vg8y7uNraUrnc6WpGn8Lf22t3D1XLL6D5NIxTr/L8VF+dB48IGWndt4KwO6 fS12TXa8hn5YTkr6j69cTHtNSfDzWMNOIK5/jcJSZThyM967d2V8ESC7iz73WBloPVwxudnK7gqZ 8+TehDdoSUJ8QjaY8Amjlz/59TkWzhaG+r56nvbSCzsi3xkMen6O8ViE4l+26TT597SBeqhcGggx bIL7d3IkwjNwIKq+RxZp5gbnCzMEFNAUXNZ0oNmUhUF4hP6mwEm2/fghgmdRi/wzUUv9AAAAAAAA --Apple-Mail=_A795626F-9DBF-44F9-B041-1615BAB3C5C0-- From owner-freebsd-questions@freebsd.org Fri Oct 16 08:28:03 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A06A642C03F for ; Fri, 16 Oct 2020 08:28:03 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from EUR06-VI1-obe.outbound.protection.outlook.com (mail-vi1eur06olkn20807.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe11::807]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "GlobalSign Organization Validation CA - SHA256 - G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCK6B3rn8z4bmk for ; Fri, 16 Oct 2020 08:28:02 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=H+jIr5pYSb4rtQ+vZ+yN5eIBIskqajaMeSTqU9iskSSIcMF+bTHkoeDOH8RBWiqKbT4JTfhKJy2+l96siR2M82hxHG3fHfCaXBKV9euxFQ+QMy52BlTyJ4HjiEdpu+mFL+YwOkbrZM9f+4joTcl4NzmSujd8u+pPLuLW+Lzk5T0C+iqzTE2mpEcyfSxjrPnEiahYxCc+j7iJL4MMpqbm6GHvwOMgbQm+J5DcBE7bhZ0QjDfwWrlgaWHVKTFx5jvOD/VX43VX/ItcHK5WGB4as1/KCtcYzE5K7gON9drSz71zf2AZDdXAMkcJsqTH4FJt5vQQsXj4vALFuo4l0o8Cmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=mDUiy2ufcaRiG2rHWe+RMsd0zPuPyk7oPhqpbp2ipVY=; b=ePPSsN+8o6oMkiWfGd65NVlfaJ/EukZEsyX3r8X2/R6q4KkLPdx+3djzABzqiy+dLmJlC6IHAorsiY/B31DDEPA/oBHGLxIrVdr8avBir6rZfRCpz7n7TRIklvLG0XxLmSfsyDo0I2bg2LNDUzy5eyCmfSZg2iAzCAGGzXMU4GpFH97ewGYJhKS7WdBSB2HDG3ej8YOl82Tpo3iP3t0wbJQggo/IbRd5Z4Qxb1syotXJR15i6TeyL7x3beqtVVL8pqo722QliJ8vGZWU0W0oR2db4wo5OtAP1ngdhcDetxxF6VAKVedqmfZrUALlvbkKCQo9qOEpd11/Yn96QXL/nA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=mDUiy2ufcaRiG2rHWe+RMsd0zPuPyk7oPhqpbp2ipVY=; b=bPxHdQQXN1dMRUKZ24ILcWOhnclFj8SMivi87v45wpeLVjVsuW6fIwW0Uyl1V1ZLJY61u4medb5pTwkyFh5gw5Og9O6b0IYq6beXvFqlmBEKY/Ns1Maj+f+RP2GqEuPPhtBSD9e/zES2dbO4R0QjWM/8FELxkvY8YydMOdYB19Iiz713b5rMuu3Ne4/KNbVaOd3UaYelpNA3k4WWVXnAXQBRpOKRZX+GORtJB0Nw/Gycjn/JZOWwlIlerOIjC/jS33giA8aC2jYYy0JllV0ss9fz2TCo6guoPehH8WHMw8ZiR/Zx5a4g0tnPx1d2GlMgUK0Tk3YgfDtN8aFq4EIuCA== Received: from DB8EUR06FT038.eop-eur06.prod.protection.outlook.com (2a01:111:e400:fc35::44) by DB8EUR06HT101.eop-eur06.prod.protection.outlook.com (2a01:111:e400:fc35::440) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21; Fri, 16 Oct 2020 08:12:24 +0000 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com (2a01:111:e400:fc35::4a) by DB8EUR06FT038.mail.protection.outlook.com (2a01:111:e400:fc35::314) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 08:12:24 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:5D245642B4EBCA0F1E334C6006C89D052AFCF07F51846D053962B3019ED9FF5F; UpperCasedChecksum:39F60925748AE61440E37E522BA956A381C5AF413C9EEEBB909B448CC839A874; SizeAsReceived:8693; Count:48 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f]) by DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f%9]) with mapi id 15.20.3477.023; Fri, 16 Oct 2020 08:12:24 +0000 Subject: Fwd: Re: sh scripting question References: To: FreeBSD From: Manish Jain X-Forwarded-Message-Id: Message-ID: Date: Fri, 16 Oct 2020 13:42:17 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-TMN: [yWHUYsWUg0xUQhn9MNvxqMgSm7EKtfgXtjN1VsPbCDs=] X-ClientProxiedBy: BM1PR01CA0111.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00::27) To DB8PR06MB6442.eurprd06.prod.outlook.com (2603:10a6:10:126::7) X-Microsoft-Original-Message-ID: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.2] (103.195.202.206) by BM1PR01CA0111.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 08:12:23 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 48 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: 691b42f8-93a1-464e-465e-08d871ab369d X-MS-TrafficTypeDiagnostic: DB8EUR06HT101: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 3HQ9Ucctqb3ZgJZCmIEEAGlJegXZADqVJNMTNjrPFmGB/3WgF6bryIW0o2F1yIaGTDUoHUucTnO8cM+KU8i+di8YXKqZyDpvzW8NkBnX9gZcs+GwDynWOS3LsQKAzAMPzM+s3EsSlJJfUE0yB8lO2ZYlumevl5cp3Giow8geIn1NTQSa0W0RpQfrQdmLW/3/Jl9SeSAKOaKMZhT45DP/ow== X-MS-Exchange-AntiSpam-MessageData: 29MJtYh3xYSR3ik06jZ6ix6/sQjIix1yjSeIY7z+80+/TrBSLdzf1YFOTUlCfklw+QljyflCdnNXdvTsR83MmvcilC2qv3IWGoI/uoaGJ1T3mdkcyAYtqWwkMpO15x+JxL7P66Nhjy1W7eJGvuCRhA== X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-Network-Message-Id: 691b42f8-93a1-464e-465e-08d871ab369d X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 08:12:24.4937 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: DB8EUR06FT038.eop-eur06.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8EUR06HT101 X-Rspamd-Queue-Id: 4CCK6B3rn8z4bmk X-Spamd-Bar: +++++++++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=bPxHdQQX; dmarc=pass (policy=none) header.from=hotmail.com; spf=pass (mx1.freebsd.org: domain of bourne.identity@hotmail.com designates 2a01:111:f400:fe11::807 as permitted sender) smtp.mailfrom=bourne.identity@hotmail.com X-Spamd-Result: default: False [9.58 / 15.00]; FREEMAIL_FROM(0.00)[hotmail.com]; R_SPF_ALLOW(0.00)[+ip6:2a01:111:f400::/48]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[hotmail.com:+]; DMARC_POLICY_ALLOW(0.00)[hotmail.com,none]; RECEIVED_SPAMHAUS_PBL(0.00)[103.195.202.206:received]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; ASN(0.00)[asn:8075, ipnet:2a01:111:f000::/36, country:US]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; ARC_ALLOW(0.00)[microsoft.com:s=arcselector9901:i=1]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; RECEIVED_SPAMHAUS_XBL(5.00)[103.195.202.206:received]; R_DKIM_ALLOW(0.00)[hotmail.com:s=selector1]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(0.10)[0.101]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_MEDIUM(0.98)[0.978]; RCPT_COUNT_ONE(0.00)[1]; BAD_REP_POLICIES(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; NEURAL_SPAM_LONG(1.00)[1.004]; GREYLIST(0.00)[pass,body]; MAILMAN_DEST(0.00)[freebsd-questions] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 08:28:03 -0000 -------- Forwarded Message -------- Subject: Re: sh scripting question Date: Fri, 16 Oct 2020 13:39:06 +0530 From: Manish Jain To: Ralf Mardorf On 2020-10-16 10:02, Ralf Mardorf wrote: > On Thu, 15 Oct 2020 23:14:13 -0400, Kurt Hackenberg wrote: >> On 2020-10-15 23:05, Bob Proulx wrote: >> >>> Oh you are tormenting us now. :-) There are some subtle issues >>> here. >> >> >> Maybe a shell is the wrong tool. > > Exactly! Scripts are useful to handle tasks, such as dealing with > reasonable file names. A script should work around reasonable tricky > file names, but at some point bothering with really freakish file names > isn't worth the effort. Actually file names should be compatible with > shell, if they are intended to be used with shell scripts. To some > extent we could use shell scripts, to write little programs, that > probably better should be written in a programming language. At some > extent a programming language is required, a shell script can't do the > job at all or at best it could do the job, but not with reasonable > effort. I would strongly disagree with that. If a problem can be solved with a shell script - and Robert Huff's problem is easily solvable with a simple Bourne shell script, then a shell script must be what is used to solve the problem. Robert, I gave you the solution. Do you have a problem with that solution ? Regards, Manish Jain From owner-freebsd-questions@freebsd.org Fri Oct 16 09:34:27 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 45A8442D64D for ; Fri, 16 Oct 2020 09:34:27 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCLZp3s0dz4g25 for ; Fri, 16 Oct 2020 09:34:26 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from bell.riseup.net (bell-pn.riseup.net [10.0.1.178]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCLZc4H28zFf0c for ; Fri, 16 Oct 2020 02:34:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602840856; bh=ksEai3rENG2V27Oe3sEW0OsYooa95y5g6SVzxPfPowQ=; h=Date:From:To:Subject:In-Reply-To:References:From; b=tTTLkCwUSYDYnDV1Fi4LwiCjUNVwKJyxRTI1dlgf1/7ffYbGf9GhLuyeJLJ8OTzma ut5jtIQ6mSMPPrbCNryenjmShkWlADR5/ThGvMiTXmvvlh08rJnMFi0Zg52ZcVPbZK KrFMvSb7cbrpVA/e0OmWG8SqSWx0UtuNs1ey+kXs= X-Riseup-User-ID: AFB3CDDE6891E26E2C0FCE22D6DC8B43E48E1C4AE95D52815CF200AB4A219F5F Received: from [127.0.0.1] (localhost [127.0.0.1]) by bell.riseup.net (Postfix) with ESMTPSA id 4CCLZc0rFbzJqY2 for ; Fri, 16 Oct 2020 02:34:15 -0700 (PDT) Date: Fri, 16 Oct 2020 11:34:08 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016113408.16d58d68@archlinux> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCLZp3s0dz4g25 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=tTTLkCwU; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.19 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.99)[-0.990]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.58)[-0.578]; NEURAL_HAM_LONG(-1.02)[-1.022]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 09:34:27 -0000 On Fri, 16 Oct 2020 13:42:17 +0530, Manish Jain wrote: >-------- Forwarded Message -------- >Subject: Re: sh scripting question >Date: Fri, 16 Oct 2020 13:39:06 +0530 >From: Manish Jain >To: Ralf Mardorf > >On 2020-10-16 10:02, Ralf Mardorf wrote: >> On Thu, 15 Oct 2020 23:14:13 -0400, Kurt Hackenberg wrote: >>> On 2020-10-15 23:05, Bob Proulx wrote: >>> >>>> Oh you are tormenting us now. :-) There are some subtle issues >>>> here. >>> >>> >>> Maybe a shell is the wrong tool. >> >> Exactly! Scripts are useful to handle tasks, such as dealing with >> reasonable file names. A script should work around reasonable tricky >> file names, but at some point bothering with really freakish file >> names isn't worth the effort. Actually file names should be >> compatible with shell, if they are intended to be used with shell >> scripts. To some extent we could use shell scripts, to write little >> programs, that probably better should be written in a programming >> language. At some extent a programming language is required, a shell >> script can't do the job at all or at best it could do the job, but >> not with reasonable effort. > > >I would strongly disagree with that. If a problem can be solved with a >shell script - and Robert Huff's problem is easily solvable with a >simple Bourne shell script, then a shell script must be what is used >to solve the problem. We do not disagree here. The OP's "problem" isn't a big problem for a shell script, assuming we are talking about file names such as foo bar 10-inch.txt and not foo "bar" \ 10".txt Names read from a file containing a list of file names is one thing. The next step is how the script should proceed using the file names. Handling even the most freakish string is doable, but depending on what should be done next with this string, it's not necessarily pleasant, especially not when the content of the string conflicts with shell conventions. Imagine a file named - or -h or --help etc., then add the file name behind a command. Yes, you could use a workaround, such as adding a path. [rocketmouse@archlinux tmp]$ cat --help | head -1 Usage: cat [OPTION]... [FILE]... [rocketmouse@archlinux tmp]$ cat ./--help | head -1 test However, you easily could end up with a script containing more lines that workaround offended conventions, than containing lines for what actually should be done. From owner-freebsd-questions@freebsd.org Fri Oct 16 10:26:13 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BD2B042FBCE for ; Fri, 16 Oct 2020 10:26:13 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070024.outbound.protection.outlook.com [40.92.70.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "GlobalSign Organization Validation CA - SHA256 - G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCMkX43Pvz4kBG for ; Fri, 16 Oct 2020 10:26:12 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HqLKypBoea8ckA5DD6jVvxxcrb4jWpf1hCeQileVRKPjf6339bC5SAywEGJBO1cORhkGVcqiGcBb+E47CuvmbkeneZnKVjV5zVLpGCnlQLvRjItAIsvXwP59tDndXcQdlBzUVouGTH16MeW9aKIti9QDxup8TTpMgcq2DXTP+DVX9hVHDXJjzn8WgkOXYMwBadxoD0JFCTYWAK1YoKsIBe6iEAd7eXIaZjo7cIdmbWawjTI+/f7QpOYR3XPbXMAuaQvqpq3IKs0rAi9JZ7IbpzmbfroLKc8oOC0IYNV++ZHT/KTP7H7OtUG/Z/nsvkcbcttzdzD+rnoKLUb+vzF2Xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=C0ZsKaM/Tfjr1uiMkD/OqF4OW4dSCOrsZN2EnAwtFQY=; b=m1GLk+8XcUijCBGkZEuDXY/E+5TaAiihRPezeJlDvNbrDTtKhFKhiz67PGwg3+Pc9A+yDzv1TiNQ+BhPk3uvQg6KrMDIapTPB3nr9ppzN0e+vlEfOvht1Za9/rWmBNU1jiibnT5gcHGXQBgKHH10MgY5fxKRhst0nxaOPDcCUhuBa9loEImHCjDWA46gAU0c0VANL8EwzlywKo2xjBRkoLV0pnyrEFSdpwPTAMJ3kmEnwawtait6v8jQbsY9SusaXET7ZOupX8mv7GL7HLS98Y/+wRS6JZEmuMVqgMfX319nWS072psNXeXDUdZuM6fxWJFkBbx2dxMLDA5Ud5qAnQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=C0ZsKaM/Tfjr1uiMkD/OqF4OW4dSCOrsZN2EnAwtFQY=; b=HfHB7dbOpwxRtFYXy42l9XHe7EJBQhNdeMhXUUyw3dB/C26pQWjZ3bwx7X4UeVPfxyYm//2zCe+Xf709wYjFgJWB4piJDany6CkQnGF0SunPxtaii4fhVfuo06AqB5hoJUIC5MRI9D3EL7gEx60bhKnv99XH8vJC0gSJb7IYYu3xBlbsVh+O8wGJeCrrsVE5ex7bI/jGNofgWrN/W0umzQEHjHFEt2EZkvpbiIHkWjoyWoWDQbCyQb/RhhyAWLCExJjqygx1r6mjbKCbpB5b02uF61rnvkNFGHIVeabcXvG321He+S4ss6knkAjWWp2EE639DdCGcaQH86VUPl24MA== Received: from VE1EUR03FT050.eop-EUR03.prod.protection.outlook.com (2a01:111:e400:7e09::43) by VE1EUR03HT230.eop-EUR03.prod.protection.outlook.com (2a01:111:e400:7e09::199) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3455.23; Fri, 16 Oct 2020 10:26:08 +0000 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com (2a01:111:e400:7e09::4a) by VE1EUR03FT050.mail.protection.outlook.com (2a01:111:e400:7e09::465) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 10:26:08 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:6400E228B156600F70AFF969844B3B798CE84AABF3F6C068AAEB984A8F56B95F; UpperCasedChecksum:BC058B2AAA6A65622762F5F008F0903D1A7AC41BCD8E8E467359317BCA3F137F; SizeAsReceived:8760; Count:47 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f]) by DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f%9]) with mapi id 15.20.3477.023; Fri, 16 Oct 2020 10:26:07 +0000 Subject: Re: sh scripting question To: Ralf Mardorf , freebsd-questions@freebsd.org References: <20201016113408.16d58d68@archlinux> From: Manish Jain Message-ID: Date: Fri, 16 Oct 2020 15:55:59 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 In-Reply-To: <20201016113408.16d58d68@archlinux> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-TMN: [vJNHefwZ52/QSAo9he8QHqb+JRKLFDLHcEwzuQl/+O8=] X-ClientProxiedBy: BMXPR01CA0043.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:c::29) To DB8PR06MB6442.eurprd06.prod.outlook.com (2603:10a6:10:126::7) X-Microsoft-Original-Message-ID: <7517304b-b418-4cef-0b4f-ba0c80a854f8@hotmail.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.2] (103.195.202.206) by BMXPR01CA0043.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:c::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 10:26:06 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: dac8d98c-7a97-4c2c-0733-08d871bde472 X-MS-TrafficTypeDiagnostic: VE1EUR03HT230: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: fo+zAR8rCP7YSuxHFj1DGA/vUoVo7kRS+SPWgyaLbemZ0SmG/yqqXaT5S/UZGSeCdnsAgyRusPeAaPBOGkeuRYggHUng56iPXq3Ib5AHMfwmNqLRsbslwcokEp93g35OyfnCJG2W02lzODtiYHNpCrWmgJq7Uh5YtmDp+YST5ptN6IZGsxaV3o7drNITIxmYoGJE77IAeLd3Q+z4B5iknA== X-MS-Exchange-AntiSpam-MessageData: OGfP9IBsLr0Q67atWAcZ0+x7Gu9RHRaOtGa0aJIukWjUcfV58AXXzAqAxtVMkfsyE3rKEDcuAUgx4wnixmOQAu+Fzh944XIlTFhQn/hK3p8ep6A4sDSgZNFTwF0YQdTOCXl/YctKPSWXs6hiuaOIkA== X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-Network-Message-Id: dac8d98c-7a97-4c2c-0733-08d871bde472 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 10:26:07.0730 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: VE1EUR03FT050.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1EUR03HT230 X-Rspamd-Queue-Id: 4CCMkX43Pvz4kBG X-Spamd-Bar: +++++++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=HfHB7dbO; dmarc=pass (policy=none) header.from=hotmail.com; spf=pass (mx1.freebsd.org: domain of bourne.identity@hotmail.com designates 40.92.70.24 as permitted sender) smtp.mailfrom=bourne.identity@hotmail.com X-Spamd-Result: default: False [7.51 / 15.00]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(0.00)[+ip4:40.92.0.0/15:c]; FREEMAIL_FROM(0.00)[hotmail.com]; DKIM_TRACE(0.00)[hotmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(0.00)[hotmail.com,none]; NEURAL_HAM_SHORT(-0.00)[-0.003]; RECEIVED_SPAMHAUS_PBL(0.00)[103.195.202.206:received]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; ARC_ALLOW(0.00)[microsoft.com:s=arcselector9901:i=1]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; ASN(0.00)[asn:8075, ipnet:40.80.0.0/12, country:US]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; RECEIVED_SPAMHAUS_XBL(5.00)[103.195.202.206:received]; R_DKIM_ALLOW(0.00)[hotmail.com:s=selector1]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_MEDIUM(-0.34)[-0.335]; MIME_GOOD(-0.10)[text/plain]; BAD_REP_POLICIES(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(0.35)[0.351]; RCVD_IN_DNSWL_NONE(0.00)[40.92.70.24:from]; RWL_MAILSPIKE_POSSIBLE(0.00)[40.92.70.24:from]; GREYLIST(0.00)[pass,meta]; MAILMAN_DEST(0.00)[freebsd-questions] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 10:26:13 -0000 On 2020-10-16 15:04, Ralf Mardorf wrote: > On Fri, 16 Oct 2020 13:42:17 +0530, Manish Jain wrote: >> -------- Forwarded Message -------- >> Subject: Re: sh scripting question >> Date: Fri, 16 Oct 2020 13:39:06 +0530 >> From: Manish Jain >> To: Ralf Mardorf >> >> On 2020-10-16 10:02, Ralf Mardorf wrote: >>> On Thu, 15 Oct 2020 23:14:13 -0400, Kurt Hackenberg wrote: >>>> On 2020-10-15 23:05, Bob Proulx wrote: >>>> >>>>> Oh you are tormenting us now. :-) There are some subtle issues >>>>> here. >>>> >>>> >>>> Maybe a shell is the wrong tool. >>> >>> Exactly! Scripts are useful to handle tasks, such as dealing with >>> reasonable file names. A script should work around reasonable tricky >>> file names, but at some point bothering with really freakish file >>> names isn't worth the effort. Actually file names should be >>> compatible with shell, if they are intended to be used with shell >>> scripts. To some extent we could use shell scripts, to write little >>> programs, that probably better should be written in a programming >>> language. At some extent a programming language is required, a shell >>> script can't do the job at all or at best it could do the job, but >>> not with reasonable effort. >> >> >> I would strongly disagree with that. If a problem can be solved with a >> shell script - and Robert Huff's problem is easily solvable with a >> simple Bourne shell script, then a shell script must be what is used >> to solve the problem. > > We do not disagree here. The OP's "problem" isn't a big problem for a > shell script, assuming we are talking about file names such as > > foo bar 10-inch.txt > > and not > > foo "bar" \ 10".txt > > Names read from a file containing a list of file names is one thing. The > next step is how the script should proceed using the file names. > Handling even the most freakish string is doable, but depending on > what should be done next with this string, it's not necessarily > pleasant, especially not when the content of the string conflicts with > shell conventions. > > Imagine a file named > > - > > or > > -h > > or > > --help > > etc., then add the file name behind a command. > > Yes, you could use a workaround, such as adding a path. > > [rocketmouse@archlinux tmp]$ cat --help | head -1 > Usage: cat [OPTION]... [FILE]... > [rocketmouse@archlinux tmp]$ cat ./--help | head -1 > test > > However, you easily could end up with a script containing more lines > that workaround offended conventions, than containing lines for what > actually should be done. Hi Ralf, This is where I actually have an entirely different philosophy. When you create a file with a leading - (or for that matter, weird characters such as * anywhere in the filename), I think the filesystem driver (i.e. the kernel) should throw a warning: "Do you really want a filename like that ?" Actually, I would go one step ahead and have kernel drivers and users agree on a Unix Portable File Naming Convention, which should debar rotten file names in the first place to everyone except the root user (and even he should get a warning on violations). A few examples of what the Convention should debar: - in the leading position . in the trailing position * anywhere in the filename | anywhere in the filename I could think of a few more, but I think you get the idea. Anyway, Robert's problem I do not think relates to weird filenames as far as I can see. Regards, Manish Jain From owner-freebsd-questions@freebsd.org Fri Oct 16 10:44:26 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 5335542FFCA for ; Fri, 16 Oct 2020 10:44:26 +0000 (UTC) (envelope-from tomek@cedro.info) Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCN7Y2qRfz4kkL for ; Fri, 16 Oct 2020 10:44:25 +0000 (UTC) (envelope-from tomek@cedro.info) Received: by mail-wm1-x341.google.com with SMTP id d81so1930084wmc.1 for ; Fri, 16 Oct 2020 03:44:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cedro.info; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=XI17XPS+bzrwLmV7CKX0UmAaZAInOx1gnr+OW37flsE=; b=eWhD6ft9U8n4KaGAU0lpWcgWuh5StC3DhaReqKjRAIkNyHGYLgepbJLMMXx9aVhwF9 nz0+EBHF/qAKnmcxDkpxKRdn7Ni6cMR7N6lYvZUkfPb595g6jHLDp2YcEDiKslsHU89x Q0A7EqEER9R2GN/KsBna5dRLmAn09yH8wwf/esMKjwWX3mav8VvXGbuv84m1yMHSavwM bwEmKKH5apqqedlNsY6hT9gpEosUuClbGQ65gXHzPRf0aZub8Ktmq1RgUiNJ68bBKL5s da37nsvq+jWM8OYCkKvBrpEKXDX+5mC4+2c6VAeLR0fDsJHzKp4RKkgM0iV+vlqHxzKK wpmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=XI17XPS+bzrwLmV7CKX0UmAaZAInOx1gnr+OW37flsE=; b=B2twP392hEO5gmAo7mijsE2DkCvicPB96gzw2LHSf0cJTZAe/G7fVnADhgVI+GZ5go ke+1XqvblKB9ckOtGF1xRAYI/T1yqVaiktwLJ7b66ZNLKYhPJkUpberH6MGtjVt5vwuR Zyj/ThQSIuIcAxL5uV/8/Ds/U1wy+FHifmpZhSYu0zt7CMOsC5Jvhdnnm9vQnDYgRLNW 6OFgNbKFEuy1PNQrYZ+4BYtxcoNSNJRbxR47OPoZmgKGgUfsGDhvET7L+uzXEmSv09+V pEQvXyLoSlRCF6B1MKrGcirnQCSWIVLnqzGW6N9Yxl3opU+/Bn6fa85VmEXeg7kOytVh vlAQ== X-Gm-Message-State: AOAM532VlpQvXMvhqT5Mim5GY9UHUM5Z7aJXBPhYkhDyIjF7R/izOv3F xkUnX+yMZhEuZWt5FOBsKAv697f5B5n+U2eVLwQO9bZr8h4= X-Google-Smtp-Source: ABdhPJytTGYaVnbsugFQYLPLSP3y6C9DfhJQfzqVH6Bc+RhTEw7BVYvZDenqpvrrKff+IQEeoH/SjKySIvnhzTZrdO4= X-Received: by 2002:a1c:6302:: with SMTP id x2mr3354468wmb.121.1602845063752; Fri, 16 Oct 2020 03:44:23 -0700 (PDT) MIME-Version: 1.0 References: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> <20201015214755.GB26691@geeks.org> <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> In-Reply-To: <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> From: Tomasz CEDRO Date: Fri, 16 Oct 2020 12:44:12 +0200 Message-ID: Subject: Re: Which ports to install to compile gnu binutils? To: Christoph Kukulies Cc: Doug McIntyre , RW via freebsd-questions X-Rspamd-Queue-Id: 4CCN7Y2qRfz4kkL X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=cedro.info header.s=google header.b=eWhD6ft9; dmarc=none; spf=none (mx1.freebsd.org: domain of tomek@cedro.info has no SPF policy when checking 2a00:1450:4864:20::341) smtp.mailfrom=tomek@cedro.info X-Spamd-Result: default: False [-1.11 / 15.00]; RCVD_TLS_ALL(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[cedro.info:s=google]; NEURAL_HAM_MEDIUM(-0.93)[-0.928]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.10)[0.097]; NEURAL_HAM_LONG(-0.98)[-0.984]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[cedro.info]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[cedro.info:+]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::341:from]; R_SPF_NA(0.00)[no SPF record]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; SUBJECT_ENDS_QUESTION(1.00)[]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 10:44:26 -0000 another way is to use old os and distribution that has it in the binary packages and run it in the vm just for that particular case you need :-) there may be a linux image within a docker for rapid deployment with that tools that you need people are using this method for CI and builds on a strange / old configurations with one click. if you want to use it on FreeBSD then you may want to create a dedicated port to make compile easy and maybe even provide a binary package of the outdated software. sometimes its the only way and it (usually) works :-) -- CeDeROM, SQ7MHZ, http://www.tomek.cedro.info From owner-freebsd-questions@freebsd.org Fri Oct 16 11:23:17 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 46C2443125D for ; Fri, 16 Oct 2020 11:23:17 +0000 (UTC) (envelope-from 4250.82.1d4c50003b75108.e1f580c0d04e130d8955c6864cf60214@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCP0N1pyHz4nxG for ; Fri, 16 Oct 2020 11:23:16 +0000 (UTC) (envelope-from 4250.82.1d4c50003b75108.e1f580c0d04e130d8955c6864cf60214@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602847394; x=1605439394; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:to:from:date:x-thread-info; bh=8TStZngyxA9a3x2RWhSD54a8h+GaNSfbt5Nfoaj+tC4=; b=uJ6rFR0fk3kFHf+S4S7D8sYDr8qD2pCU77yEPcW8IYF9gCI1XdqLb0jZK/ZVr173vyn0DBj8xlYKOWPe2y1z6Ba5JvMrLp3YNg/SpeTGVs7RgyeSOlOl2XlO5uveipyq1IfCFv640yLPxST72aQxMFLwIvRUEa4SABZ8xp8yyNo= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNiNzUxMDguZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r3.us-east-2.aws.in.socketlabs.com (r3.us-east-2.aws.in.socketlabs.com [142.0.189.3]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 07:23:11 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r3.us-east-2.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 07:23:08 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTNpH-000Hc9-FT for freebsd-questions@freebsd.org; Fri, 16 Oct 2020 12:23:11 +0100 Date: Fri, 16 Oct 2020 12:23:11 +0100 From: Steve O'Hara-Smith To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016122311.022f1cf733eec8612d24b857@sohara.org> In-Reply-To: References: <20201016113408.16d58d68@archlinux> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCP0N1pyHz4nxG X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=uJ6rFR0f; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003b75108.e1f580c0d04e130d8955c6864cf60214@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003b75108.e1f580c0d04e130d8955c6864cf60214@email-od.com X-Spamd-Result: default: False [-2.15 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-0.89)[-0.893]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[sohara.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.04)[-1.036]; RCVD_COUNT_THREE(0.00)[4]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; DKIM_TRACE(0.00)[email-od.com:+]; NEURAL_HAM_SHORT(-0.52)[-0.521]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003b75108.e1f580c0d04e130d8955c6864cf60214@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003b75108.e1f580c0d04e130d8955c6864cf60214@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 11:23:17 -0000 On Fri, 16 Oct 2020 15:55:59 +0530 Manish Jain wrote: > This is where I actually have an entirely different philosophy. When you > create a file with a leading - (or for that matter, weird characters > such as * anywhere in the filename), I think the filesystem driver (i.e. > the kernel) should throw a warning: "Do you really want a filename like > that ?" There is a POSIX standard for portable filenames but no requirement to restrict users to it. By default the only characters not allowed in a filename are / and NUL - which has the advantage of supporting filenames in just about any encoding without problems (useful if you are serving files for international workflows). BTW you have left out the fun and games available by use of backspace and vertical tab in filenames - I have seen sysadmins lose half a day trying to delete files like that (* is another favourite component in sysadmin trap filenames). -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 11:25:42 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0B3D343185F for ; Fri, 16 Oct 2020 11:25:42 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCP391z41z4p7x for ; Fri, 16 Oct 2020 11:25:41 +0000 (UTC) (envelope-from ralf-mardorf@riseup.net) Received: from capuchin.riseup.net (capuchin-pn.riseup.net [10.0.1.176]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4CCP2r2rD5zFtS7 for ; Fri, 16 Oct 2020 04:25:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1602847532; bh=PWOP8QpOWvBYc0GgWxpR9GAqL4PXrxUjGal7m3g/bN0=; h=Date:From:To:Subject:In-Reply-To:References:From; b=ap7BZNrIc7StyAnrBcQ1gW5jLfQiI/Wr9vVe+iSQk4qPMrJ3Inu/j72sijDYUxtxk IIoQOfGzEPntmT9QaAEMS8f74stWbcUq+24uRscEwFXwb12A/yCJS1WfGvpzSAPWtw ZzzO642poMnb3TgRIMGtNeRy5e020HWMOhtIezGw= X-Riseup-User-ID: 4DFD3AE4343CAB2FD50270C880FCD1455C58FA9E85A06F171C09FD08D3F3714C Received: from [127.0.0.1] (localhost [127.0.0.1]) by capuchin.riseup.net (Postfix) with ESMTPSA id 4CCP2q5GwQz8vXV for ; Fri, 16 Oct 2020 04:25:23 -0700 (PDT) Date: Fri, 16 Oct 2020 13:25:16 +0200 From: Ralf Mardorf To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016132516.71e06c69@archlinux> In-Reply-To: References: <20201016113408.16d58d68@archlinux> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCP391z41z4p7x X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=riseup.net header.s=squak header.b=ap7BZNrI; dmarc=pass (policy=none) header.from=riseup.net; spf=pass (mx1.freebsd.org: domain of ralf-mardorf@riseup.net designates 198.252.153.129 as permitted sender) smtp.mailfrom=ralf-mardorf@riseup.net X-Spamd-Result: default: False [-4.39 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[riseup.net:s=squak]; NEURAL_HAM_MEDIUM(-0.98)[-0.980]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[198.252.153.129:from]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[riseup.net:dkim]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[riseup.net:+]; DMARC_POLICY_ALLOW(-0.50)[riseup.net,none]; NEURAL_HAM_SHORT(-0.79)[-0.792]; NEURAL_HAM_LONG(-1.02)[-1.020]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:16652, ipnet:198.252.153.0/24, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_IN_DNSWL_LOW(-0.10)[198.252.153.129:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 11:25:42 -0000 On Fri, 16 Oct 2020 15:55:59 +0530, Manish Jain wrote: >Hi Ralf, > >This is where I actually have an entirely different philosophy. When >you create a file with a leading - (or for that matter, weird >characters such as * anywhere in the filename) [snip] I can't notice a different philosophy. We agree again. I just wanted to point out, that our scripts might need to be able to handle some imported iDroidWindowsCamEmailAttachment file names, at least to some extend, but we and anybody using systems we might administrate, should apply a minimum of convention, compatibility, portability. Let alone that a apart from little girls nobody tend to name a file ***such a cute cat ;)... and only complete unworldly users use uninformatively names such as -*. On the quick I was unable to create a file with a / in it's name (Linux, login shell bash, just using shell commands, no tool explicitly aimed to edit/corrupt file system entries). I guess a file name containing a "/" overTRUMPs all other odd file names. From owner-freebsd-questions@freebsd.org Fri Oct 16 11:28:10 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3A0D5431BC8 for ; Fri, 16 Oct 2020 11:28:10 +0000 (UTC) (envelope-from michaelsprivate@gmail.com) Received: from mail-il1-x12b.google.com (mail-il1-x12b.google.com [IPv6:2607:f8b0:4864:20::12b]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCP611PFyz4pl3 for ; Fri, 16 Oct 2020 11:28:09 +0000 (UTC) (envelope-from michaelsprivate@gmail.com) Received: by mail-il1-x12b.google.com with SMTP id j8so2221998ilk.0 for ; Fri, 16 Oct 2020 04:28:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=XDefpga8FZfXXx2VbJT20AIY31Ur54ZTth1uYntVLic=; b=FwHsMk9bu7jYqNwSe4M2/BLmrs3GfzYcJ8Mukq9+hb1+ffilnY1sDR/kYXOsiWc62V Wu+0e4bE2O+npu6c2LUpRJHR8gf+QlskUEaIGmhfbE9k51tpac1AqDkhNZCp0s2FkvKm GYtJLrvhq+N3XesesFQ6T3G1I9D2gLLOSjwaAIn48fFnzkxDbGkO2JCkU0zV2OTEfkZs 3arouJHcp0upYFW/nR9vHYEF+n1GViW5VYY9ex5cL2Kv5s3WPl2wxhxdPoiBrQmra5ip GGZFbBcjQnIEfzUwFBJSSKqYbepTz8LKa0fJOoo+Yx+JUedj3/y7AsfS7eLVmE2TcW+F Wi8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=XDefpga8FZfXXx2VbJT20AIY31Ur54ZTth1uYntVLic=; b=WSz1+R48JnnWs8DElHyh7vDm3LMmxH8lDx6R1fQIm5zE+mAa//O4LR02bgevwJEiR8 cheEBGRLWxRWz+tH+3Z4azES06cHG5Qw+M2YdkX7MhaE8xNloWn7RJ3Pg4e+14HL8XZt 67ePRXLZnmRYBsN8rkRxRAM0rZSiARV057ZlzAOUAAIRC09LR7l7ITJaFem7qYSO+BWz sMEN1YXiSGkWiouT1ZUg+37Ad9BU77shftS7C8Jr+WJQPHGDhmt7RoYYELWcVoWTcm9w mdVjT4VAhXGob+LKh/bMfOJyViRg9hsJjNpEVzGyd9ZTHddrQqMcWJ4v7zO6hvtKkOyJ VWKQ== X-Gm-Message-State: AOAM532qrMMTfFZPAL+aTltan4F4N9dQP4vgkmqI8NosUA6+EQ2AhzHO 0voPwLH65/mfBbHoRXDSbCOrNongMczkqOH+sVU= X-Google-Smtp-Source: ABdhPJyWpxSSQkmY5COSSTnTXldS5nQnwaV9wbZ0d/GdeqoKfeXxYB2j7ZPViuk9TD7yG+r75FgdLagLmFotiWN6204= X-Received: by 2002:a92:24cf:: with SMTP id k198mr2244573ilk.3.1602847687998; Fri, 16 Oct 2020 04:28:07 -0700 (PDT) MIME-Version: 1.0 References: <20201016113408.16d58d68@archlinux> <20201016132516.71e06c69@archlinux> In-Reply-To: <20201016132516.71e06c69@archlinux> From: Michael Schuster Date: Fri, 16 Oct 2020 13:27:57 +0200 Message-ID: Subject: Re: sh scripting question To: Ralf Mardorf Cc: freeBSD Mailing List X-Rspamd-Queue-Id: 4CCP611PFyz4pl3 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=FwHsMk9b; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of michaelsprivate@gmail.com designates 2607:f8b0:4864:20::12b as permitted sender) smtp.mailfrom=michaelsprivate@gmail.com X-Spamd-Result: default: False [-2.77 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.04)[-1.042]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; RCVD_TLS_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36:c]; FREEMAIL_FROM(0.00)[gmail.com]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; NEURAL_HAM_LONG(-1.00)[-1.002]; NEURAL_SPAM_SHORT(0.27)[0.273]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::12b:from]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 11:28:10 -0000 On Fri, Oct 16, 2020 at 1:25 PM Ralf Mardorf wrote: > [...] > > On the quick I was unable to create a file with a > > / > > in it's name (Linux, login shell bash, just using shell commands, no > tool explicitly aimed to edit/corrupt file system entries). I guess a > file name containing a "/" overTRUMPs all other odd file names. > that's because '/' is interpreted by the kernel, whereas all other "special" characters are special to the shell(s). cheers -- Michael Schuster http://recursiveramblings.wordpress.com/ recursion, n: see 'recursion' From owner-freebsd-questions@freebsd.org Fri Oct 16 11:35:10 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9A418431E38 for ; Fri, 16 Oct 2020 11:35:10 +0000 (UTC) (envelope-from 4250.82.1d4c50003b92cf9.278181dca667d1ffd08ee21d36d4fc2a@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCPG55wpwz4qQm for ; Fri, 16 Oct 2020 11:35:09 +0000 (UTC) (envelope-from 4250.82.1d4c50003b92cf9.278181dca667d1ffd08ee21d36d4fc2a@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602848108; x=1605440108; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:to:from:date:x-thread-info; bh=KbHdFZlBivtxJ8VdISM1azEyRmxCVrtW69YiAFWeaDE=; b=Mq6DrrSJ3BMq/WyfyOgYD7Zui+rRa9nyRdUODOZ45qyIv9v/qi4ZCVa2rvZEeT4decObQ0smmTJSJCRkpGJ2r8YT0ZqahiLbH7Im77mJcVU7Femzv9BmgVoylYw8PrRRI9eWLm8Bv5pUahqXWx1TIsgJ6zCu+wjNyLvc4RvJM4M= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNiOTJjZjkuZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r1.us-west-2.aws.in.socketlabs.com (r1.us-west-2.aws.in.socketlabs.com [142.0.190.1]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 07:35:04 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r1.us-west-2.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 07:34:49 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTO0l-000Hqo-BQ for freebsd-questions@freebsd.org; Fri, 16 Oct 2020 12:35:03 +0100 Date: Fri, 16 Oct 2020 12:34:58 +0100 From: Steve O'Hara-Smith To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016123458.2e7f0eaf74adf4eb1443a69e@sohara.org> In-Reply-To: <20201016132516.71e06c69@archlinux> References: <20201016113408.16d58d68@archlinux> <20201016132516.71e06c69@archlinux> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCPG55wpwz4qQm X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=Mq6DrrSJ; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003b92cf9.278181dca667d1ffd08ee21d36d4fc2a@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003b92cf9.278181dca667d1ffd08ee21d36d4fc2a@email-od.com X-Spamd-Result: default: False [-1.75 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.89)[-0.888]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20:c]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[sohara.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.03)[-1.035]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DKIM_TRACE(0.00)[email-od.com:+]; NEURAL_HAM_SHORT(-0.13)[-0.131]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003b92cf9.278181dca667d1ffd08ee21d36d4fc2a@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003b92cf9.278181dca667d1ffd08ee21d36d4fc2a@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 11:35:10 -0000 On Fri, 16 Oct 2020 13:25:16 +0200 Ralf Mardorf wrote: > I can't notice a different philosophy. We agree again. I just wanted to > point out, that our scripts might need to be able to handle some > imported iDroidWindowsCamEmailAttachment file names, at least to some > extend, but we and anybody using systems we might administrate, should > apply a minimum of convention, compatibility, portability. > > Let alone that a apart from little girls nobody tend to name a file > > ***such a cute cat ;)... But somebody might have an NFS or SMB mounted home directory on a workstation set to use Shift-JIS and produce filenames that look really weird from the console. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 11:45:11 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 5082B431FF9 for ; Fri, 16 Oct 2020 11:45:11 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCPTg0nf1z4qy6 for ; Fri, 16 Oct 2020 11:45:11 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from smtp.infracaninophile.co.uk (smtp.infracaninophile.co.uk [IPv6:2001:8b0:151:1:c4ea:bd49:619b:6cb3]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.infracaninophile.co.uk", Issuer "Let's Encrypt Authority X3" (verified OK)) (Authenticated sender: matthew/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 8E93F16241 for ; Fri, 16 Oct 2020 11:45:10 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from liminal.local (unknown [IPv6:2001:8b0:151:1:4d51:9e48:c00d:505b]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: m.seaman@infracaninophile.co.uk) by smtp.infracaninophile.co.uk (Postfix) with ESMTPSA id E30F11B80E for ; Fri, 16 Oct 2020 11:45:07 +0000 (UTC) Authentication-Results: smtp.infracaninophile.co.uk; dmarc=none (p=none dis=none) header.from=FreeBSD.org Authentication-Results: smtp.infracaninophile.co.uk/E30F11B80E; dkim=none; dkim-atps=neutral Subject: Re: sh scripting question To: freebsd-questions@freebsd.org References: <20201016113408.16d58d68@archlinux> <20201016132516.71e06c69@archlinux> From: Matthew Seaman Autocrypt: addr=matthew@FreeBSD.org; prefer-encrypt=mutual; keydata= mQINBFJIL80BEADi7/VbnnErDU6pjEhI/SzEZ/HbDRkJ5g7HroAtqIRm6nj8ZwOAgZ/2ZnWn 5F+fXTuLsG0FLNtkd17FoVcuCi5e/GPliXI5cmamV7E1Yz4T8UsJ7RQolimyxVexccKd16Tc AA7B9bFlJSKkBUSD0buj7VjT07xWhRzu6Vgi5r0UjLALYJz977uZA0F1aOGOXREDEAOhdcNc kSNjynqAwDA6dCT1Elpi4key1fYjv4jyDF+GU/YXul2Y/rguA8FCkHd9vyym5eAsLQ5mG00V V9fkEHIpH5KorNVnl/ufHXnkZqmHAZVpFDcrshb7aZ/pL45PXyWgLj+e6etelgj3a2bZi0JF cVdXCnBZVP2oIyYblM11ugTbfCwodORU8a5KfPeztMdAtDr4e+32NTrPdPi5rLT+GUsYz+PL 3A3m3u8bdsFp40DlIrBtSByVjqERxcfhphrEB4J8BXHUG7OAtXkZMlW/PGKDwXJq0O6Z5Tcg YHAoEiSWbXiexHgXNJyP+sqnIlhLWhSJGeJ+C83wqI6oYlZUCW00NkPxcIHnQPV/z+5wQVci TMyaWC2YCIHz4Ljs+TnwWMz0E8PNFDfHVbQ0W4PRGV7gRAqxfL+yKufauIEGbEq8rNDbSwL3 bcUCxR4ZDlaUEUwT4J8naf7rjdgiEYHs2Ig3jeK1+ER4FPG1sQARAQABtCRNYXR0aGV3IFNl YW1hbiA8bWF0dGhld0BmcmVlYnNkLm9yZz6JAlQEEwEKAD4CGwMFCwkIBwMFFQoJCAsFFgMC AQACHgECF4AWIQRyz6whebywJLW1RZADb2ye5/OevwUCXp/jFQUJDjo4SAAKCRADb2ye5/Oe v5lwD/0bhCaxMGrWb1PpmvqwARJRcqcXJOLUJXUvjKrMp97OtbGOucgsmTvBzXR7XaZrW/Y4 t5kquSg39ZellWjeVn2GUc4Cql+IPlGkxYiJu39dHu66iOhgpfOzIZQL7NxFysc+bvY0/XO6 sfNNUcIQ0ywmiOQedoxmcJs/gJo4mAZsf9ltLnlDeCTG8OqsjAKUsxatoGHvZ3wvFeEfdYjJ 9BO1haLm5EnnEnMlmgfopR3oW7oV8p8lIVFwzeHJTCVOv3xoo5o0kXK+YHdOLYWcPM9hiMDq u5AGbfPWw8IsDWFjeCUcgNADCG/DKJ98ld6R7QjDCOh8waKQDSStPxF71YwtUKRMCm7JayrM GhIlFxCfp5P9ALdiTsOctW5ONBBGvyCd3ggVikCxvsIP7rmt+yh5Bd6rz+Q9z/RikugN8ZRA 4g2TwDaM36obseh5VyDSlOkWpIJ7Mi5g8TWnhwy2KGeVvuQh2jeeMzCUBFQ3cV9sifAkcjoK ldsanwjKzqMT8Tf671zALHeWj1VtRjiRGDBPpTPeA/bmqZLAL5kqUejYZeqI7rkUN4cGYW59 o8P9F0GDcDBhoYRQOxPcm+eJMOjr8oDxwfGUJN5QYPEaEXxLfypSYrK8qem5Lp4uIdJfTLrT atLU97HL+POyyhDnvfob54OlY2BqUYL173MpHt17J7kCDQRSUUKTARAAt6FH3HbDFoumOWUu JlDgOQs3wdp2n3IKv7gqzbDdgaoWW7hDTvjO0Cb6p2PGUKEoxMQQoIdDO0pQ9rgr4Sh4VSVC 9WMO/fUwqdrIs2nACIg4OwvNhIccW08S+N72f+yuXWOQ/dv79cwruE26/BEXgIP09MYcOWwc UCXzOoUR3er+jzcsN9uFjcsBVUJLIEru1askHRzCUa5P9S9GAFBwN49HC5IJWEzdLP27FjjO G5UG3+QZahHrjG1i6S3bIYXtaGsqNyfkp9Is7Wpj2kk+s9Ua+YMG/V5YVlbANIexa1yr75p1 W9biqXpCWnB3TaHSfI0G1t9w8K2qhR/Z1/YLIcRzZ2aHJnvbzJYw5Cs1jfNpFytbASsxj0rb ReouftlBvVWFRxsZ+oG1ZXL64/SVKMZAnfBNxd1uajp+HtoQtYoTu88la6zcdnAhOD5JdOnt N2VF8iQnDfPgkidfuSZ1C059xaRPTSRJBgMRDtOlDxgz7Pxx/7L2jwxRY1dq6NGioflY7CCp Gc7bi1K6xnf3lBL8X2nGpRAVsg9Lx1ShIWkgNbTAcPXpXcXlJ1xqz8HS8Twadh6gIfk/RNch BIED9lkVCKHYp/XQb8T8vMwn/kTWUm5WlPkQUFQN4D1b6+dJw4bwn/wiRS8did1MU1OytJB6 tljfEUCx0uKkzqr+33MAEQEAAYkEuwQYAQoAJgIbAhYhBHLPrCF5vLAktbVFkANvbJ7n856/ BQJen+OUBQkOMSYBAonBvSAEGQEKAGYFAlJRQpNfFIAAAAAALgAoaXNzdWVyLWZwckBub3Rh dGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDE5RjE1NEVDQkYxMTJFNTA1NDRFM0Yz MDAwNTEzRjEwRTBBOUU0RTcACgkQAFE/EOCp5OdNFg//ZqeVdGoKkMvALPzZjGz84+6l0kcM xSN4TfWmec0YpSmDEzCw4/SZoGqHlZb8lcTevmNrNXg6c+wVw6P+Ycl20Nzb98Kt9C5sz+zG VmPPK+3O9gaPnEqlIKnnbxKXXNHQdd8Mf0UTpifMqX0IkWOqhe/tQKGoQ9+feKvLIaToIe/N josW6vJ9YAgFqZ0015zwbElhMNFmgDMOI2SgjBZ9ngP1U82Mqb7/7G9GxHtnwuJBSnPJgN8t av2O9uWPC0N8deyZBH4y9ERBPTFMc46wjkW030olcq7g4hZ55rpPIEyGQZCq4u1gGibbiQJZ EyUQT7BJm70/PeUr3uNjPlQODV/lF5TBvqGHEmlSQfo6Yb/QQx07CK9bvhUSO2XP3ybS8Jwo MZlgZzZcjiPiQF9ot6152/Cp/XrsKgtk+fg5ARZpyywRlQk1JCHRZvhgXIxqNYA04uwdPFcL I4vPiDaLS8mhXHLRZsSpHmIBqqrnam5Lq7iDc39UZrSJMM40oy3iAOI2B7AOCbzxRuEplJd3 E/tEqrnFGcPVN+h52ka74lEyfkwA2RrASWJJcXLN3/VsizEj8okepefzjU/UPnU8sirzeWWo 8Z4uKddovk//NwAPUJbee4vZLjYE6MWdpEoZP9CZXbtIPWuc9Djg16aHOgv44JPokDMaHA27 A4rw2KwJEANvbJ7n856/CZQP/1XGLC6fXn9SsllmWbsBjgERmqqNEz1c7uxqdNcPc3v/p5hG vuJmbg76H+dj9ZiHvStnSg7TQ73TtDbQNlnnAuyN53iYDzDGk8ZkQtWviwvbs1G4VbgB8DA5 Wdpjx/nH5vOpKB+6d9/KPZdjpHJVQydAbEqf6alRyMx2COBKzUg8COTQQtktO7fuXf1jzlOs OiSuHYTgRq7HUoYTvs8S62W2szMdYEBDJ+/j+9q24sKDpJYEnCKfirX5yFeknkRQUUz1Zsyi thnOPgJI1j5kdClSAA6q5LwDorHhzW4LVATqd4ATSeM9yTKSPbskquC3olamX3Bbfl8bT4NP Eot1d8A2FWehpWPrIvl2Tg4nI2/9krighKrrQBkC91A1bJPg4td3msCvrYRkiVFVFNHIO2uD XtTJ+heUmvNM4XlvUTXo7BE9Ew3yLg2B+Ipo5FVJJVPvKfWxVGKVVxBzMhbPYmbwNxE+NKZa J51Tdl+KeDXniadB5DMX/er7bhmG44dQUvz3kDYAX8c1i9vCxVQWNxcV98/ZO5RtXXZxokdh 8IMjqGonk9XlLi5GLbCMww2pQVqWVuQfLZTeVAzklB3dAj5ByJL1WbdIXMekMDWYXaEc+TAy tbaPz1YLJRz2s0tFOULw4LiVQqMobRRl1anfoEiUrSHHeTV1DrA+W1uQuf+cuQINBFJRQrgB EADUWFag56O3CaycayGght1rYWYz7P9/3s7OlqAuEAId8/kSz8jXzAb/Qb6t0247a2MD0gxn jgZQy2OiQOsOTrc31L6tUrLVATL5Q3oKIh9hOlNMA+cRjsgY3UmMaSw+Gftp64EJDBQwBXWT 7CSUEJw4PqzwMPiTHRkmqQfzdfNagFJVqZ0e+cznoLzI9WvkccwLW1kicBYEysX5yOXUQ9/P cKqRWcbxLFznJ16JsxL1DeUct5WRWUxECY2rM0t+AkNRa3NpzskiMUSzFhiGmJo9yyy1RS4d rjMhEn/IcM1sO21ZF/WWuUVkul65qngFnaFDDRQ5lU3AagWhLhmppmK/yabSVfqz38B1APoB WuldYprslTbAOJrL2xFtiH7m9VYbP2aGdwr9V/C27kiNWnm/lYzP9Z+dTFkxw2V+BOjiLWzD DD6pEE7YDhiPyoopadOyXtoJf3aK1OI+DBu3piBA/CDDDvavruM+3mjxUxcOo8w8rMaJzDUD LG0yOyhKWef3UW5ly3CKXe8+m/MZe0GavNBJt0ObLQpPmnn9b2kP/xS0ssszo8uzlfSMiGi9 AedAoRQ7vFXfI0MBb0M8gJ6Ht/+j1b5Al9ABeeA3PRuu+aBJwBRdFp4AV5BsCa0Qb3aqVJUP uBvtY56aWWB9sSfQ1qeu/loRxkJbHhaPJswscQARAQABiQI8BBgBCgAmAhsMFiEEcs+sIXm8 sCS1tUWQA29snufznr8FAl6f45QFCQ4xJdwACgkQA29snufznr9gXRAAoM1Vj0WDukryz52s MM4wPD6ny/uGaL0mTscWvvZZ7sXhJSgdLkYYZeXRuDOZN6K8vCxFB1frploGOHY6z5U3CW/l sEIW0BvEoYi5yLneCIJU2M5Y/8+35ffdV103de+RXP4VpAVf3kNdle7z6xpO452fhw2ymrAV +PgLlRBNVVgPG6NCrSpwLE5B63+guJzwhJ8dQGgi+TQTGHdWz66UQLig1KRON/KFtOlDCJci YLYmnnXIqb60JD8oePfjgyFTHEdXcEllsHtRhtE81Aw6fMeOZigxKaDcDzopS+8RWSHxrFL9 qwCNWL9KycIu2usa5qxBSVf4Q9hr2vFVuQZHnVDvuM6RzJBgD+j7o7xA7DWGv1njPJyoCCmV SRz4XuV2Y2jonNuEipsaftzMFlIkg4yg0s+eknh0cv0IjFTas5FMGX7hQLClnsCy8rzCDzKC J4jNALJ22sdft1CsZjOz7x+aOg5ypDOfR29PmF/gygk2dgt9HjMHcYlOkgsbY0/PwxNIpgYM xI7iELFa7W9ZNZfcWDSaP/VQfsL2/vOHBZzEmqmalQHp5QeZszGDTwr7yR886viXbLV40bBs ZXyVm2yodwsT3B1swxMGASV6ZG9p0bURekwyuN1zjCf2cIr6SrU8gTZjQyAlfDtU+dhvVCfw D2UGgsFXnd7KkBLadQs= Message-ID: <18d647f7-293c-434f-f499-41a13bd8f357@FreeBSD.org> Date: Fri, 16 Oct 2020 12:45:07 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:68.0) Gecko/20100101 Thunderbird/68.12.1 MIME-Version: 1.0 In-Reply-To: <20201016132516.71e06c69@archlinux> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="uMXdd8QjaltXMcKXPURxjcgov5PVNAzCP" X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 11:45:11 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --uMXdd8QjaltXMcKXPURxjcgov5PVNAzCP Content-Type: multipart/mixed; boundary="nf4aRMookKNTCit1t5pesxJU52OLXrvXP" --nf4aRMookKNTCit1t5pesxJU52OLXrvXP Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: quoted-printable On 16/10/2020 12:25, Ralf Mardorf wrote: > On the quick I was unable to create a file with a >=20 > / >=20 > in it's name (Linux, login shell bash, just using shell commands, no > tool explicitly aimed to edit/corrupt file system entries). I guess a > file name containing a "/" overTRUMPs all other odd file names. There's only two characters you can't have in a Unix filename, which are '/' -- because it's the directory separator, and '\0' (Null) because C language strings. Anything else is fair game. Cheers, Matthew --nf4aRMookKNTCit1t5pesxJU52OLXrvXP-- --uMXdd8QjaltXMcKXPURxjcgov5PVNAzCP Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEGfFU7L8RLlBUTj8wAFE/EOCp5OcFAl+Jh8NfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDE5 RjE1NEVDQkYxMTJFNTA1NDRFM0YzMDAwNTEzRjEwRTBBOUU0RTcACgkQAFE/EOCp 5OfcWQ/+IOk0KnF7GcogVKZD7VfqwZRJsOeHGBb23MRIONKXifFNe4R1Z217Unpj pzTjAR0koR5o9jQMfzOoyVfAj56GfO5YT45PSQhrnRztfhz0vRgNk+Krfj15IJ3s 1niJzD6OvQ6g97cuJuPVr6cxdPED/ubO2g1WJqJ56/DBGQGWEsuZPgL/BZj6RRKz CGx5kdjTFla6ocE35LccvSdQrhAsUj8OKT6vgNFIBIdtEljLDA9GcBRvi26TQgm3 fmhOy0Bn9jtFn4Rl0FFaeSYzSAiq+TOfaEBPgCEPWrsHk2L5HoXTpEZPN4z7Gy+Q l8o2Lh9nE0rZ1Va47cVMm7YFK0xHsl/lJLj5BmqCWMVZfUywhjNyhP+JdSUMMJBg /MxaIaeRl9avG1qX2c9325poBxzgP8l1YxcstgoL+URD546fbN7B6i9gBTyiZM4y /F5zHt41oTinI6S5a/aSDQDqXte4Ojr/pIhcU43UANRD+mElREvPXHaZHcb88t0A hMJm5i6JOT+GmTBRoD8cBHqagr1oAqFq3e0divVB+dsFQ54S07xMPQGFKDFwhRFb cXQvnM08sZyI8CcDLcNxiHqwI8+PP/IJP7fgmTzTYlIezD1i0DzxnHHxKJCo+MzX b/p9+AxnMj4DRQ/2EvfUdp44dearVPpzfRkhMygrYihVT6IzY4k= =CPX3 -----END PGP SIGNATURE----- --uMXdd8QjaltXMcKXPURxjcgov5PVNAzCP-- From owner-freebsd-questions@freebsd.org Fri Oct 16 12:00:35 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 181C7433056 for ; Fri, 16 Oct 2020 12:00:35 +0000 (UTC) (envelope-from roberthuff@rcn.com) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCPqQ6J4vz4rlW for ; Fri, 16 Oct 2020 12:00:34 +0000 (UTC) (envelope-from roberthuff@rcn.com) Received: by mailman.nyi.freebsd.org (Postfix) id D7F15432C74; Fri, 16 Oct 2020 12:00:34 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D7BAD432E50 for ; Fri, 16 Oct 2020 12:00:34 +0000 (UTC) (envelope-from roberthuff@rcn.com) Received: from smtp.rcn.com (smtp.rcn.com [69.168.97.78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCPqP6nlkz4rrB for ; Fri, 16 Oct 2020 12:00:33 +0000 (UTC) (envelope-from roberthuff@rcn.com) DKIM-Signature: v=1; a=rsa-sha1; d=rcn.com; s=20180516; c=relaxed/simple; q=dns/txt; i=@rcn.com; t=1602849632; h=From:Subject:Date:To:MIME-Version:Content-Type; bh=zPH+4C9CTXBeEZ9tbgviIlAP2Xo=; b=VZrgiExEFMjteHvkAUJeiX+804Wrhl+FgG/NX/WMQaIlAEsIsSUkcPoowTcigmy6 nOG+90G5fNu2k2h2Lp+nuXMqLBY5nEaMLjwqI1oELjmAJSJCB0LVZuztYxVEnCqa rQgvAf9ZSeOZy61zgDlZUNeQyix9chyvVhfpPZfPHNAHl2knfEVeQY2v9QRh6dou kqZP7JkdQF8bYGH0WLNP+0jWrJqSq+d//thIYrKCSUVVBnqTzmY1Bz0o/oTM2E5G 4+UuMUHrdqUQKCbBsDnhdcCYRFGt9JSKvetRP0OVFJVXQOk7rWPMc1OfAHXRyYtg eE471pgEfYEduQ0IjGgPQQ==; X_CMAE_Category: , , X-CNFS-Analysis: v=2.3 cv=OswxNB3t c=1 sm=1 tr=0 cx=a_idp_x a=9TgA2UwI6Wy+6BV4wQM/cQ==:117 a=9TgA2UwI6Wy+6BV4wQM/cQ==:17 a=KGjhK52YXX0A:10 a=kj9zAlcOel0A:10 a=XRQyMpdBKAEA:10 a=afefHYAZSVUA:10 a=48faUk6PgeAA:10 a=2v6Nz8L8GH7cKgcV3QAA:9 a=CjuIK1q_8ugA:10 X-CM-Score: 0 X-Scanned-by: Cloudmark Authority Engine X-Authed-Username: cm9iZXJ0aHVmZkByY24uY29t Received: from [209.6.230.48] ([209.6.230.48:44863] helo=jerusalem.litteratus.org.litteratus.org) by smtp.rcn.com (envelope-from ) (ecelerity 3.6.25.56547 r(Core:3.6.25.0)) with ESMTPSA (cipher=AES256-GCM-SHA384) id 11/FA-38180-06B898F5; Fri, 16 Oct 2020 08:00:32 -0400 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <24457.35680.223661.203846@jerusalem.litteratus.org> Date: Fri, 16 Oct 2020 08:00:32 -0400 From: Robert Huff To: Manish Jain CC: questions@freebsd.org Subject: Re: sh scripting question In-Reply-To: References: <20201016113408.16d58d68@archlinux> X-Mailer: VM 8.2.0b under 27.1 (amd64-portbld-freebsd13.0) X-Rspamd-Queue-Id: 4CCPqP6nlkz4rrB X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=rcn.com header.s=20180516 header.b=VZrgiExE; dmarc=pass (policy=none) header.from=rcn.com; spf=pass (mx1.freebsd.org: domain of roberthuff@rcn.com designates 69.168.97.78 as permitted sender) smtp.mailfrom=roberthuff@rcn.com X-Spamd-Result: default: False [-2.47 / 15.00]; RCVD_TLS_ALL(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[rcn.com:s=20180516]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:69.168.97.0/24]; NEURAL_HAM_LONG(-0.99)[-0.989]; MIME_GOOD(-0.10)[text/plain]; NEURAL_HAM_MEDIUM(-0.98)[-0.984]; DWL_DNSWL_LOW(-1.00)[rcn.com:dkim]; RWL_MAILSPIKE_POSSIBLE(0.00)[69.168.97.78:from]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[rcn.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[rcn.com,none]; NEURAL_HAM_SHORT(-0.40)[-0.400]; FREEMAIL_TO(0.00)[hotmail.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; INTRODUCTION(2.00)[]; ASN(0.00)[asn:36271, ipnet:69.168.97.0/24, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[questions]; RCVD_IN_DNSWL_LOW(-0.10)[69.168.97.78:from] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 12:00:35 -0000 Manish Jain writes: > We do not disagree here. The OP's "problem" isn't a big problem for a > shell script, assuming we are talking about file names such as > > foo bar 10-inch.txt > > and not > > foo "bar" \ 10".txt OP here. The filenames at hand were generated by "find" and - on casual inspection - have no oddities other than the embedded spaces. I leave the debate on the general case to those with more time, investment, and experience. Respectfully, Robert Huff -- Hello ... my name is Coronavirus. You are not wearing a mask? Prepare To Die! From owner-freebsd-questions@freebsd.org Fri Oct 16 12:36:58 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0A5F3434780 for ; Fri, 16 Oct 2020 12:36:58 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCQdP5xsJz4tQb for ; Fri, 16 Oct 2020 12:36:57 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: by mailman.nyi.freebsd.org (Postfix) id CBF4243437F; Fri, 16 Oct 2020 12:36:57 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id CBB8543454A for ; Fri, 16 Oct 2020 12:36:57 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from slave.jschneider.net (slave.jschneider.net [46.235.226.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCQdP1sPcz4tSw for ; Fri, 16 Oct 2020 12:36:56 +0000 (UTC) (envelope-from freebsd@jschneider.net) X-Disposition: Mostly harlmess; Fri, 16 Oct 2020 13:36:54 +0100 From: Jon Schneider Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.7\)) Subject: Re: sh scripting question Date: Fri, 16 Oct 2020 13:36:56 +0100 References: <24457.35680.223661.203846@jerusalem.litteratus.org> <72957D12-2A86-4F92-8E2D-091F88989ADF@itsp.co.uk> To: questions@freebsd.org In-Reply-To: <72957D12-2A86-4F92-8E2D-091F88989ADF@itsp.co.uk> Message-Id: <185BCC3D-EC07-4B7E-B3D9-55DD8AD7F79E@jschneider.net> X-Mailer: Apple Mail (2.3445.9.7) X-Rspamd-Queue-Id: 4CCQdP1sPcz4tSw X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of freebsd@jschneider.net designates 46.235.226.89 as permitted sender) smtp.mailfrom=freebsd@jschneider.net X-Spamd-Result: default: False [-1.55 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.74)[-0.743]; FROM_HAS_DN(0.00)[]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[jschneider.net]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.46)[-0.461]; R_SPF_ALLOW(-0.20)[+ip4:46.235.226.89]; NEURAL_HAM_SHORT(-0.55)[-0.548]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:44684, ipnet:46.235.224.0/21, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 12:36:58 -0000 The really robust methods use null separated file names such as from = find =E2=80=A6 -print0 that can possibly be piped to xargs -0 For example xargs -0 Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3A1F1434EA2 for ; Fri, 16 Oct 2020 13:01:57 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCRBF0Dywz4vPV for ; Fri, 16 Oct 2020 13:01:57 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: by mailman.nyi.freebsd.org (Postfix) id 07FC5434DCE; Fri, 16 Oct 2020 13:01:57 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 07C61434EA1 for ; Fri, 16 Oct 2020 13:01:57 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.17.13]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRBC6R2tz4vfy for ; Fri, 16 Oct 2020 13:01:55 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue109 [212.227.15.183]) with ESMTPA (Nemesis) id 1MIdW7-1khS6s2Mj7-00EfMv; Fri, 16 Oct 2020 15:01:43 +0200 Date: Fri, 16 Oct 2020 15:01:43 +0200 From: Polytropon To: Robert Huff Cc: questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016150143.9ee6e90f.freebsd@edvax.de> In-Reply-To: <24456.60388.135834.43951@jerusalem.litteratus.org> References: <24456.60388.135834.43951@jerusalem.litteratus.org> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:BwxKUo6ZOl7bXmarjmnoFIKK40wi98L3aYh5A7Z4O8/eDZ35Lp8 Vtlm9SBDrKMtjaNqrMq/P6CLDfBy9g27UbolkpAk11olyvhVd7cJBN1G8Dn1zEOH0NSX6ib 5MSWNDP4vc3NEIssjxuQpQGRcKZIfzFlG5u7BGmvGMRG+bA4KESasTi0Ae/4NZYaVyJYtDQ Kz1iTriMRe31Bht7JnylQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:MLno05pUohI=:nLDpkkXIW1+3B8HKSUaEt4 CksgnM3nfzNjfDErWicpYf/lkEsVPoW0NbV7LGyio1LDfN/ZycdfQJ1Ctiv6yqCoOGeG/qyrN KZ7XU2iuC/l1hifP92JKUvJp1Bi/4UjNwj450QeJmU2RfQd/ELGulh48m83/aD3qNVmnpmTGU BlPIDmRVKnSAfNACRfDjP239fbSqzfjrF4Oe7U3co1gH6kuGveTLJq7V7VfOb+OyL6y0QPqcT xD8h6j19Xfj8PmW0vzHe355SlAEOo2mILjbRy7ueMXnydgq94B+2zqO7eaHlcyyOZ5wyJ7DLZ g4AAQelmN+YnsEQ/ce1ynnltPwJ0lMxaIC7GvfCbKIdv54ArkTbPfZXoF3mOmK5E7PinpC++r ppJCUPaAmzO8Em5aVmZdaooDqbtmmRWScGS/zU79yl0f/XO0jwNpwUAF/eld6 X-Rspamd-Queue-Id: 4CCRBC6R2tz4vfy X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.17.13) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [-0.13 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-1.03)[-1.034]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.70)[-0.696]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.80)[-0.804]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.17.13:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.17.13:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:01:57 -0000 On Thu, 15 Oct 2020 20:40:04 -0400, Robert Huff wrote: > > I have a file ("files.list") with a list of filenames, similar to > > /path A/path B/FreeBSD is great.txt > > (note the embedded spaces) > If I use > > for FILE in `cat files.list` > > FILE will be set to "/path". > How do I get it to read the entire string? > Or am I using the wrong tool? Generally speaking, you need to set IFS, the input field separator, to newline instead of space. You also have to pay attention to every point during the script you will use ${FILE}. For example: OLD_IFS=$IFS IFS=" " for FILE in `cat files.list`; do something ... "${FILE}" done IFS=$OLD_IFS Instead of a literal linebreak, you could probably also use something more elegant like IFS=`printf "\n"`. Also note the quotes around each use of ${FILE}. But: Whenever this comes up - spaces in filenames -, I tend to suggest _first_ reading the following two articles: Filenames and Pathnames in Shell: How to do it Correctly David A. Wheeler 2020-02-22 (original version 2010-05-19) https://dwheeler.com/essays/filenames-in-shell.html And: Fixing Unix/Linux/POSIX Filenames: Control Characters (such as Newline), Leading Dashes, and Other Problems David A. Wheeler 2019-03-18 (originally 2009-03-24) https://dwheeler.com/essays/fixing-unix-linux-filenames.html There is so much wisdom and knowledge in those articles, you won't regret reading them, thinking about them, and finally understanding the problem space you've entered. :-) You can easily use sh for processing such filenames if you take care for a few important things. Especially if you do not have the option to "normalize" the names, i. e., replace spaces with underscores (the common replacement character), there is a way you can go. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 13:05:58 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C6BD6435286 for ; Fri, 16 Oct 2020 13:05:58 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [217.72.192.75]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRGs49llz3RcS for ; Fri, 16 Oct 2020 13:05:57 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue108 [212.227.15.183]) with ESMTPA (Nemesis) id 1MYNS0-1kyqD70Waw-00VN5Q; Fri, 16 Oct 2020 15:05:51 +0200 Date: Fri, 16 Oct 2020 15:05:50 +0200 From: Polytropon To: Kurt Hackenberg Cc: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016150550.6562ab84.freebsd@edvax.de> In-Reply-To: References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:JdlUlCbSVMOiwf7ttOJZeDTyvRLRmvBi49H/vxJcdrLH7kV4Hsm sPj/AFxbEpAKyMA/LsF6wW7i3PnJMwxTJy5IlcLqXDp+6E4GJN2rbbAflqGIFf5TkQ1Rwp8 ZPSIjD+Mbss7THWEsPcIQGxHg01fe5XCtmcNyJ8fU+JZLs/DhXq6AsMKgDA8S9xH3AwfbUv cm4kznMi3WTTJVQOJpIPQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:1qi1m+0cApE=:Xqkxybz+wB2xe2j6H8uQd2 kd0xtxYra1h4He2y3w4h+SxgGEzJT11swtelYbvQQMRF8GmzBPgb3hDq0dXPeMtwKScKCiIk9 jWiQ15odcjz8vF1cDOWFQMSDSRLB9Qbh/M0gdrUltPFFwt/vspydnd0cPUiHZOitXOj+TzMGm aG5LSx1KCd2Ip3UVz6yAPmE6x/9pV4RE8hquQkMgs8AaxAKjuKYFHf164Ja6znpkLDrVrpbSv WuVBMHAFz3xkeWalQLoVuBoSXSeS0a885oYIgNyNFCLH7iE7q/SFr/QYWFqtgkz2Qc/SQHeau w/6PAy4TnMkjdRwSEyTcxmzhf4U4MAoMLzAUqk+5rh0i9eUMvB6vnBG9vLvvFyStPNFVPZzE4 4QVOAj/skyN8jNmxgKgzWG11/EUm4u1Tp6u92YEUUeh2Oqdata4T9jSM0QjMR X-Rspamd-Queue-Id: 4CCRGs49llz3RcS X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 217.72.192.75) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [-0.02 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-1.04)[-1.044]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:217.72.192.0/20, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.63)[-0.631]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.75)[-0.747]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[217.72.192.75:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[217.72.192.75:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:05:58 -0000 On Thu, 15 Oct 2020 23:14:13 -0400, Kurt Hackenberg wrote: > On 2020-10-15 23:05, Bob Proulx wrote: > > > Oh you are tormenting us now. :-) There are some subtle issues here. > > > Maybe a shell is the wrong tool. No, it's not, it's just not as trivial as if the filenames would have been "normalized", i. e., if they wouldn't use reserved (but valid!) characters such as spaces. :-) I have dealt with this kind of torture many times already, and I'm quite happy I have a script that "normalizes" filenames for further use, if this is possible and allowed; if not, there are specific precautions you have to observe in your sh code. The common "for f in *; do ... bla $f ... done" just doesn't work anymore. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 13:09:49 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 36935435457 for ; Fri, 16 Oct 2020 13:09:49 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [217.72.192.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRMJ0jYJz3S82 for ; Fri, 16 Oct 2020 13:09:47 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue106 [212.227.15.183]) with ESMTPA (Nemesis) id 1Mzy6q-1kHmDb3AaE-00x51e; Fri, 16 Oct 2020 15:09:41 +0200 Date: Fri, 16 Oct 2020 15:09:39 +0200 From: Polytropon To: Ralf Mardorf Cc: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016150939.d2218e13.freebsd@edvax.de> In-Reply-To: <20201016054735.33ad768e@archlinux> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016054735.33ad768e@archlinux> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:JSHq0Fheg7ZocZefw2W6DF1HAymZZ66GHjchUshXHJH0gFtsP7e WwthGZJ6RzDlEf99tfMqOZuCldh6UgUuQxK8gTKDCwHuhpvzLE+Vu95YBTLODuXKmRZgzck ZMYD088BhoAQXlqOiTR11uH66bjgrML5b7zW8CX5yYQdQTwA0yIwd/4rh0aE1Y+3UdD33BE genpGuLnJPy0AxXIRefdA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:qVy1nFevumQ=:QJl7qOnuKXzNR+gEF/WODn hdRA4CqaGEV9rRio51eoLE3u2Het77UZ8Mqh1KXq506cR1oaFRvD/mDPFkRw1bMazMPvdj2RW XtKYvcROpJqGBPw0bDhFdJ9Cn8oX3r4pfHNTgYLUydblnn7qcoiJxm87SaL6tov75TEyBCzYK 5pf7oOEzIrRDPnuqK9Srn70t9syzNl8zogFaSDZ4B9IOkYFNHzfyY6AqdsheWbiFbZTgKKS8o Q73ZBT3IvmCBGMgGdUXFSN+wASmuwOS7sPSk6W/UzNt5rx/kIDk3fI6zUydGBPaUSFMD2Ij9M 2VkxqgJmLOFeV8S5icNG4X/a++8T4X+2/rDDACb4bznnJax4/f30rl2C0H1zMrrZ5lRGmtsoR q2UIwsdYg1qF0pZSiYtMrLRFnWSh1NoIRXzzmsIHJI5ZifxQ15Ejk1fi1uaxh X-Rspamd-Queue-Id: 4CCRMJ0jYJz3S82 X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 217.72.192.74) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [-0.02 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-1.04)[-1.043]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:217.72.192.0/20, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.63)[-0.630]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.75)[-0.747]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[217.72.192.74:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[217.72.192.74:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:09:49 -0000 On Fri, 16 Oct 2020 05:47:57 +0200, Ralf Mardorf wrote: > To me already "FreeBSD is great.txt" isn't a good file name, I would > name it "freebsd_is_great.txt", but that's just me. However, > naming it " FreeBSD is great.txt ", would be just stupid. But valid. :-) You can easily have filenames with "false positives" (read: homographs) using UTF-8, where a dot isn't a dot, a space isn't a space, a hyphen isn't a hyphen, where invisible characters are included at arbitrary places, and then make the whole thing look innocent, like "Alice & Bob @ the beach in summer [2020], good weather (1).xls.jpg.exe". ;-) And as you know, stupid people tend to actually _do_ stupid things, especially when they have access to a computer. :-) -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 13:19:56 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 333BE4356E4 for ; Fri, 16 Oct 2020 13:19:56 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.17.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRZx6JYSz3SQN for ; Fri, 16 Oct 2020 13:19:53 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue107 [212.227.15.183]) with ESMTPA (Nemesis) id 1MNtny-1knFoc4BgW-00OEzG; Fri, 16 Oct 2020 15:19:43 +0200 Date: Fri, 16 Oct 2020 15:19:42 +0200 From: Polytropon To: Ralf Mardorf Cc: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016151942.e01600b6.freebsd@edvax.de> In-Reply-To: <20201016063211.2f8b3a74@archlinux> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016063211.2f8b3a74@archlinux> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:TPJTvPJuWYFI711kuc44MXCS+sMV/12itL+vidA/AEHx5T647/+ Ga/jRZpeegBPNQ2njO/zVe8HfhV33hfrrOPYVvferLOLHSgTUHeK4gsfBAepJP8G/4F9+H0 fXgyKbLj1+g30AjEwRZHROQOzIJ+j9H+dSPRRDdHaxXFDMfb/vDQEvCvNp0K9oGNqLZUzNJ +9aq4hI1ELnO9RTCZ/vYg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:QYzuMiaALAA=:eSR/YHazJN3RzlOYeonjQb UNfnYZJrQTk8pPqDXH7B2eR6yjM39p3gKV961gVzqKIqMsBjjm506+gSWymXa7oXaGC6iPQ0R z5+YQI2mxm186O371cGJgTxnowtiwY4c0idq6+jW6YJaYkHP7CQEBzDz/4+d5i9bzuvixXnFs stVezGm7POfLxpjv026B9/ASVlUKExI2p07LAooI2eSUTWyAKjp8WMAqnY060iuyi+2jjsPKM yNs9X0oPmh8bQrPOMS/Qw5KlQW1WwhbdbC8Jep3C/HpJ6hPy5PtIYJK1RPwFj1GyMMl7zskKG g2WleDtVvrBPE2Pj+cmgTct7cKwfdjdJvV8kiR9gCl7/a778xzlNoLWb6kyTlLdLxd40F1FU/ MuQk+ycnHHaRwTza80m3dTvcP3V6zPCo635SA97ge6zZZ3dvE7Db2rvAipaJ4 X-Rspamd-Queue-Id: 4CCRZx6JYSz3SQN X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.17.24) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [-0.02 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-1.05)[-1.046]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.63)[-0.631]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.75)[-0.747]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.17.24:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.17.24:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:19:56 -0000 On Fri, 16 Oct 2020 06:32:11 +0200, Ralf Mardorf wrote: > On Thu, 15 Oct 2020 23:14:13 -0400, Kurt Hackenberg wrote: > >On 2020-10-15 23:05, Bob Proulx wrote: > > > >> Oh you are tormenting us now. :-) There are some subtle issues > >> here. > > > > > >Maybe a shell is the wrong tool. > > Exactly! Scripts are useful to handle tasks, such as dealing with > reasonable file names. There is a significant problem with this statement (even though I can understand its intention): At what point does a filename become "not reasonable"? Stupid people do stupid things. Stupidly programmed programs do stupid things to filenames, too. Scripts usually do not care. They typically (!) are not limited to a subset of valid filenames, they work on _all_ filenames. Just imagine you want to copy or delete a file, but the program in question complains that you cannot do it with _this_ file because its name is not reasonable... that would be a really strange situation... > A script should work around reasonable tricky > file names, but at some point bothering with really freakish file names > isn't worth the effort. Depends. If your scope involves processing 1000+ files delivered by your stupid coworkers, you will surely develop a script that fights all the freakish things you will encounter by iterating over those filenames. As I mentioned in my first reply, this is absolutely possible, but not _trivial_ anymore. In my opinion, the goal defines the amount of work you will put into it. > Actually file names should be compatible with > shell, if they are intended to be used with shell scripts. There is a problem. Filenames are subject to restrictions. The first level of restrictions is imposed by the filesystem. It defines a maximum length as well as reserved characters, such as "/" for the directory separator, and "." and ".." which are handled in a specific way. The second level of restrictions comes from the shell. It includes, but is not limited to, using " " (space) as the command and options separator, "-" as the options prefix, and may contain many more, such as "*" or "?". While all of them are valid within a filename, they probably _should_ not be in a filename. If a file should have a name valid on other filesystems which are not as generous as UFS, a third level of restrictions will apply, originating from the limitations of the foreign filesystem, and can even include "forbidden filenames" such as "COM1:". :-) > To some > extent we could use shell scripts, to write little programs, that > probably better should be written in a programming language. At some > extent a programming language is required, a shell script can't do the > job at all or at best it could do the job, but not with reasonable > effort. Fully correct, but also suffers from the lack of a definition of "reasonable" that works everywhere every time. :-) -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 13:23:45 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E0B0C435C9F for ; Fri, 16 Oct 2020 13:23:45 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.17.10]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRgN1r8Tz3Stl for ; Fri, 16 Oct 2020 13:23:43 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue108 [212.227.15.183]) with ESMTPA (Nemesis) id 1N3sVq-1kKZy715zE-00zjhU; Fri, 16 Oct 2020 15:23:39 +0200 Date: Fri, 16 Oct 2020 15:23:38 +0200 From: Polytropon To: Ralf Mardorf Cc: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016152338.168831c5.freebsd@edvax.de> In-Reply-To: <20201016113408.16d58d68@archlinux> References: <20201016113408.16d58d68@archlinux> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:qUH1OHKaBhTjYZUVKNTa4QX71QCzBojpfWYtMbkWCl04NMl7yFD M1i/jURVIgu1UryrJ2KwnGeK/0GQPFmjRPmFXkwicK3n/YeWGLZRajMHoGQ89nKdCAJtTO8 6cYpZ2R0jddyeO1eseG+FByjqVILtamm5yxkgwseR2ft1bki0kDEXxIki22U/RiXaar6pO+ peRyu6USySHpwLgAGTLnA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:D//Oc2klslQ=:EmeIPOclq7utEKfr6OBcRd kvX3QDzTrdfBbgXLFvYvlkaWbTzXs7KyrjYJoGKPQq1F70xRdJYv9Twt3L9r9pvv0Cyr9u84/ JV9c6wCPuL3N7SIHPSoxJ33UeoYInlY7iTSIbxdM7fvVFP/QSjN+EEBGO/6NjhZ5cK12ipmyY 58wbbWPC0025A2+aydOVVE2nclxtSd8phXygLaqaZ5KQIuu9m4N9TZ0UOrIKfB+CBsMGyABbt KTyp/SsWNl8YrAq15gblVV7h2K2irmKk22C3jSZhXdygsjZeDSIVaxv5AljPRT7482dKhDOfI XmlLrAM9gCSzn97iKpkjUOs6AwM2kYTbiF3at1ZVSq64a72xazyyg94uKHyV4Q99QHEse5aj3 JwWAdARmHtWGg3XE3X97rqLx86N8cq1ecGQ5RIEMkL374Jjag9opuv9pbWF06 X-Rspamd-Queue-Id: 4CCRgN1r8Tz3Stl X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.17.10) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [-0.03 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-1.04)[-1.045]; RCPT_COUNT_TWO(0.00)[2]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.63)[-0.632]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-0.75)[-0.751]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.17.10:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.17.10:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:23:45 -0000 On Fri, 16 Oct 2020 11:34:08 +0200, Ralf Mardorf wrote: > Imagine a file named > > - > > or > > -h > > or > > --help > > etc., then add the file name behind a command. > > Yes, you could use a workaround, such as adding a path. > > [rocketmouse@archlinux tmp]$ cat --help | head -1 > Usage: cat [OPTION]... [FILE]... > [rocketmouse@archlinux tmp]$ cat ./--help | head -1 > test For such files, using "--", the "stop processing command line options" directive, is quite useful: # cat -- --help | head -l This of course assumes that _after_ the offending filename, no further command line arguments will be supplied. > However, you easily could end up with a script containing more lines > that workaround offended conventions, than containing lines for what > actually should be done. That's right, a "benevolent script" will eventually contain many different kinds of defensive mechanisms, and will therefore be much more complex (and surely prone to breaking, if not done properly) than a script working on "normalized" filenames. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 13:33:43 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 54722436252 for ; Fri, 16 Oct 2020 13:33:43 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.17.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRtt3cHZz3TYH for ; Fri, 16 Oct 2020 13:33:42 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue106 [212.227.15.183]) with ESMTPA (Nemesis) id 1N2VKr-1kJhf142vv-013xeh; Fri, 16 Oct 2020 15:33:33 +0200 Date: Fri, 16 Oct 2020 15:33:32 +0200 From: Polytropon To: Manish Jain Cc: Ralf Mardorf , freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016153332.89f1418f.freebsd@edvax.de> In-Reply-To: References: <20201016113408.16d58d68@archlinux> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:RmIA1w10aZ0OhuEUXaEMhk9kM33Rw5XlfpjJS3lxFV3Ex38+hCP gk2BcjyHe2HP7cwyMfzWGEWBjg5CHIha2SztZBv2SLlK4dbWeDrd6SC/QN1dGRd/NBKZ6iI WRallCCJNrJaSr0RNUY45LnD44k1lePRSg+K+rAvXuiQBQvjVgw9UmxQ9vj7SnPrnGwELRI G20WguOshESgiPrXyMkUA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:1A6/Cfkmax4=:AThMPfbOGw/19xGBHWsrqX 9QZJxaPxoJO3du1twfHxYEYNEzHEZk+viCVI0lY1jgTAflJVOcJa4aC15KI3k2Pn9TU7618ym bEojG8YINsXy/2U0XLeQPRXrgOjUvjrfz2f+Jt5zGFIb/EPDRTFHwDkKbJCQ10ANY2thwaIdl NvdDYOc9VqO6AsQumBp1bYHw7XHJxri0RButG6HQeo+3E3wercXjWU19TJGRJdKZMFb6y6vUQ abpzC4sW0p7nNrhbnAdLg9C6OVOrvLo5UJVe0lp9FsUVwWj7mYJUeHvcxRIkUuAy4ELCGclvA 5BBEht68VXoJlj9SI9wdTI6gHNb2Jrid8YFyf/u8GOZXkvofnlmgZ0VBoAykz+HPUEAYQjmC3 Q8qwRLHx5VyJZojYhuxA34LRxE0+phH7BIsnkfNIJ+HDKt6x613CosZSpltmKFBgdma1lNFto tpm0dkRRaHefkXwqfwxloxiZrhR11AM= X-Rspamd-Queue-Id: 4CCRtt3cHZz3TYH X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.17.24) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [1.66 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; FREEMAIL_TO(0.00)[hotmail.com]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.43)[-0.432]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.01)[0.010]; NEURAL_HAM_LONG(-0.32)[-0.315]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.17.24:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.17.24:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:33:43 -0000 On Fri, 16 Oct 2020 15:55:59 +0530, Manish Jain wrote: > This is where I actually have an entirely different philosophy. When you > create a file with a leading - (or for that matter, weird characters > such as * anywhere in the filename), I think the filesystem driver (i.e. > the kernel) should throw a warning: "Do you really want a filename like > that ?" The kernel is not responsible here. It's the VFS driver and its interface to the UFS filesystem driver. Generally, there are only two (!) characters that need special attention in UFS: "/" with the meaning of directory separator, and NUL (the null byte) as the string terminator. Any other characters are valid. UFS simply interprets a few other characters as special, such as "." and "..". The shell might treat other characters in a specific way, such as "*" or "?", or "-" at the beginning of a string (which _could_ be a filename; see sh's "--" options processing terminator). > Actually, I would go one step ahead and have kernel drivers and users > agree on a Unix Portable File Naming Convention, which should debar > rotten file names in the first place to everyone except the root user > (and even he should get a warning on violations). You cannot. Stupid people do stupid things, and if you give them a computer, you cannot even estimate the level of stupid that can be emitted. Furthermore, stupid people write stupid programs, and those will then generate filenames with freakish names because some PHB claims "That's the rule! Obey it! Or else!" So any kind of consensus would be hard, you cannot for anyone, and in the end, it's just a suggestion that nobody really follows... Yes, I wish it would be different, but I'm old and grumpy. ;-) > A few examples of what the Convention should debar: > > - in the leading position Understandable - could be an option. > . in the trailing position Why? > * anywhere in the filename > | anywhere in the filename Add other shell-specific wildcards and operators, such as "?" and "!" and "&", and redirection, parentheses, brackets, braces... Depending on the shell in question, there could be a lot. > Anyway, Robert's problem I do not think relates to weird filenames as > far as I can see. Spaces in filenames is a common (and technically solved) problem. I had to deal with it a lot, as well as with "filenames from the stupid", that's why I'm honestly claiming they won't go away in the future. :-) -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 13:38:08 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id ED229436773 for ; Fri, 16 Oct 2020 13:38:08 +0000 (UTC) (envelope-from 4250.82.1d4c50003bde76e.7440523575860eb51cf7fe02d54884d5@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCRzz40JKz3V5j for ; Fri, 16 Oct 2020 13:38:07 +0000 (UTC) (envelope-from 4250.82.1d4c50003bde76e.7440523575860eb51cf7fe02d54884d5@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602855486; x=1605447486; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:cc:to:from:date:x-thread-info; bh=g3D3vjwxG/th23nKIY/6oaxyNk9jEHHSCLN5K9U3zBo=; b=wlyiukwoCHxEtvHIP9k+Nxppg5j+m3W/SvjQ/DHx60iqamPT/GH8Ik3RoNYOPaN7CdteJMyCzIS6RATvxK5lDyk16bIZUdJGM+el29X0Z9ZcmRxJ8SJHbUMWtQfLJbsgqorlDs5t6s9BSg0VjEgC2aFrHlgX0QEgq/4XCY/vgF8= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNiZGU3NmUuZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r1.us-east-2.aws.in.socketlabs.com (r1.us-east-2.aws.in.socketlabs.com [142.0.189.1]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 09:38:03 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r1.us-east-2.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 09:38:21 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTPvm-000KnO-9R; Fri, 16 Oct 2020 14:38:02 +0100 Date: Fri, 16 Oct 2020 14:38:02 +0100 From: Steve O'Hara-Smith To: Polytropon Cc: Ralf Mardorf , freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016143802.11156879863c4885fb3dd2e7@sohara.org> In-Reply-To: <20201016151942.e01600b6.freebsd@edvax.de> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016063211.2f8b3a74@archlinux> <20201016151942.e01600b6.freebsd@edvax.de> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCRzz40JKz3V5j X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=wlyiukwo; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003bde76e.7440523575860eb51cf7fe02d54884d5@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003bde76e.7440523575860eb51cf7fe02d54884d5@email-od.com X-Spamd-Result: default: False [-2.81 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-1.03)[-1.034]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[sohara.org]; NEURAL_HAM_LONG(-1.02)[-1.022]; TO_DN_SOME(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[email-od.com:+]; NEURAL_HAM_SHORT(-1.05)[-1.054]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003bde76e.7440523575860eb51cf7fe02d54884d5@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003bde76e.7440523575860eb51cf7fe02d54884d5@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:38:09 -0000 On Fri, 16 Oct 2020 15:19:42 +0200 Polytropon wrote: > Fully correct, but also suffers from the lack of a definition > of "reasonable" that works everywhere every time. :-) POSIX portable filenames -they're pretty restrictive though. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 13:44:44 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4363E436A65 for ; Fri, 16 Oct 2020 13:44:44 +0000 (UTC) (envelope-from 4250.82.1d4c50003be09c8.77bb022725b23e6358b7d11dbe2e9885@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCS7b4ChLz3VX0 for ; Fri, 16 Oct 2020 13:44:43 +0000 (UTC) (envelope-from 4250.82.1d4c50003be09c8.77bb022725b23e6358b7d11dbe2e9885@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602855882; x=1605447882; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:cc:to:from:date:x-thread-info; bh=RQQNbpRLGmk8Miv8xtqmpTqt7MASe8q4AwOm5Kdi/Rg=; b=iGw7ichBfY3hptHC3RGeT7+UjlBQV5ZVqdrNy5Ys1gtXxRGsQZg7Sew9/hocR7p0Lfxt6AwFM8kDa8cdMfyy1Un3By6pTDC7CXovp7DQrAVE+1Mw0FIK48OsgWt9ZqAgQrORDnnsvuqvB6qVHB5MQ3YaNXdTcw6zMWubY3EHU5w= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNiZTA5YzguZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r2.us-east-1.aws.in.socketlabs.com (r2.us-east-1.aws.in.socketlabs.com [142.0.191.2]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 09:44:36 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r2.us-east-1.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 09:45:01 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTQ28-000Kuj-N5; Fri, 16 Oct 2020 14:44:36 +0100 Date: Fri, 16 Oct 2020 14:44:36 +0100 From: Steve O'Hara-Smith To: freebsd-questions@freebsd.org Cc: Polytropon Subject: Re: sh scripting question Message-Id: <20201016144436.9a22761fe90ea32a640023ab@sohara.org> In-Reply-To: <20201016153332.89f1418f.freebsd@edvax.de> References: <20201016113408.16d58d68@archlinux> <20201016153332.89f1418f.freebsd@edvax.de> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCS7b4ChLz3VX0 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=iGw7ichB; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003be09c8.77bb022725b23e6358b7d11dbe2e9885@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003be09c8.77bb022725b23e6358b7d11dbe2e9885@email-od.com X-Spamd-Result: default: False [-2.90 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.04)[-1.038]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20:c]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[sohara.org]; NEURAL_HAM_LONG(-1.02)[-1.016]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[email-od.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; NEURAL_HAM_SHORT(-1.14)[-1.142]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003be09c8.77bb022725b23e6358b7d11dbe2e9885@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003be09c8.77bb022725b23e6358b7d11dbe2e9885@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:44:44 -0000 On Fri, 16 Oct 2020 15:33:32 +0200 Polytropon wrote: > UFS simply interprets a few other characters as special, such as "." and > "..". They're just the first two directory entries placed when the directory is created, the only special treatment is that they can't be unlinked and that they're hard links to directories. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 13:53:48 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 58F6B436EE5 for ; Fri, 16 Oct 2020 13:53:48 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.135]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCSL31LMrz3WGN for ; Fri, 16 Oct 2020 13:53:46 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.3.6]) by mrelayeu.kundenserver.de (mreue012 [212.227.15.167]) with ESMTPA (Nemesis) id 1MoeU5-1k4nf943uz-00p0fz; Fri, 16 Oct 2020 15:53:39 +0200 Date: Fri, 16 Oct 2020 15:53:38 +0200 From: Polytropon To: "Steve O'Hara-Smith" Cc: Ralf Mardorf , freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016155338.4f88563f.freebsd@edvax.de> In-Reply-To: <20201016143802.11156879863c4885fb3dd2e7@sohara.org> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016063211.2f8b3a74@archlinux> <20201016151942.e01600b6.freebsd@edvax.de> <20201016143802.11156879863c4885fb3dd2e7@sohara.org> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K1:ACjsIMa35lK1EleokI///WizyGcmW5+4XWEGzysKQdfHSPid5lw hqfouZuVdbnMr5kSIkdAHwhMuekkW5zDF8sWxcz6XgjjSQNEtibUpvT5xMIDroBitW5Mbeb 1NXsYqAytN6Ykve1IOuIM7Xc2mKgD1Y97XJGOyHcm/akegmmtD40v3y+yceN17Jiipo1vci PsEVHg+fMwJrGOyMa/uIA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:q2drmLQR1Xs=:rg5VS33tumqfTKOcupwSua WCJ5hso3m6RfrwP847uQ041kNX3jzf8ENcALE8Jy3z1Yf5a3pDWoc99Y96ePUCWS+u0c84N4I sltREDPluCsZsjrXdX43U85sOPjpEksxt/L3ZfPmwYNF5nM/Vma8hMBvo0C2IfiEOte3SMBDJ CtMUy88ClQweHrFTrEVJHNZ9LKx7LacmM6TMJ4ORI2NKGy4MVSPUvAptp7tW5WOEwS8rUAUB9 m4/cXInFBOS3RjGmudEUxA6kjkrGdYplF07O87SA5zpBglkc3EVjtdwqGeEec4R0EmcsssPNP w6T1SIEgmoyLJN9bL3BRcTvL9k3wtQTWLbZiBsvfmhRio6Yw33uBx6jKQkEOtSrqOzntUNf25 1BLcqv9xBlTCkTLV0EbXobqrRQP5Eva2jqdRk385tEMvAB5JgSQGtKZdQd9+T X-Rspamd-Queue-Id: 4CCSL31LMrz3WGN X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd@edvax.de has no SPF policy when checking 212.227.126.135) smtp.mailfrom=freebsd@edvax.de X-Spamd-Result: default: False [0.84 / 15.00]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; NEURAL_HAM_SHORT(-0.04)[-0.039]; RECEIVED_SPAMHAUS_PBL(0.00)[94.222.3.6:received]; RCVD_TLS_LAST(0.00)[]; R_DKIM_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.76)[-0.756]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_HAM_LONG(-0.76)[-0.763]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MID_CONTAINS_FROM(1.00)[]; RCVD_IN_DNSWL_NONE(0.00)[212.227.126.135:from]; R_SPF_NA(0.00)[no SPF record]; RWL_MAILSPIKE_POSSIBLE(0.00)[212.227.126.135:from]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 13:53:48 -0000 On Fri, 16 Oct 2020 14:38:02 +0100, Steve O'Hara-Smith wrote: > On Fri, 16 Oct 2020 15:19:42 +0200 > Polytropon wrote: > > > Fully correct, but also suffers from the lack of a definition > > of "reasonable" that works everywhere every time. :-) > > POSIX portable filenames -they're pretty restrictive though. Yes, true - BUT: Programs don't have to be POSIX compliant, and even if they were, nothing stops users from using an external tool to rename filenames from a POSIX-portable one to something that isn't portable - or reasonable - anymore... "But I like the emojis in the names of my business report files!" "We use stars in filenames to show how important they are." "the number of dashes before the actual name indicate the revision level of the file." --- Expenses in € (10|2020) ☺ *** Bob,Berlin – Copy (2) .doc Real people and their work results... :-) -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... From owner-freebsd-questions@freebsd.org Fri Oct 16 14:08:09 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C8B8C4373C8 for ; Fri, 16 Oct 2020 14:08:09 +0000 (UTC) (envelope-from 4250.82.1d4c50003be904f.a471a9c5b21b4e028a49472d6a5039db@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCSfc5CLBz3X54 for ; Fri, 16 Oct 2020 14:08:08 +0000 (UTC) (envelope-from 4250.82.1d4c50003be904f.a471a9c5b21b4e028a49472d6a5039db@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602857287; x=1605449287; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:cc:to:from:date:x-thread-info; bh=KgGN09Qjv3Rufqlfh+VPKi2ZFbtx6xNphbr6fQgjBFQ=; b=BgzOwoboTWjmQO6i6RnaloxFkJHA7Slc9x5jWc+c9u9nZgrUMMVk9JHEPr8O+8zWez4UmtiVzdP+KyMPlgj2s68bNSR1rN4gI47QGRnpZKOXK0cPLWJEYIu+BR5t/teNMUJowDEXFRBD+z76QeDHzEBECXKi+sMsl8ozG4Sc/KI= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNiZTkwNGYuZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r2.sg.in.socketlabs.com (r2.sg.in.socketlabs.com [142.0.179.12]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 10:07:57 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r2.sg.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 10:07:58 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTQOi-000LP4-SV; Fri, 16 Oct 2020 15:07:56 +0100 Date: Fri, 16 Oct 2020 15:07:56 +0100 From: Steve O'Hara-Smith To: Polytropon Cc: Ralf Mardorf , freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-Id: <20201016150756.f2ce6613a4eb9d722df7ffef@sohara.org> In-Reply-To: <20201016155338.4f88563f.freebsd@edvax.de> References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016063211.2f8b3a74@archlinux> <20201016151942.e01600b6.freebsd@edvax.de> <20201016143802.11156879863c4885fb3dd2e7@sohara.org> <20201016155338.4f88563f.freebsd@edvax.de> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCSfc5CLBz3X54 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=BgzOwobo; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003be904f.a471a9c5b21b4e028a49472d6a5039db@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003be904f.a471a9c5b21b4e028a49472d6a5039db@email-od.com X-Spamd-Result: default: False [-2.81 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-1.03)[-1.031]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[sohara.org]; NEURAL_HAM_LONG(-1.02)[-1.022]; TO_DN_SOME(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[email-od.com:+]; NEURAL_HAM_SHORT(-1.06)[-1.057]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003be904f.a471a9c5b21b4e028a49472d6a5039db@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003be904f.a471a9c5b21b4e028a49472d6a5039db@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 14:08:09 -0000 On Fri, 16 Oct 2020 15:53:38 +0200 Polytropon wrote: > On Fri, 16 Oct 2020 14:38:02 +0100, Steve O'Hara-Smith wrote: > > On Fri, 16 Oct 2020 15:19:42 +0200 > > Polytropon wrote: > > > > > Fully correct, but also suffers from the lack of a definition > > > of "reasonable" that works everywhere every time. :-) > > > > POSIX portable filenames -they're pretty restrictive though. > > Yes, true - BUT: Programs don't have to be POSIX compliant, Oh sure, nobody uses it but it is the definition you asked for, useless as it is :) > "But I like the emojis in the names of my business report files!" Have you ever seen an NFS exported common work area directory used by an international team dumping files in there with names in whatever encoding their PCs are set up for ? It doesn't take long before nothing can render a sane looking file listing. > Real people and their work results... :-) Yep no test group can ever find more creative ways of screwing you up than users. -- Steve O'Hara-Smith | Directable Mirror Arrays C:\>WIN | A better way to focus the sun The computer obeys and wins. | licences available see You lose and Bill collects. | http://www.sohara.org/ From owner-freebsd-questions@freebsd.org Fri Oct 16 14:55:34 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4714D43878D for ; Fri, 16 Oct 2020 14:55:34 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) Received: from EUR03-VE1-obe.outbound.protection.outlook.com (mail-oln040092072106.outbound.protection.outlook.com [40.92.72.106]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "GlobalSign Organization Validation CA - SHA256 - G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCTjK10kQz3Ysv for ; Fri, 16 Oct 2020 14:55:32 +0000 (UTC) (envelope-from bourne.identity@hotmail.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RraAwiTVMsX9w9I5mUyLRoIU9DTZFSLXVCXUNuUnKIN71+I3wVTg7t11PgPx8PL7q/h8pKz1zT1b1hfS5vpNk0QwvkYLiXyb5eKlRf6WYRvqpZTl/FvAzXAYSlvMYVay20Go2dtqSRsjcE1scT3XIqvZ2IZd3OUQYSOCD7btlkXzrt5FsXaBWvaoOzsJEIcs8deFLCepoOgPaH0v8O9zkFwMZm2KSsskqkeNA54aZKBIr2EG0wg34ByIi7m3XH/CeHMbfoHYWLxuLByvheyrL1QDifdSlPVOJbB1RnBp9gTM8z3/bRskdZzukcNDGB5OBHb1PnqxIr2KhDghipm6Kw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=S4Dc6L+8/x4d935VAlcg3Ts/pgVB1b7jkBLWZtyuMRE=; b=KlxNqHEjYSXNgHD/2DuqXt1fQFLo67cTifqFispZ4pmRHk2bB12YRwCiYRLXvkYQtuaRpfKtjVLutrDrnfXQqjSAo7KeB2VrUk/lSl8gNQWgr4sUUE+RF7DTsqSkaShcEfWCzf3emeqjy1gJXH/P6IXphJkAjdbzie371SZUPs7yKfAfQe9S8wLimmz2kUsuuMKQLMbPaDtqKi2ciMo5GFX7i1ezg3rP3jkGkAOa6R2Fh3iaK8jyE+Vw7cmj5tEn02oCMsV0OsFG06Vc+0Xtavl0RJp8W7vwFWPcMTU6Zou5/hRbUBpgUG3CyFc7VtAPNDdnsqp82zs1MHvXaG3GjA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=S4Dc6L+8/x4d935VAlcg3Ts/pgVB1b7jkBLWZtyuMRE=; b=e5ZeoofiEipf/9pGiKZ1EOWQDYZUtEvW1YXerz7mgqPW7nhA7AXNNpLeFcOh0kuD0Tz+lBXsrV/xujOwTjkaFcgl181gOWqnRPzEBWtP3HD2L+upeRXc78jWtfafnOuP+iTLACPt7ogMXVPUmfShCf2yUM3X18mR2RWKm0YjYyKYJTG/d3nUpz9zwAotBtPXZyW9eWJTFyYPmFpnN9D8dWcAgCK02aJXKF3VPG9BRFLYLfvjJGH3QPbuOTStKqOVwStsq9LgyvwPDxcfIUz2amyV9KhN+wl+C8qPGMEADTpV8R/so9e/w8Cx0gLsP261Efx3u7vZumqvqi7iuHTogQ== Received: from VE1EUR03FT055.eop-EUR03.prod.protection.outlook.com (2a01:111:e400:7e09::51) by VE1EUR03HT227.eop-EUR03.prod.protection.outlook.com (2a01:111:e400:7e09::180) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3455.23; Fri, 16 Oct 2020 14:40:28 +0000 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com (2a01:111:e400:7e09::41) by VE1EUR03FT055.mail.protection.outlook.com (2a01:111:e400:7e09::414) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 14:40:28 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:7312733FA6AB83660775B93A4957A3E9C0465649F0447BBA85B5082FFCCC51FD; UpperCasedChecksum:91C08A6731F995D8BC07E099A653760D3A9219C96CB4F1D0E6954961628D501A; SizeAsReceived:8782; Count:47 Received: from DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f]) by DB8PR06MB6442.eurprd06.prod.outlook.com ([fe80::5822:2d5d:a176:574f%9]) with mapi id 15.20.3477.023; Fri, 16 Oct 2020 14:40:28 +0000 Subject: Re: sh scripting question To: freebsd-questions@freebsd.org References: <24456.60388.135834.43951@jerusalem.litteratus.org> <20201015204226099763897@bob.proulx.com> <20201016063211.2f8b3a74@archlinux> <20201016151942.e01600b6.freebsd@edvax.de> From: Manish Jain Message-ID: Date: Fri, 16 Oct 2020 20:10:20 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 In-Reply-To: <20201016151942.e01600b6.freebsd@edvax.de> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit X-TMN: [eV0K6Lb5eeaEUxN4BIMj434KS81sMIoistcKXarZGLM=] X-ClientProxiedBy: BM1PR0101CA0068.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:19::30) To DB8PR06MB6442.eurprd06.prod.outlook.com (2603:10a6:10:126::7) X-Microsoft-Original-Message-ID: <19d056f5-ada8-b61f-ada6-2a5684124591@hotmail.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [192.168.1.2] (103.195.202.206) by BM1PR0101CA0068.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:19::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 14:40:27 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: ebe11ef0-ccbc-4505-e82e-08d871e16cbc X-MS-TrafficTypeDiagnostic: VE1EUR03HT227: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: IeqOOBtIqkVy83s7s3/mGM7wn6y2LSlaYyT/o/oeTEJObWCgdSjwXVnfpSUp6rFXKOqLlmbimg8Jxwkyx5Zf0meLedxYYNOzV4d92N10WtYpsqKGByS1l1/34h2jE6RnDgQRj5pBfOX2iLWaCVdI8pAzAdqc4fiNQgI9GvU4shn6n2F3KzPiL2z9iToz1saj0K8YF4xSQnK2RaBW7kgGTw== X-MS-Exchange-AntiSpam-MessageData: V3p2ISo3n6nSTIfNznb8YbWjaCTH7dZRI1CJrElK3FhlGRJDA44L4Y1VTtnF7evFQBvRqelu95eV0mH3jjBv7yNcMrXfXs9Dl8tzhNB/X3RD31rolcm1mIhMhvQlE4ct44+Cx0eK2reeZPW9o8RiRA== X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-Network-Message-Id: ebe11ef0-ccbc-4505-e82e-08d871e16cbc X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 14:40:28.6451 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: VE1EUR03FT055.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1EUR03HT227 X-Rspamd-Queue-Id: 4CCTjK10kQz3Ysv X-Spamd-Bar: ++++++++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hotmail.com header.s=selector1 header.b=e5Zeoofi; dmarc=pass (policy=none) header.from=hotmail.com; spf=pass (mx1.freebsd.org: domain of bourne.identity@hotmail.com designates 40.92.72.106 as permitted sender) smtp.mailfrom=bourne.identity@hotmail.com X-Spamd-Result: default: False [8.96 / 15.00]; FREEMAIL_FROM(0.00)[hotmail.com]; R_SPF_ALLOW(0.00)[+ip4:40.92.0.0/15]; TO_DN_NONE(0.00)[]; DKIM_TRACE(0.00)[hotmail.com:+]; DMARC_POLICY_ALLOW(0.00)[hotmail.com,none]; NEURAL_HAM_SHORT(-0.34)[-0.342]; RCVD_IN_DNSWL_LOW(-0.10)[40.92.72.106:from]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[hotmail.com]; ASN(0.00)[asn:8075, ipnet:40.80.0.0/12, country:US]; FORGED_MUA_THUNDERBIRD_MSGID_UNKNOWN(2.50)[]; ARC_ALLOW(0.00)[microsoft.com:s=arcselector9901:i=1]; DWL_DNSWL_NONE(0.00)[hotmail.com:dkim]; RECEIVED_SPAMHAUS_XBL(5.00)[103.195.202.206:received]; R_DKIM_ALLOW(0.00)[hotmail.com:s=selector1]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_MEDIUM(0.92)[0.920]; RCPT_COUNT_ONE(0.00)[1]; BAD_REP_POLICIES(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; NEURAL_SPAM_LONG(0.98)[0.979]; RECEIVED_SPAMHAUS_PBL(0.00)[103.195.202.206:received]; RWL_MAILSPIKE_POSSIBLE(0.00)[40.92.72.106:from]; GREYLIST(0.00)[pass,body]; MAILMAN_DEST(0.00)[freebsd-questions] X-Spam: Yes X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 14:55:34 -0000 On 2020-10-16 18:49, Polytropon wrote: > Stupid people do stupid things. Stupidly programmed programs > do stupid things to filenames, too. Scripts usually do not > care. They typically (!) are not limited to a subset of valid > filenames, they work on_all_ filenames. The best way to let stupid people realize that their file names are stupid is to let their shell scripts fly off the handle. Regards, Manish Jain From owner-freebsd-questions@freebsd.org Fri Oct 16 17:50:22 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 422DE43BD5B for ; Fri, 16 Oct 2020 17:50:22 +0000 (UTC) (envelope-from doug@fledge.watson.org) Received: from cyrus.watson.org (cyrus.watson.org [204.107.128.30]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCYb13YD2z40gM for ; Fri, 16 Oct 2020 17:50:21 +0000 (UTC) (envelope-from doug@fledge.watson.org) Received: from fledge.watson.org (fledge.watson.org [198.74.231.63]) by cyrus.watson.org (Postfix) with ESMTPS id 321379021C; Fri, 16 Oct 2020 17:50:20 +0000 (UTC) Received: from fledge.watson.org (doug@localhost [127.0.0.1]) by fledge.watson.org (8.16.1/8.16.1) with ESMTPS id 09GHoKbV011688 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Fri, 16 Oct 2020 17:50:20 GMT (envelope-from doug@fledge.watson.org) Received: from localhost (doug@localhost) by fledge.watson.org (8.16.1/8.16.1/Submit) with ESMTP id 09GHoJIR011685; Fri, 16 Oct 2020 17:50:19 GMT (envelope-from doug@fledge.watson.org) Date: Fri, 16 Oct 2020 17:50:19 +0000 (UTC) From: doug Reply-To: doug@safeport.com To: Jon Schneider cc: freebsd-questions@freebsd.org, Twingly Customer Support Subject: Re: FreeBSD using swap even though there's a lot of free memory In-Reply-To: Message-ID: References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> User-Agent: Alpine 2.21.9999 (BSF 287 2018-06-16) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Rspamd-Queue-Id: 4CCYb13YD2z40gM X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of doug@fledge.watson.org has no SPF policy when checking 204.107.128.30) smtp.mailfrom=doug@fledge.watson.org X-Spamd-Result: default: False [-0.48 / 15.00]; HAS_REPLYTO(0.00)[doug@safeport.com]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.18)[-0.180]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_DN_SOME(0.00)[]; NEURAL_HAM_LONG(-0.77)[-0.767]; MIME_GOOD(-0.10)[text/plain]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; DMARC_NA(0.00)[watson.org]; AUTH_NA(1.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.53)[-0.529]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:11288, ipnet:204.107.128.0/24, country:US]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 17:50:22 -0000 On Thu, 15 Oct 2020, Jon Schneider wrote: > top -w -oswap > > seems to report the right thing. Would be interesting if it's _not_ MySQL. > > Jon > > On 15/10/2020 15:23, Twingly Customer Support wrote: >> Hi, >> >> We have a server running FreeBSD 12.1-RELEASE-p10. We currently have a >> problem where FreeBSD starting to swap when running ZFS scrub, even though >> we have ~70G of free memory. >> This did not happen before when running FreeBSD 11.3 for example. It >> started happening at approximately the time we upgraded from >> 12.1-RELEASE-p5 to 12.1-RELEASE-p6, but if the upgrade is the cause of the >> problem is unclear, though FreeBSD never swapped for us before that. >> "Laundry" memory was not something we saw before either, it started to >> appear at the same time as FreeBSD started swapping. >> >> Eventually, after scrubbing a few times, the swap becomes full and we start >> seeing "swap_pager_getswapspace(24): failed" etc. in dmesg. >> This is the memory usage a while after scrubbing, note the values for >> Mem/Free and Swap: >> >> ``` >> % top | head -n 7 >> last pid: 8112; load averages: 1.82, 1.77, 1.73 up 6+01:37:42 >> 10:53:48 >> 35 processes: 1 running, 34 sleeping >> CPU: 4.9% user, 0.0% nice, 4.2% system, 0.2% interrupt, 90.7% idle >> Mem: 110G Active, 27G Inact, 5413M Laundry, 39G Wired, 68G Free >> ARC: 34G Total, 28G MFU, 4101M MRU, 53M Anon, 1317M Header, 225M Other >> 30G Compressed, 53G Uncompressed, 1.77:1 Ratio >> Swap: 8192M Total, 6434M Used, 1757M Free, 78% Inuse >> ``` >> >> We are running MySQL, which has been configured to use ~50% of the total >> amount memory (using innodb_buffer_pool_size=127748M) >> ZFS ARC has been configured to use 25% of the total memory (using >> vfs.zfs.arc_max="63874M") >> >> We have tried raising both vfs.zfs.arc_max and innodb_buffer_pool_size, but >> this did not make any change to the total memory usage, the free memory >> stays at around 70G and FreeBSD still started swapping. >> It's as if the memory is capped at around 180G for some reason. >> >> Are there any configuration values that could cause FreeBSD to swap even >> though there's free memory? Are there any config values one could try to >> change in order to get FreeBSD to use the remaining ~70G of free memory >> instead of swapping? >> >> Let me know if there's any more details you want me to provide and I'll >> attach those. >> >> Thanks! >> >> // Mattias I see similar things. The Jails in question are 11.1. The systems updated to 12.1 do not display this behavior. This 11.1 system runs 5 jails. Swapinfo is shown below: Device 1K-blocks Used Avail Capacity /dev/aacd0p3 4194304 1776000 2418304 42% These numbers are developed from top on the base system [ 0 50861 ] root [ 20 281903 ] camden squirellmail/roundcube/postfix/mysql [ 21 322759 ] bassharbor wordpress/php56 [ 19 343522 ] monhegan wordpress/php56 [ 18 369139 ] newharbor apache24/sendmail [ 17 587332 ] pemaquid wordpress/php74 Jails: 1904655 total: 1955516 I read somewhere that the virtual memory system pre-pages modified pages as a just-in-case measure. If this is correct, 12.1 does not do this on a non-paging system. The system shown above uses about 10% swapspace after a reboot and works its way to the 42% shown above in a day or so. From owner-freebsd-questions@freebsd.org Fri Oct 16 17:53:10 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B62F343BFB2 for ; Fri, 16 Oct 2020 17:53:10 +0000 (UTC) (envelope-from johnl@iecc.com) Received: from gal.iecc.com (gal.iecc.com [IPv6:2001:470:1f07:1126:0:43:6f73:7461]) (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-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "gal.iecc.com", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCYfF62Pwz40td for ; Fri, 16 Oct 2020 17:53:09 +0000 (UTC) (envelope-from johnl@iecc.com) Received: (qmail 11931 invoked from network); 16 Oct 2020 17:53:03 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=iecc.com; h=date:message-id:from:to:cc:subject:in-reply-to:mime-version:content-type:content-transfer-encoding; s=2e99.5f89ddff.k2010; bh=VkV/5JkJSnGOgXjux3nJCS4ovM8SYQVt8lKwDgyqQhc=; b=TzUSE7ly+k8Y5dnUd+FcyUj/LC2F3MWDnt/CGhz8Kc6KW96onNqeHmhG8VdNEWFCY7IZWIMFWYkKnH6QSM33L4tpd2JEqYTf5rpMdwS0Yc5Mlow+n6DzhEwuC2net8zBtGbuureaYksMVD4cVbSKIw0Vre96E3nKn1HGgUL9jkNTzC/ETgmPNUCpAdHZmrXp/I25AbHocJkTfVuhA0KW/TB4Evifcm/pnnhvVAxpduDTw1OOGqaUO15HGpxz2BPLYwhSc8JA9U/mn5yCfGUIS+sa7W2Get/0J4F+RkvRIUGpkQKK7bCMO81FsjfRgVfsGMFXEXQ2XMRfBcGtyUfCHw== Received: from ary.qy ([IPv6:2001:470:1f07:1126::78:696d:6170]) by imap.iecc.com ([IPv6:2001:470:1f07:1126::78:696d:6170]) with ESMTPS (TLS1.2 ECDHE-RSA AES-256-GCM AEAD) via TCP6; 16 Oct 2020 17:53:03 -0000 Received: by ary.qy (Postfix, from userid 501) id CFDB2238515F; Fri, 16 Oct 2020 13:53:02 -0400 (EDT) Date: 16 Oct 2020 13:53:02 -0400 Message-Id: <20201016175302.CFDB2238515F@ary.qy> From: "John Levine" To: freebsd-questions@freebsd.org Cc: vrwmiller@gmail.com Subject: Re: sh scripting question In-Reply-To: Organization: Taughannock Networks X-Headerized: yes Mime-Version: 1.0 Content-type: text/plain; charset=utf-8 Content-transfer-encoding: 8bit X-Rspamd-Queue-Id: 4CCYfF62Pwz40td X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=iecc.com header.s=2e99.5f89ddff.k2010 header.b=TzUSE7ly; dmarc=pass (policy=none) header.from=iecc.com; spf=pass (mx1.freebsd.org: domain of johnl@iecc.com designates 2001:470:1f07:1126:0:43:6f73:7461 as permitted sender) smtp.mailfrom=johnl@iecc.com X-Spamd-Result: default: False [-5.15 / 15.00]; RCVD_TLS_ALL(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[iecc.com:s=2e99.5f89ddff.k2010]; NEURAL_HAM_MEDIUM(-1.01)[-1.013]; FROM_HAS_DN(0.00)[]; DWL_DNSWL_MED(-2.00)[iecc.com:dkim]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip6:2001:470:1f07:1126::/64]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.004]; HAS_ORG_HEADER(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[iecc.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[iecc.com,none]; NEURAL_HAM_SHORT(-0.63)[-0.631]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:6939, ipnet:2001:470::/32, country:US]; FREEMAIL_CC(0.00)[gmail.com]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 17:53:10 -0000 In article you write: >On Thu, Oct 15, 2020 at 8:40 PM Robert Huff wrote: >> I have a file ("files.list") with a list of filenames, similar to >> >> /path A/path B/FreeBSD is great.txt >> >> (note the embedded spaces) This is the sensible answer. Messing with IFS is very fragile. >$ while read line; do >> echo $line >> done < f.in >/path A/path B/FreeBSD is great.txt >/path T/path Q/FreeBSD rocks.txt The "read" command can set more than one variable so while read a b c do ... done < files.list will set $a to the first word on each line, $b to the second, $c to the rest of the line, which looks like what you wanted to do here. From owner-freebsd-questions@freebsd.org Fri Oct 16 17:54:24 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id AA6E443C22B for ; Fri, 16 Oct 2020 17:54:24 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from slave.jschneider.net (slave.jschneider.net [46.235.226.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCYgg6nk5z41M5 for ; Fri, 16 Oct 2020 17:54:23 +0000 (UTC) (envelope-from freebsd@jschneider.net) X-Disposition: Mostly harlmess; Fri, 16 Oct 2020 18:54:08 +0100 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: Jon Schneider Mime-Version: 1.0 (1.0) Subject: Re: FreeBSD using swap even though there's a lot of free memory Message-Id: <05399132-C7A7-4B96-B6E4-D469CCDC70D5@jschneider.net> Date: Fri, 16 Oct 2020 18:54:06 +0100 Cc: freebsd-questions@freebsd.org, Twingly Customer Support To: doug@safeport.com X-Mailer: iPad Mail (18A393) X-Rspamd-Queue-Id: 4CCYgg6nk5z41M5 X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of freebsd@jschneider.net designates 46.235.226.89 as permitted sender) smtp.mailfrom=freebsd@jschneider.net X-Spamd-Result: default: False [-1.73 / 15.00]; FAKE_REPLY(1.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.99)[-0.991]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:46.235.226.89]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[jschneider.net]; NEURAL_HAM_LONG(-0.99)[-0.987]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.96)[-0.955]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:44684, ipnet:46.235.224.0/21, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 17:54:24 -0000 =EF=BB=BFSunOS 4 used to (speculatively) page stuff out. Probably just indic= ates relatively unused pages. Jon > On 16 Oct 2020, at 18:50, doug wrote: >=20 > =EF=BB=BF >=20 >> On Thu, 15 Oct 2020, Jon Schneider wrote: >> top -w -oswap >> seems to report the right thing. Would be interesting if it's _not_ MySQL= . >> Jon >>> On 15/10/2020 15:23, Twingly Customer Support wrote: >>> Hi, >>> We have a server running FreeBSD 12.1-RELEASE-p10. We currently have a p= roblem where FreeBSD starting to swap when running ZFS scrub, even though we= have ~70G of free memory. >>> This did not happen before when running FreeBSD 11.3 for example. It sta= rted happening at approximately the time we upgraded from 12.1-RELEASE-p5 to= 12.1-RELEASE-p6, but if the upgrade is the cause of the problem is unclear,= though FreeBSD never swapped for us before that. "Laundry" memory was not s= omething we saw before either, it started to appear at the same time as Free= BSD started swapping. >>> Eventually, after scrubbing a few times, the swap becomes full and we st= art seeing "swap_pager_getswapspace(24): failed" etc. in dmesg. >>> This is the memory usage a while after scrubbing, note the values for Me= m/Free and Swap: >>> ``` >>> % top | head -n 7 >>> last pid: 8112; load averages: 1.82, 1.77, 1.73 up 6+01:37:42 10:5= 3:48 >>> 35 processes: 1 running, 34 sleeping >>> CPU: 4.9% user, 0.0% nice, 4.2% system, 0.2% interrupt, 90.7% idle >>> Mem: 110G Active, 27G Inact, 5413M Laundry, 39G Wired, 68G Free >>> ARC: 34G Total, 28G MFU, 4101M MRU, 53M Anon, 1317M Header, 225M Other >>> 30G Compressed, 53G Uncompressed, 1.77:1 Ratio >>> Swap: 8192M Total, 6434M Used, 1757M Free, 78% Inuse >>> ``` >>> We are running MySQL, which has been configured to use ~50% of the total= amount memory (using innodb_buffer_pool_size=3D127748M) >>> ZFS ARC has been configured to use 25% of the total memory (using vfs.zf= s.arc_max=3D"63874M") >>> We have tried raising both vfs.zfs.arc_max and innodb_buffer_pool_size, b= ut this did not make any change to the total memory usage, the free memory s= tays at around 70G and FreeBSD still started swapping. >>> It's as if the memory is capped at around 180G for some reason. >>> Are there any configuration values that could cause FreeBSD to swap even= though there's free memory? Are there any config values one could try to ch= ange in order to get FreeBSD to use the remaining ~70G of free memory instea= d of swapping? >>> Let me know if there's any more details you want me to provide and I'll a= ttach those. >>> Thanks! >>> // Mattias >=20 > I see similar things. The Jails in question are 11.1. The systems updated t= o 12.1 do not display this behavior. This 11.1 system runs 5 jails. Swapinfo= is shown below: >=20 > Device 1K-blocks Used Avail Capacity > /dev/aacd0p3 4194304 1776000 2418304 42% >=20 > These numbers are developed from top on the base system >=20 > [ 0 50861 ] root > [ 20 281903 ] camden squirellmail/roundcube/postfix/mysql > [ 21 322759 ] bassharbor wordpress/php56 > [ 19 343522 ] monhegan wordpress/php56 > [ 18 369139 ] newharbor apache24/sendmail > [ 17 587332 ] pemaquid wordpress/php74 >=20 > Jails: 1904655 > total: 1955516 >=20 > I read somewhere that the virtual memory system pre-pages modified pages a= s a just-in-case measure. If this is correct, 12.1 does not do this on a non= -paging system. The system shown above uses about 10% swapspace after a rebo= ot and works its way to the 42% shown above in a day or so. From owner-freebsd-questions@freebsd.org Fri Oct 16 18:07:42 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 2AE3343C728 for ; Fri, 16 Oct 2020 18:07:42 +0000 (UTC) (envelope-from freebsd@jschneider.net) Received: from slave.jschneider.net (slave.jschneider.net [46.235.226.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCYz14Hkyz41tZ for ; Fri, 16 Oct 2020 18:07:41 +0000 (UTC) (envelope-from freebsd@jschneider.net) X-Disposition: Mostly harlmess; Fri, 16 Oct 2020 19:07:38 +0100 From: Jon Schneider Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.7\)) Subject: Re: sh scripting question Message-Id: <69FD7F52-B1D9-4540-9379-CD3122BEDBB6@jschneider.net> Date: Fri, 16 Oct 2020 19:07:41 +0100 Cc: Ralf Mardorf , freebsd-questions@freebsd.org To: Polytropon X-Mailer: Apple Mail (2.3445.9.7) X-Rspamd-Queue-Id: 4CCYz14Hkyz41tZ X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of freebsd@jschneider.net designates 46.235.226.89 as permitted sender) smtp.mailfrom=freebsd@jschneider.net X-Spamd-Result: default: False [-1.73 / 15.00]; FAKE_REPLY(1.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.99)[-0.993]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:46.235.226.89]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[jschneider.net]; NEURAL_HAM_LONG(-0.99)[-0.987]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.95)[-0.948]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:44684, ipnet:46.235.224.0/21, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 18:07:42 -0000 There=E2=80=99s a YouTube publisher called enderman who shows how how = inconsistently these special CP/M and DOS file names are handled in = Windows. He does things like create install Windows itself into con. I = have found you can total OneNote for Windows users by creating a = notebook called for example =E2=80=9Ccon=E2=80=9D. https://www.youtube.com/watch?v=3DYcAdgcAvTCs&t=3D221s Having watched these I am convinced Microsoft should have simply allowed = them in Windows. Currently there is a horrible mess. As for the original problem the only (and safe and portable way among = all OSs that use C language interfaces) is to assume that the null = character is the only safe separator in file lists. Because of the = underlying C language interfaces. Jon > such as "COM1:". :- From owner-freebsd-questions@freebsd.org Fri Oct 16 18:36:23 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 00C1443CDBF for ; Fri, 16 Oct 2020 18:36:22 +0000 (UTC) (envelope-from kudzu@tenebras.com) Received: from mail-lj1-x22d.google.com (mail-lj1-x22d.google.com [IPv6:2a00:1450:4864:20::22d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCZc60VH4z43DB for ; Fri, 16 Oct 2020 18:36:21 +0000 (UTC) (envelope-from kudzu@tenebras.com) Received: by mail-lj1-x22d.google.com with SMTP id p15so3538865ljj.8 for ; Fri, 16 Oct 2020 11:36:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tenebras-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=eoibjFHXIxjW4h1eN4aDJBz6n1mrfxqMa89paVrP3zc=; b=qTtu6E13mXoy4qfxIajJaHzagD74peVS4As0A6De9BNRcHwVKoeyuZbZnlUx2tWu+M 0HJ8TkGdvxGXbZKwd+t8cp1ddq7lRCXuTzXZuKjjS6T0lTMNMXOM6nRylr/eRBFNYAfY ck10qmDjP3ODGJyBl1pUjz305SKYejvzeP1iMH/MsjYQeXc3hJWXHzxE/t6/AlyuUMYJ RaVxGnT6W1mF48tfqohEEs7yIeUB8QZbNYYTdkW70mI3IxU2pxSX7hStc90/7lcpe9dv JvmDna2aeMWM6pn6NL1i7LyFHJ/Ah+vGD3PIB33HS6C7W0lpWJU/k1W7zyUSnTXXSGV6 bKjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=eoibjFHXIxjW4h1eN4aDJBz6n1mrfxqMa89paVrP3zc=; b=egmB95RF1J35o2ZBQev/R8LyMTFXqEDibFFj9eJaGe88WaKoTbbb77oHwQ0KErVMj5 IgIPKq1iTbvz9Ll8FqYZtfkK/tey6qJ+gYwop4YGMfKxAWdHyHLW2eYNYTIRbQsgoF05 F57LMn69aZbzQADasOOOT8mEImZyJ6cXmw30Y+QP/LjE4eqql4/8Jf74vOQs3mRyKbML J07tV750iPJ8nm+rG0SLW0/WsYT8ZujwLifCjFVOz3aFchQD0kmYIto70nwLh6Xh6D5T wz/fpWzyE1+5Th51DYW7UjfQPV14++OZyJeOu6gOFs55XmuSjXKuYvQM7tscJjmrjpqL cleA== X-Gm-Message-State: AOAM532wxVZHdWZ9HasnpIT/wdeVCJA3njEWLqCr5VZdNIMjhkrzucjX y+RTXY6jo1pNWeuar6EoTF61XhlOzDWqRMClOsAeOmF0DI7xAcXA X-Google-Smtp-Source: ABdhPJz32OT4GCW8wryg3JmnBLMBsoCkXQQtkjdz/chz76wfFfzLHqGNuJ1BYLbAIwkwxVpnJ1vn2hR8EZV2qV3dl2Y= X-Received: by 2002:a2e:9c84:: with SMTP id x4mr2105882lji.326.1602873377885; Fri, 16 Oct 2020 11:36:17 -0700 (PDT) MIME-Version: 1.0 References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> In-Reply-To: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> From: Michael Sierchio Date: Fri, 16 Oct 2020 11:35:42 -0700 Message-ID: Subject: Re: FreeBSD using swap even though there's a lot of free memory To: FreeBSD Questions X-Rspamd-Queue-Id: 4CCZc60VH4z43DB X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=pass header.d=tenebras-com.20150623.gappssmtp.com header.s=20150623 header.b=qTtu6E13; dmarc=none; spf=none (mx1.freebsd.org: domain of kudzu@tenebras.com has no SPF policy when checking 2a00:1450:4864:20::22d) smtp.mailfrom=kudzu@tenebras.com X-Spamd-Result: default: False [-1.06 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.57)[-0.567]; R_DKIM_ALLOW(-0.20)[tenebras-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.64)[-0.644]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[tenebras.com]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[tenebras-com.20150623.gappssmtp.com:+]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::22d:from]; NEURAL_SPAM_SHORT(0.45)[0.451]; R_SPF_NA(0.00)[no SPF record]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 18:36:23 -0000 On Thu, Oct 15, 2020 at 7:24 AM Twingly Customer Support wrote: > Hi, > > We have a server running FreeBSD 12.1-RELEASE-p10. We currently have a > problem where FreeBSD starting to swap when running ZFS scrub, even thoug= h > we have ~70G of free memory. tl;dr =E2=80=93 this is normal, nothing to see, move along. It's not "swapping" =E2=80=93 it's paging pre-emptively. If you're used to= Linux, you might think "swap bad" ;-) There is a lot of history to VM management in BSD. This might be an easy place to start: https://flylib.com/books/en/2.849.1.78/1/ --=20 "Well," Brahm=C4=81 said, "even after ten thousand explanations, a fool is = no wiser, but an intelligent person requires only two thousand five hundred." - The Mah=C4=81bh=C4=81rata From owner-freebsd-questions@freebsd.org Fri Oct 16 18:55:58 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D60EC43D0FE for ; Fri, 16 Oct 2020 18:55:58 +0000 (UTC) (envelope-from 4250.82.1d4c50003cac6c4.427c5627c7dfbdc6b846b7ffecdc16d4@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCb2k03Zqz43pp for ; Fri, 16 Oct 2020 18:55:57 +0000 (UTC) (envelope-from 4250.82.1d4c50003cac6c4.427c5627c7dfbdc6b846b7ffecdc16d4@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602874556; x=1605466556; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:to:from:date:x-thread-info; bh=T5HChZ6VUTdhuL+eaPyKixHVcn0cQlLU9U5JTYIv5Nc=; b=CdEP43olb/BK1RcJFvDh/0++AKjVtJkT81eUUe/npkD9s8DuHjA/3goU1RDxT3nzyYYiJSbhDbkEMH+e0mLrFQTvcAKA9kfKw9PEUSRdqigp4C2D2zc5bdBw1cU8E7r5j6qDK/oP+PqsiYzL/+Qc3ciDupQ8M/z11DszLNn/5kg= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNjYWM2YzQuZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r4.h.in.socketlabs.com (s1-b40f.socketlabs.email-od.com [142.0.180.15]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 14:55:46 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r4.h.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 14:55:48 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTUtG-0002OR-Ce for freebsd-questions@freebsd.org; Fri, 16 Oct 2020 19:55:46 +0100 Date: Fri, 16 Oct 2020 19:55:46 +0100 From: Steve O'Hara-Smith To: freebsd-questions@freebsd.org Subject: Re: FreeBSD using swap even though there's a lot of free memory Message-Id: <20201016195546.a3392f971837aa2eeace1325@sohara.org> In-Reply-To: References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4CCb2k03Zqz43pp X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=CdEP43ol; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003cac6c4.427c5627c7dfbdc6b846b7ffecdc16d4@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003cac6c4.427c5627c7dfbdc6b846b7ffecdc16d4@email-od.com X-Spamd-Result: default: False [-2.32 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-1.03)[-1.026]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[sohara.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.03)[-1.035]; RCVD_COUNT_THREE(0.00)[4]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; DKIM_TRACE(0.00)[email-od.com:+]; NEURAL_HAM_SHORT(-0.56)[-0.564]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003cac6c4.427c5627c7dfbdc6b846b7ffecdc16d4@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003cac6c4.427c5627c7dfbdc6b846b7ffecdc16d4@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 18:55:58 -0000 On Fri, 16 Oct 2020 11:35:42 -0700 Michael Sierchio wrote: > On Thu, Oct 15, 2020 at 7:24 AM Twingly Customer Support > wrote: > > > Hi, > > > > We have a server running FreeBSD 12.1-RELEASE-p10. We currently have a > > problem where FreeBSD starting to swap when running ZFS scrub, even > > though we have ~70G of free memory. > > > tl;dr – this is normal, nothing to see, move along. Not when it starts running out of swap space while still reporting 70G of free memory. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 18:57:53 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4118043D801 for ; Fri, 16 Oct 2020 18:57:53 +0000 (UTC) (envelope-from 4250.82.1d4c50003cacaa4.154ff645ab5d25d4ad0353d00fb9eb89@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCb4w4FBCz442H for ; Fri, 16 Oct 2020 18:57:51 +0000 (UTC) (envelope-from 4250.82.1d4c50003cacaa4.154ff645ab5d25d4ad0353d00fb9eb89@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602874671; x=1605466671; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:cc:to:from:date:x-thread-info; bh=qo8m2sKcaYcgG6gx2K+YcIIK2xWkgq39nw5a7RoRQBo=; b=WGJJLL2GctD4w3hso+Qgj7nbgshA3A8WErekkHppXvVc12ddiIPwQu9dZl7G0BBwUfrjPGMcE2rg2AqhWwNhr+GItPq0Y39NP7Ee7IpDxjefYhRMgy0c5m9e6O2UAa07aqlWV9S2dANLncrU1x5QEYnl+/K0GfNWnYRhP3C3Azg= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNjYWNhYTQuZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r2.us-east-1.aws.in.socketlabs.com (r2.us-east-1.aws.in.socketlabs.com [142.0.191.2]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 14:57:48 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r2.us-east-1.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 14:58:14 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTUvF-0002W7-0H; Fri, 16 Oct 2020 19:57:49 +0100 Date: Fri, 16 Oct 2020 19:57:48 +0100 From: Steve O'Hara-Smith To: Twingly Customer Support Cc: freebsd-questions@freebsd.org Subject: Re: FreeBSD using swap even though there's a lot of free memory Message-Id: <20201016195748.ffc15759b311a5feefc91ef5@sohara.org> In-Reply-To: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCb4w4FBCz442H X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=WGJJLL2G; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003cacaa4.154ff645ab5d25d4ad0353d00fb9eb89@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003cacaa4.154ff645ab5d25d4ad0353d00fb9eb89@email-od.com X-Spamd-Result: default: False [-2.40 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.04)[-1.038]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20:c]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[sohara.org]; NEURAL_HAM_LONG(-1.02)[-1.016]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[email-od.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; NEURAL_HAM_SHORT(-0.65)[-0.649]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003cacaa4.154ff645ab5d25d4ad0353d00fb9eb89@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003cacaa4.154ff645ab5d25d4ad0353d00fb9eb89@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 18:57:53 -0000 On Thu, 15 Oct 2020 15:23:51 +0100 Twingly Customer Support wrote: > Eventually, after scrubbing a few times, the swap becomes full and we > start seeing "swap_pager_getswapspace(24): failed" etc. in dmesg. Are you using a swap backed tmpfs ? -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 20:11:39 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 21AC343E9D0 for ; Fri, 16 Oct 2020 20:11:39 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.ilk.org (be-well.ilk.org [23.30.133.173]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCck23FfBz471V for ; Fri, 16 Oct 2020 20:11:38 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from lowell-desk.be-well.ilk.org (router.lan [172.30.250.2]) by be-well.ilk.org (Postfix) with ESMTP id DBF5E33C06; Fri, 16 Oct 2020 16:11:25 -0400 (EDT) Received: by lowell-desk.be-well.ilk.org (Postfix, from userid 1147) id CC40416323B5; Fri, 16 Oct 2020 16:11:24 -0400 (EDT) From: Lowell Gilbert To: Christoph Kukulies Cc: Doug McIntyre , RW via freebsd-questions Subject: Re: Which ports to install to compile gnu binutils? References: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> <20201015214755.GB26691@geeks.org> <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> Reply-To: freebsd-questions@freebsd.org Date: Fri, 16 Oct 2020 16:11:24 -0400 In-Reply-To: <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> (Christoph Kukulies's message of "Fri, 16 Oct 2020 09:17:09 +0200") Message-ID: <448sc6szgz.fsf@be-well.ilk.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 4CCck23FfBz471V X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-questions-local@be-well.ilk.org has no SPF policy when checking 23.30.133.173) smtp.mailfrom=freebsd-questions-local@be-well.ilk.org X-Spamd-Result: default: False [2.24 / 15.00]; HAS_REPLYTO(0.00)[freebsd-questions@freebsd.org]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.40)[0.396]; NEURAL_HAM_LONG(-0.35)[-0.355]; MIME_GOOD(-0.10)[text/plain]; SUBJECT_ENDS_QUESTION(1.00)[]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; AUTH_NA(1.00)[]; DMARC_NA(0.00)[ilk.org]; NEURAL_SPAM_MEDIUM(0.20)[0.197]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_COUNT_TWO(0.00)[2]; ASN(0.00)[asn:7922, ipnet:23.30.0.0/15, country:US]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 20:11:39 -0000 Christoph Kukulies writes: > Thanks. I gave up resp. I abandoned. It is too difficult (to me at least) to figure out, how > to configure binutils to build > gcc-arm-none-eabi-4_9-2015q1-20150306-src.tar.bz2 > > (md5 > ) > from it. Do you need that specific version? If not, the devel/binutils port with the arm-none-eabi flavor will build it for you. I can't find the user documentation for using flavors at the moment, but # make -C /usr/ports/devel/binutils FLAVOR=arm_none_eabi install should do it, or the equivalent for your build system (e.g. # portmaster devel/binutils@arm_none_eabi will also work). If you do need the specific version, then the (some would say optional) first step is to badmouth the person forcing you to use a specific old version. After you've done that, you can either change the port or build it by hand. Both are fairly simple: the first involves changing the tarfile name in the Makefile and distinfo, while the second involves unpacking the tarball and following the README instructions, which will generally lead you to a 2-line command invocation. Good luck. From owner-freebsd-questions@freebsd.org Fri Oct 16 20:20:13 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D85D143ED7C for ; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCcvx4dkQz4751 for ; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: by mailman.nyi.freebsd.org (Postfix) id 7D87D43E6FE; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7D4B243EBBA for ; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.ilk.org (be-well.ilk.org [23.30.133.173]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCcvw6dwjz47B0 for ; Fri, 16 Oct 2020 20:20:12 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from lowell-desk.be-well.ilk.org (router.lan [172.30.250.2]) by be-well.ilk.org (Postfix) with ESMTP id 486F133C0C; Fri, 16 Oct 2020 16:20:07 -0400 (EDT) Received: by lowell-desk.be-well.ilk.org (Postfix, from userid 1147) id 5223816323B5; Fri, 16 Oct 2020 16:20:06 -0400 (EDT) From: Lowell Gilbert To: Robert Huff Cc: questions@freebsd.org Subject: Re: sh scripting question References: <20201016113408.16d58d68@archlinux> <24457.35680.223661.203846@jerusalem.litteratus.org> Reply-To: questions@freebsd.org Date: Fri, 16 Oct 2020 16:20:05 -0400 In-Reply-To: <24457.35680.223661.203846@jerusalem.litteratus.org> (Robert Huff's message of "Fri, 16 Oct 2020 08:00:32 -0400") Message-ID: <444kmtudmy.fsf@be-well.ilk.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 4CCcvw6dwjz47B0 X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-questions-local@be-well.ilk.org has no SPF policy when checking 23.30.133.173) smtp.mailfrom=freebsd-questions-local@be-well.ilk.org X-Spamd-Result: default: False [0.07 / 15.00]; HAS_REPLYTO(0.00)[questions@freebsd.org]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_MEDIUM(-0.19)[-0.187]; NEURAL_HAM_LONG(-0.91)[-0.909]; MIME_GOOD(-0.10)[text/plain]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; DMARC_NA(0.00)[ilk.org]; AUTH_NA(1.00)[]; NEURAL_SPAM_SHORT(0.17)[0.170]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:7922, ipnet:23.30.0.0/15, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 20:20:13 -0000 Robert Huff writes: > OP here. > The filenames at hand were generated by "find" and - on casual > inspection - have no oddities other than the embedded spaces. Since find is in use, I think the canonical solution is to use "find -print0"..."xargs -0" But it's not always convenient to use that mechanism, so there are other methods that have been used quite a few times, depending on the tools the user is comfortable with. In my case, it might involve an inline sed invocation to add the quoting for the spaces. Be well. From owner-freebsd-questions@freebsd.org Fri Oct 16 20:21:09 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 58C8443EDD0 for ; Fri, 16 Oct 2020 20:21:09 +0000 (UTC) (envelope-from jerry@seibercom.net) Received: from mail-qt1-x82c.google.com (mail-qt1-x82c.google.com [IPv6:2607:f8b0:4864:20::82c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCcx04qlNz47Vq for ; Fri, 16 Oct 2020 20:21:08 +0000 (UTC) (envelope-from jerry@seibercom.net) Received: by mail-qt1-x82c.google.com with SMTP id j62so2399570qtd.0 for ; Fri, 16 Oct 2020 13:21:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=seibercom.net; s=google; h=date:from:to:subject:message-id:in-reply-to:references:reply-to :organization:mime-version:content-transfer-encoding; bh=az2ok5qb3b2V1BtqWIZvK8lSKmlfR6ekkSyC1wezCG0=; b=QGEB7LDaZSrcX8WV1iNPPGlXfEusG2ghcIUxdsO6LhnOQmE5H98pgJ8pUqLeK7G03F /6G7VT9iMAHI14o5XwFmZytWbfH0MNKfAHN7K/sleKdrJnDr/kRMyrzydAD8PgNV85rL vWzb2STutJAFL9kRUKaQFXXNNV3LImySnesmk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:in-reply-to :references:reply-to:organization:mime-version :content-transfer-encoding; bh=az2ok5qb3b2V1BtqWIZvK8lSKmlfR6ekkSyC1wezCG0=; b=hGU0N+9ciR3YGxhEct4yMRL2j4tZfClE94rjZED9WuN1j4c7YHnSE7xkCMUowr0QsI Cu8ztAPxYJ1YL+Akl99osmV4lMGptU9THxZ6WTsSfxtZ+aa4VKwaLD3c/TejX0PuUYdD m9wJzoEheb4mCaK/JUzpePgFOAuq5/DyqFpNYEPqIuP7A16MWLIuGT3pjz22EPiDk7Ye iny6CGIC/JlMKeeVL0y3PY/AkbPScWSrbLDwBVYoH90LwFCJF2Ydy3u2zAItwYbzPhZl u4HWZM+ngD3KPA4TN9p6c4skMW+TDOka36m5rpgeUgXFEsMZ2HwFgbiJ4voY6W1mofd5 w4mQ== X-Gm-Message-State: AOAM533Jq+pTl7JifO4E2Up/JlFKdjnKhwTmMnu1Z6+rLb1Gj16QrKSK GVPsXxj8b2vFAkOCezQIAJcpHOtgbITG5g== X-Google-Smtp-Source: ABdhPJwtEuSW4u9BjrYX8mfltP8OC56OvQ9vvl8cKbJtUxZCAzfCYbaUh/I7BkLnpSqJQKLq/WU6+g== X-Received: by 2002:a37:7805:: with SMTP id t5mr5621048qkc.157.1602879344531; Fri, 16 Oct 2020 13:15:44 -0700 (PDT) Received: from scorpio.seibercom.net (cpe-174-109-231-236.nc.res.rr.com. [174.109.231.236]) by smtp.gmail.com with ESMTPSA id f187sm1310603qke.60.2020.10.16.13.15.43 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Oct 2020 13:15:43 -0700 (PDT) Received: from localhost (hp-envy.seibercom.net [192.168.1.102]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: jerry@seibercom.net) by scorpio.seibercom.net (Postfix) with ESMTPSA id 4CCcpk3h19z21rK for ; Fri, 16 Oct 2020 16:15:42 -0400 (EDT) Date: Fri, 16 Oct 2020 16:15:40 -0400 From: Jerry To: freebsd-questions@freebsd.org Subject: Re: sh scripting question Message-ID: <20201016161540.00001abd@seibercom.net> In-Reply-To: <69FD7F52-B1D9-4540-9379-CD3122BEDBB6@jschneider.net> References: <69FD7F52-B1D9-4540-9379-CD3122BEDBB6@jschneider.net> Reply-To: freebsd-questions@freebsd.org Organization: seibercom.net X-Mailer: Claws Mail 3.17.4 (GTK+ 2.24.32; i686-w64-mingw32) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4CCcx04qlNz47Vq X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=seibercom.net header.s=google header.b=QGEB7LDa; dmarc=none; spf=pass (mx1.freebsd.org: domain of jerry@seibercom.net designates 2607:f8b0:4864:20::82c as permitted sender) smtp.mailfrom=jerry@seibercom.net X-Spamd-Result: default: False [2.18 / 15.00]; HAS_REPLYTO(0.00)[freebsd-questions@freebsd.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; TO_DN_NONE(0.00)[]; HAS_ORG_HEADER(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; DKIM_TRACE(0.00)[seibercom.net:+]; NEURAL_HAM_SHORT(-0.39)[-0.387]; RECEIVED_SPAMHAUS_PBL(0.00)[174.109.231.236:received]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; REPLYTO_EQ_TO_ADDR(5.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.95)[-0.947]; R_DKIM_ALLOW(-0.20)[seibercom.net:s=google]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.98)[-0.984]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[seibercom.net]; RCPT_COUNT_ONE(0.00)[1]; RCVD_IN_DNSWL_NONE(0.00)[2607:f8b0:4864:20::82c:from]; RCVD_TLS_ALL(0.00)[]; GREYLIST(0.00)[pass,body]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 20:21:09 -0000 On Fri, 16 Oct 2020 19:07:41 +0100, Jon Schneider commented: >There’s a YouTube publisher called enderman who shows how how >inconsistently these special CP/M and DOS file names are handled in >Windows. He does things like create install Windows itself into con. I >have found you can total OneNote for Windows users by creating a >notebook called for example “con”. > >https://www.youtube.com/watch?v=YcAdgcAvTCs&t=221s > >Having watched these I am convinced Microsoft should have simply >allowed them in Windows. Currently there is a horrible mess. > >As for the original problem the only (and safe and portable way among >all OSs that use C language interfaces) is to assume that the null >character is the only safe separator in file lists. Because of the >underlying C language interfaces. I had no problem creating a notebook named "con". I cannot seem to delete it though. I will have to look into that. -- Jerry From owner-freebsd-questions@freebsd.org Fri Oct 16 20:24:21 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9C9E043F281 for ; Fri, 16 Oct 2020 20:24:21 +0000 (UTC) (envelope-from SRS0=mlVd=DX=mail.sermon-archive.info=doug@sermon-archive.info) Received: from mail.sermon-archive.info (sermon-archive.info [71.177.216.148]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCd0h4T54z47ck for ; Fri, 16 Oct 2020 20:24:20 +0000 (UTC) (envelope-from SRS0=mlVd=DX=mail.sermon-archive.info=doug@sermon-archive.info) Received: from [10.0.1.251] (mini [10.0.1.251]) by mail.sermon-archive.info (Postfix) with ESMTPSA id 4CCd0Y6fWhz2fjWD for ; Fri, 16 Oct 2020 13:24:13 -0700 (PDT) From: Doug Hardie Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: Re: FreeBSD using swap even though there's a lot of free memory Date: Fri, 16 Oct 2020 13:24:13 -0700 References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> <20201016195546.a3392f971837aa2eeace1325@sohara.org> To: FreeBSD Mailing List In-Reply-To: <20201016195546.a3392f971837aa2eeace1325@sohara.org> Message-Id: <89B99A9E-C3A2-47BE-8A0E-D296846946CB@mail.sermon-archive.info> X-Mailer: Apple Mail (2.3445.104.17) X-Virus-Scanned: clamav-milter 0.101.4 at mail X-Virus-Status: Clean X-Rspamd-Queue-Id: 4CCd0h4T54z47ck X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of SRS0=mlVd=DX=mail.sermon-archive.info=doug@sermon-archive.info designates 71.177.216.148 as permitted sender) smtp.mailfrom=SRS0=mlVd=DX=mail.sermon-archive.info=doug@sermon-archive.info X-Spamd-Result: default: False [-1.35 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.91)[-0.915]; FROM_HAS_DN(0.00)[]; MV_CASE(0.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[lafn.org: no valid DMARC record]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.94)[-0.945]; TO_DN_ALL(0.00)[]; NEURAL_HAM_SHORT(-0.09)[-0.093]; R_SPF_ALLOW(-0.20)[+ip4:71.177.216.148]; FORGED_SENDER(0.30)[bc979@lafn.org,SRS0=mlVd=DX=mail.sermon-archive.info=doug@sermon-archive.info]; RCVD_NO_TLS_LAST(0.10)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:5650, ipnet:71.177.216.0/23, country:US]; FROM_NEQ_ENVFROM(0.00)[bc979@lafn.org,SRS0=mlVd=DX=mail.sermon-archive.info=doug@sermon-archive.info]; MAILMAN_DEST(0.00)[freebsd-questions]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 20:24:21 -0000 > On 16 October 2020, at 11:55, Steve O'Hara-Smith = wrote: >=20 > On Fri, 16 Oct 2020 11:35:42 -0700 > Michael Sierchio wrote: >=20 >> On Thu, Oct 15, 2020 at 7:24 AM Twingly Customer Support >> wrote: >>=20 >>> Hi, >>>=20 >>> We have a server running FreeBSD 12.1-RELEASE-p10. We currently have = a >>> problem where FreeBSD starting to swap when running ZFS scrub, even >>> though we have ~70G of free memory. >>=20 >>=20 >> tl;dr =E2=80=93 this is normal, nothing to see, move along. >=20 > Not when it starts running out of swap space while still = reporting > 70G of free memory. I encountered this issue a year or so ago. In my case it turned out to = be a process that was allocating anonymous segments using mmap. It = tended to forget to free them after the usage was complete. As a = result, the system would run out of swap even though there was plenty of = free memory. Anonymous segments are mapped to swap space. I traced the = problem using: procstat -va | grep df That generated a lot of data. I looked for processes that had an = increasing number of df files. Eventually I found the right one and = fixed it. Interesting observation: I have used FreeBSD since version 2.5 and for = years it always had a small number of processes swapped out within an = hour of a boot. Typically they were gettys and similar processes that = never got used. However, with 12.x, I now find that swap info is always = showing 0 blocks used even after weeks of operation. Something has = changed for the better. It is also possible that greping for sw rather than df might give some = useful information. I can't tell as none of my systems are using any = swap. Actually, one system did not have any swap for over a year. I = didn't notice that there was an issue mounting its swap. There were no = performance indicators that issue existed. Nothing changed after I = corrected the problem and added the swap. -- Doug From owner-freebsd-questions@freebsd.org Fri Oct 16 20:28:53 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A326043F58B for ; Fri, 16 Oct 2020 20:28:53 +0000 (UTC) (envelope-from 4250.82.1d4c50003cd8ca8.478d6739d28ae2d1a8ca5415c426de52@email-od.com) Received: from s1-b0c6.socketlabs.email-od.com (s1-b0c6.socketlabs.email-od.com [142.0.176.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CCd5w5PC9z48Wm for ; Fri, 16 Oct 2020 20:28:52 +0000 (UTC) (envelope-from 4250.82.1d4c50003cd8ca8.478d6739d28ae2d1a8ca5415c426de52@email-od.com) DKIM-Signature: v=1; a=rsa-sha256; d=email-od.com;i=@email-od.com;s=dkim; c=relaxed/relaxed; q=dns/txt; t=1602880131; x=1605472131; h=content-transfer-encoding:content-type:mime-version:references:in-reply-to:message-id:subject:cc:to:from:date:x-thread-info; bh=JZB1eWbLr8LzHT69Ma6EegzVnAT1baAGRlP+eElcshA=; b=G5a31Dm0ck+ysZT3z1c6Gm1ev19jvK4mrcmyYWesbEMSLM6/UilW/agwWGYJCGHL0ZwZu0RmDhLvjEl4RtnQMchOE1XnFmSahj8G5Ls/PoqrPaPBMsGsrsl+8hL/HdMFksY0yRMJHPPsaEtCH9JUCDgV9ouJyKFc1MrUweT3vIw= X-Thread-Info: NDI1MC45Mi4xZDRjNTAwMDNjZDhjYTguZnJlZWJzZC1xdWVzdGlvbnM9ZnJlZWJzZC5vcmc= Received: from r1.us-east-2.aws.in.socketlabs.com (r1.us-east-2.aws.in.socketlabs.com [142.0.189.1]) by mxsg2.email-od.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 16:28:42 -0400 Received: from smtp.lan.sohara.org (EMTPY [185.202.17.215]) by r1.us-east-2.aws.in.socketlabs.com with ESMTP(version=Tls12 cipher=Aes256 bits=256); Fri, 16 Oct 2020 16:29:00 -0400 Received: from [192.168.63.1] (helo=steve.lan.sohara.org) by smtp.lan.sohara.org with smtp (Exim 4.94 (FreeBSD)) (envelope-from ) id 1kTWLB-0004cg-97; Fri, 16 Oct 2020 21:28:41 +0100 Date: Fri, 16 Oct 2020 21:28:41 +0100 From: Steve O'Hara-Smith To: Doug Hardie Cc: FreeBSD Mailing List Subject: Re: FreeBSD using swap even though there's a lot of free memory Message-Id: <20201016212841.0864fb91b9f2e72e1246bbfa@sohara.org> In-Reply-To: <89B99A9E-C3A2-47BE-8A0E-D296846946CB@mail.sermon-archive.info> References: <5f885b772d622_95aa2adab2b9c5b41576495c3@sirportly-app-02.mail> <20201016195546.a3392f971837aa2eeace1325@sohara.org> <89B99A9E-C3A2-47BE-8A0E-D296846946CB@mail.sermon-archive.info> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) X-Clacks-Overhead: "GNU Terry Pratchett" Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4CCd5w5PC9z48Wm X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=email-od.com header.s=dkim header.b=G5a31Dm0; dmarc=none; spf=pass (mx1.freebsd.org: domain of 4250.82.1d4c50003cd8ca8.478d6739d28ae2d1a8ca5415c426de52@email-od.com designates 142.0.176.198 as permitted sender) smtp.mailfrom=4250.82.1d4c50003cd8ca8.478d6739d28ae2d1a8ca5415c426de52@email-od.com X-Spamd-Result: default: False [-2.62 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; R_DKIM_ALLOW(-0.20)[email-od.com:s=dkim]; NEURAL_HAM_MEDIUM(-1.04)[-1.044]; FROM_HAS_DN(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[142.0.176.198:from]; MV_CASE(0.50)[]; R_SPF_ALLOW(-0.20)[+ip4:142.0.176.0/20]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[sohara.org]; NEURAL_HAM_LONG(-1.02)[-1.015]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[email-od.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[142.0.176.198:from]; NEURAL_HAM_SHORT(-0.86)[-0.861]; FORGED_SENDER(0.30)[steve@sohara.org,4250.82.1d4c50003cd8ca8.478d6739d28ae2d1a8ca5415c426de52@email-od.com]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:7381, ipnet:142.0.176.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[steve@sohara.org,4250.82.1d4c50003cd8ca8.478d6739d28ae2d1a8ca5415c426de52@email-od.com]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 20:28:53 -0000 On Fri, 16 Oct 2020 13:24:13 -0700 Doug Hardie wrote: > I encountered this issue a year or so ago. In my case it turned out to > be a process that was allocating anonymous segments using mmap. Now that's an interesting one - thank you for mentioning it. -- Steve O'Hara-Smith From owner-freebsd-questions@freebsd.org Fri Oct 16 22:21:25 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 5BC434413E0 for ; Fri, 16 Oct 2020 22:21:25 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCgbn1Bzzz4GqV for ; Fri, 16 Oct 2020 22:21:25 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: by mailman.nyi.freebsd.org (Postfix) id 292C14413DF; Fri, 16 Oct 2020 22:21:25 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 28F57441A2F for ; Fri, 16 Oct 2020 22:21:25 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.ilk.org (be-well.ilk.org [23.30.133.173]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCgbl5HLdz4GwL for ; Fri, 16 Oct 2020 22:21:23 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from lowell-desk.be-well.ilk.org (router.lan [172.30.250.2]) by be-well.ilk.org (Postfix) with ESMTP id E11EC33C06; Fri, 16 Oct 2020 18:21:17 -0400 (EDT) Received: by lowell-desk.be-well.ilk.org (Postfix, from userid 1147) id CC24116323B5; Fri, 16 Oct 2020 18:21:16 -0400 (EDT) From: Lowell Gilbert To: Robert Huff Cc: questions@freebsd.org Subject: Re: sh scripting question References: <24456.60388.135834.43951@jerusalem.litteratus.org> Date: Fri, 16 Oct 2020 18:21:16 -0400 In-Reply-To: <24456.60388.135834.43951@jerusalem.litteratus.org> (Robert Huff's message of "Thu, 15 Oct 2020 20:40:04 -0400") Message-ID: <44zh4lstgj.fsf@be-well.ilk.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 4CCgbl5HLdz4GwL X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-questions-local@be-well.ilk.org has no SPF policy when checking 23.30.133.173) smtp.mailfrom=freebsd-questions-local@be-well.ilk.org X-Spamd-Result: default: False [-0.09 / 15.00]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.51)[-0.505]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_SPAM_SHORT(0.35)[0.349]; NEURAL_HAM_LONG(-0.93)[-0.933]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[ilk.org]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:7922, ipnet:23.30.0.0/15, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 22:21:25 -0000 Robert Huff writes: > Or am I using the wrong tool? I have been thinking about this for a few hours now, and came to a simple conclusion. Which is: That is in fact a good question. From owner-freebsd-questions@freebsd.org Sat Oct 17 07:21:58 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 08A6842D999 for ; Sat, 17 Oct 2020 07:21:58 +0000 (UTC) (envelope-from kuku@kukulies.org) Received: from mail.kukulies.org (mail.kukulies.org [116.203.115.43]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCvbT0BVmz3WGf for ; Sat, 17 Oct 2020 07:21:56 +0000 (UTC) (envelope-from kuku@kukulies.org) Received: from localhost (localhost [127.0.0.1]) by mail.kukulies.org (Postfix) with ESMTP id D3C9010276A; Sat, 17 Oct 2020 09:21:49 +0200 (CEST) Received: from mail.kukulies.org ([127.0.0.1]) by localhost (mail.kukulies.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id s4x19EvGr9ue; Sat, 17 Oct 2020 09:21:49 +0200 (CEST) Received: from christophs-macbook-pro.fritz.box (p57a1f9fb.dip0.t-ipconnect.de [87.161.249.251]) by mail.kukulies.org (Postfix) with ESMTPSA id 64DCD102769; Sat, 17 Oct 2020 09:21:49 +0200 (CEST) From: Christoph Kukulies Message-Id: Content-Type: multipart/signed; boundary="Apple-Mail=_A561A8F9-6D80-4B4E-B03B-B4A1DDE606DF"; protocol="application/pkcs7-signature"; micalg=sha-256 Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.4\)) Subject: Re: Which ports to install to compile gnu binutils? Date: Sat, 17 Oct 2020 09:21:48 +0200 In-Reply-To: <448sc6szgz.fsf@be-well.ilk.org> Cc: Doug McIntyre To: RW via freebsd-questions References: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> <20201015214755.GB26691@geeks.org> <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> <448sc6szgz.fsf@be-well.ilk.org> X-Mailer: Apple Mail (2.3608.120.23.2.4) X-Rspamd-Queue-Id: 4CCvbT0BVmz3WGf X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of kuku@kukulies.org has no SPF policy when checking 116.203.115.43) smtp.mailfrom=kuku@kukulies.org X-Spamd-Result: default: False [-0.41 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; MV_CASE(0.50)[]; HAS_ATTACHMENT(0.00)[]; RCVD_COUNT_THREE(0.00)[4]; TO_DN_ALL(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:24940, ipnet:116.203.0.0/16, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[87.161.249.251:received]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.67)[-0.671]; FREEFALL_USER(0.00)[kuku]; FROM_HAS_DN(0.00)[]; SIGNED_SMIME(-2.00)[]; NEURAL_SPAM_SHORT(0.45)[0.445]; NEURAL_HAM_LONG(-0.59)[-0.585]; MIME_GOOD(-0.20)[multipart/signed,text/plain]; MIME_TRACE(0.00)[0:+,1:+,2:~]; DMARC_NA(0.00)[kukulies.org]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; R_SPF_NA(0.00)[no SPF record]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Oct 2020 07:21:58 -0000 --Apple-Mail=_A561A8F9-6D80-4B4E-B03B-B4A1DDE606DF Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > Am 16.10.2020 um 22:11 schrieb Lowell Gilbert = : >=20 > Christoph Kukulies writes: >=20 >> Thanks. I gave up resp. I abandoned. It is too difficult (to me at = least) to figure out, how >> to configure binutils to build >> gcc-arm-none-eabi-4_9-2015q1-20150306-src.tar.bz2 >> = >> (md5 >> = ) >> from it. >=20 > Do you need that specific version? >=20 Yes. Reason: I =E2=80=9Einherited=E2=80=9C a project from someone, who = passed away and it is to me to continue the project. He had developed = everything under that specific version of the gnu-arm toolchain. I moved everything to Unix and to be = sure that my build environment will produce the exact same results - = which isn=E2=80=99t the case at the moment (some instructions are assembled differently) - I=E2=80= =99m in need of the exact version. > If not, the devel/binutils port with the arm-none-eabi flavor will = build > it for you. I can't find the user documentation for using flavors at = the > moment, but > # make -C /usr/ports/devel/binutils FLAVOR=3Darm_none_eabi install > should do it, or the equivalent for your build system (e.g. > # portmaster devel/binutils@arm_none_eabi > will also work). >=20 > If you do need the specific version, then the (some would say = optional) > first step is to badmouth the person forcing you to use a specific old :) difficult. I could stand at his grave. May God bless him. > version. After you've done that, you can either change the port or = build > it by hand. Both are fairly simple: the first involves changing the > tarfile name in the Makefile and distinfo, while the second involves > unpacking the tarball and following the README instructions, which = will > generally lead you to a 2-line command invocation. This gives me a little hope.=20 >=20 > Good luck. > _ Thanks. =E2=80=94 Christoph --Apple-Mail=_A561A8F9-6D80-4B4E-B03B-B4A1DDE606DF Content-Disposition: attachment; filename=smime.p7s Content-Type: application/pkcs7-signature; name=smime.p7s Content-Transfer-Encoding: base64 MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgEFADCABgkqhkiG9w0BBwEAAKCCCc0w ggSQMIIDeKADAgECAggYVYMhomAL1zANBgkqhkiG9w0BAQsFADBmMQswCQYDVQQGEwJERTEzMDEG A1UECgwqREdOIERldXRzY2hlcyBHZXN1bmRoZWl0c25ldHogU2VydmljZSBHbWJIMSIwIAYDVQQD DBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBFOlBOMB4XDTIwMDUxNjE1Mjc1OVoXDTIxMDUxNjE1Mjc1 OVowbzELMAkGA1UEBhMCREUxITAfBgNVBAUTGDQwMDAwMDAwNWVjMDA4ZGQzNzNhZDhlYzEbMBkG A1UEAwwSQ2hyaXN0b3BoIEt1a3VsaWVzMSAwHgYJKoZIhvcNAQkBFhFrdWt1QGt1a3VsaWVzLm9y ZzCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKug1655hQWRmOtGAShZLbMwDtrm7rAH 7p1oPtE/5KpTpJZe8LHPxxvW0EAd2JcLtEhdvAi7smhZ/giJ3IBK7OYmdaCvuQ6MFvJpkmLkQ9TO 4+RLW+PkBk8nFIUe+PQG+VurpWc8pbU4IRsWS3pEUgov9+LF6VtyYBHKD2HZwe46YBwUq7l0EHxc aa98ewCMO43XznlqjE+oKxwaS2nl1rL/SPVlfGmKqHkdSKEKl6yR1LCcI3J3HP56kqmIrvtySr7q UZVsibA+D6vArqklO99WKQmt0b4IX6TXouvAA6bNoF1FhYUyihm4omMWZkdTs7Gv5rr1fzPWXcev cMfJdtUCAwEAAaOCATcwggEzMB0GA1UdDgQWBBSQh9N17gCH/igJy5ftrVaJNm6SCTAMBgNVHRMB Af8EAjAAMB8GA1UdIwQYMBaAFOnGk9HVDwZkcupqlj66EPJUVLJ5MFYGA1UdIARPME0wSwYMKwYB BAH7KwIBAwIIMDswOQYIKwYBBQUHAgEWLWh0dHA6Ly9zZWM1LmRnbnNlcnZpY2UuZGUvcG9saWNp ZXMvaW5kZXguaHRtbDA+BgNVHR8ENzA1MDOgMaAvhi1odHRwOi8vc2VjNS5kZ25zZXJ2aWNlLmRl L2NybC9jcmwyLXR5cGUtZS5jcmwwDgYDVR0PAQH/BAQDAgSwMB0GA1UdJQQWMBQGCCsGAQUFBwMC BggrBgEFBQcDBDAcBgNVHREEFTATgRFrdWt1QGt1a3VsaWVzLm9yZzANBgkqhkiG9w0BAQsFAAOC AQEALUBRNzLAUiPi29LLATqWmrUlyacMVAtjdROQMd/AVPj0mUqTMoDO+YoWICOSEn/nEyb2Lrrz JNGqC6KO0CNROaWcEhFadKx4qtp9t26Qe/EkO0XbXexIfBxFl1ynQA54D0qtPb/SUZvTy0tq8oBt FdsIU+cXAzigEz2Z9nziHBMqThoKzAZSrk/sPvxT6MNMC/BMGlHGl0DV//wwI5vlzJiKS8iXFyxf 5VrN1IwgRyqXD8JsgF1BuEqcloSJ3JnWUGQCTURFasZDJlP0f/KJS8odUpEWDKnn6tt0RjBk0jUN i7z42ozzPn/o154AgXC2cNmROxC0gnvd+V/yIuAryDCCBTUwggQdoAMCAQICCFUcStdmrSX2MA0G CSqGSIb3DQEBCwUAMGExCzAJBgNVBAYTAkRFMTMwMQYDVQQKDCpER04gRGV1dHNjaGVzIEdlc3Vu ZGhlaXRzbmV0eiBTZXJ2aWNlIEdtYkgxHTAbBgNVBAMMFGRnbnNlcnZpY2UgUm9vdCA3OlBOMB4X DTE2MTAyNjA5MjI0MVoXDTI0MTAyNjA5MjI0MVowZjELMAkGA1UEBhMCREUxMzAxBgNVBAoMKkRH TiBEZXV0c2NoZXMgR2VzdW5kaGVpdHNuZXR6IFNlcnZpY2UgR21iSDEiMCAGA1UEAwwZZGduc2Vy dmljZSBDQSAyIFR5cGUgRTpQTjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBANyl8pQ/ dMejR9KXZs5ro81tFwNhloThlXe8sat79Tjjk6xFqE5E94//0vifJxMrp9RrCkNOo5oPG1djGOgk 0L0ucpHFUH9SQF/SHbm83QvWJXgqEJpjxOKZXTPbJRKVvY25niB0FTr2omRqypiP4A/w5xA6jSJ2 P02vV6WgcPfaLQkM+SEGPxV/pzpvuY3KfzJ9li9mXPNXaJD9y+jqIUvHbCAbuYKQ5nwEAcYMXDpP RQgDQGTrRiFExHEjsZeMzEFADZj9deg/h29AMO0w2YrSvkNReh/zvDZutdy25DZvjE3AUgStWgBC 7x+2ddOb2I61o6xbIsxlfq/mzNpAGoECAwEAAaOCAeowggHmMBIGA1UdEwEB/wQIMAYBAf8CAQAw HwYDVR0jBBgwFoAUAQwWG3Ry0zwU7iZ3t0kUU9j7ixswWwYIKwYBBQUHAQEETzBNMEsGCCsGAQUF BzABhj9odHRwOi8vcm9jc3AtZGduLmRnbnNlcnZpY2UuZGU6ODA4MC9lamJjYS9wdWJsaWN3ZWIv c3RhdHVzL29jc3AwagYDVR0gBGMwYTBfBgwrBgEEAfsrAgEEAgEwTzBNBggrBgEFBQcCARZBaHR0 cDovL3d3dy5kZ25zZXJ2aWNlLmRlL3RydXN0Y2VudGVyL3B1YmxpYy9kZ25zZXJ2aWNlL2luZGV4 Lmh0bWwwgZkGA1UdHwSBkTCBjjCBi6CBiKCBhYaBgmxkYXA6Ly9sZGFwLmRnbnNlcnZpY2UuZGU6 Mzg5L0NOPUNSTC0xLE89REdOJTIwU2VydmljZSUyMEdtYkgsQz1ERT9jZXJ0aWZpY2F0ZVJldm9j YXRpb25MaXN0P2Jhc2U/b2JqZWN0Q2xhc3M9Y1JMRGlzdHJpYnV0aW9uUG9pbnQwHQYDVR0OBBYE FOnGk9HVDwZkcupqlj66EPJUVLJ5MA4GA1UdDwEB/wQEAwIBBjAbBgkrBgEEAcBtAwUEDjAMBgor BgEEAcBtAwUBMA0GCSqGSIb3DQEBCwUAA4IBAQCrvDn6Rcn7/FNq3SOJNfgYNfkdR5CiGoC4sZ+i 0dypCqqMXwbpRQjSriLS2eEe2V2Fms0E4SuBOEaxOg1nVjYafQVGtytRT0ueFIzB3VcnQl7oRFJ0 SHi9d/xjElAZkk8I8lytuWG57SabA72duEp7AaCWG3lVZIdNLy+rkNrfNvEUbqUh0TrZXgqpwwCL JjYF8vyC4I+xxNaXm3EmuNvgQ2j2dGp3Oxc0QbfLLOCbK/rOdDikaBN7kTqpfHls7pcIOhQrgrPV LzY/NHqG9zEpmjuQora63YHdu7BTzGp/DvcQwfyKa/gtb9LHn3AoSUqOKOMd02sUb/AxGhsNjMzJ MYIDFDCCAxACAQEwcjBmMQswCQYDVQQGEwJERTEzMDEGA1UECgwqREdOIERldXRzY2hlcyBHZXN1 bmRoZWl0c25ldHogU2VydmljZSBHbWJIMSIwIAYDVQQDDBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBF OlBOAggYVYMhomAL1zANBglghkgBZQMEAgEFAKCCAXMwGAYJKoZIhvcNAQkDMQsGCSqGSIb3DQEH ATAcBgkqhkiG9w0BCQUxDxcNMjAxMDE3MDcyMTQ4WjAvBgkqhkiG9w0BCQQxIgQgGoi4iRncG10A fn2HwhCyVet82RK5Efa6sF/j/xFuK2cwgYEGCSsGAQQBgjcQBDF0MHIwZjELMAkGA1UEBhMCREUx MzAxBgNVBAoMKkRHTiBEZXV0c2NoZXMgR2VzdW5kaGVpdHNuZXR6IFNlcnZpY2UgR21iSDEiMCAG A1UEAwwZZGduc2VydmljZSBDQSAyIFR5cGUgRTpQTgIIGFWDIaJgC9cwgYMGCyqGSIb3DQEJEAIL MXSgcjBmMQswCQYDVQQGEwJERTEzMDEGA1UECgwqREdOIERldXRzY2hlcyBHZXN1bmRoZWl0c25l dHogU2VydmljZSBHbWJIMSIwIAYDVQQDDBlkZ25zZXJ2aWNlIENBIDIgVHlwZSBFOlBOAggYVYMh omAL1zANBgkqhkiG9w0BAQEFAASCAQASPR518Ef38zQHjUugWc8qbCgHVdg5IXjNCPMQx2gVdfS5 +kzkbcS2cVO2iLhXnkpevQmh2cmKQIuj0hHuQRA7Z681ha6LA0hxB/jJr0FgA/aq5BTihrkVP+Vb /SW378O/T6g58E1B5ka36gbzggps+/0XA3DWyMgp1wjXc43YkgC1ju16pLLBa6KFAICBUNN7DNzZ I8ML7ZWpp4qYEa+q73+jWZSl2sGTpBHo5BZibafF0Yu0CfuKYdIp35BlS+PRakMMhmEMhmVYWeTc LEBFT50f+Gl0qygKw27GiUoIPlUoqVE4WHCa3URCDR46ehUCTaX9JUPMjjTJWqOD+mRjAAAAAAAA --Apple-Mail=_A561A8F9-6D80-4B4E-B03B-B4A1DDE606DF-- From owner-freebsd-questions@freebsd.org Sat Oct 17 19:18:55 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id BFA814403A8 for ; Sat, 17 Oct 2020 19:18:55 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from ms-10.1blu.de (ms-10.1blu.de [178.254.4.101]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4CDCVk3d5Bz4X3v for ; Sat, 17 Oct 2020 19:18:54 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from [80.187.82.78] (helo=localhost.unixarea.de) by ms-10.1blu.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kTrjA-0007rc-38 for freebsd-questions@freebsd.org; Sat, 17 Oct 2020 21:18:52 +0200 Received: from localhost.my.domain (localhost [127.0.0.1]) by localhost.unixarea.de (8.15.2/8.14.9) with ESMTPS id 09HJIo94012005 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO) for ; Sat, 17 Oct 2020 21:18:50 +0200 (CEST) (envelope-from guru@unixarea.de) Received: (from guru@localhost) by localhost.my.domain (8.15.2/8.14.9/Submit) id 09HJIoXn012004 for freebsd-questions@freebsd.org; Sat, 17 Oct 2020 21:18:50 +0200 (CEST) (envelope-from guru@unixarea.de) X-Authentication-Warning: localhost.my.domain: guru set sender to guru@unixarea.de using -f Date: Sat, 17 Oct 2020 21:18:50 +0200 From: Matthias Apitz To: freebsd-questions@freebsd.org Subject: printf(1) and UTF-8 multi-byte chars Message-ID: <20201017191850.GA11909@c720-r342378> Reply-To: Matthias Apitz Mail-Followup-To: freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Operating-System: FreeBSD 13.0-CURRENT r342378 (amd64) X-message-flag: Mails containing HTML will not be read! Please send only plain text. User-Agent: Mutt/1.11.1 (2018-12-01) X-Con-Id: 51246 X-Con-U: 0-guru X-Originating-IP: 80.187.82.78 X-Rspamd-Queue-Id: 4CDCVk3d5Bz4X3v X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of guru@unixarea.de has no SPF policy when checking 178.254.4.101) smtp.mailfrom=guru@unixarea.de X-Spamd-Result: default: False [2.84 / 15.00]; HAS_REPLYTO(0.00)[guru@unixarea.de]; RCVD_VIA_SMTP_AUTH(0.00)[]; HAS_XOIP(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[178.254.4.101:from]; HAS_XAW(0.00)[]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; RECEIVED_SPAMHAUS_PBL(0.00)[80.187.82.78:received]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:42730, ipnet:178.254.0.0/19, country:DE]; MIME_TRACE(0.00)[0:+]; RCVD_IN_DNSWL_LOW(-0.10)[178.254.4.101:from]; ARC_NA(0.00)[]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(0.01)[0.008]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[unixarea.de]; AUTH_NA(1.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_SPAM_MEDIUM(0.67)[0.673]; NEURAL_SPAM_LONG(0.85)[0.855]; R_SPF_NA(0.00)[no SPF record]; MID_RHS_NOT_FQDN(0.50)[]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Oct 2020 19:18:55 -0000 If you look at the two examples: $ printf "[%-10s]\n" "xxxx?xxx" [xxxx?xxx ] $ printf "[%-10s]\n" "xxxx¿xxx" [xxxx¿xxx ] you see that in the first two blanks are used to fill the '%-10s' pattern, while in the second only one blank is used. For sure, the problem/bug has todo with being '¿' a multi-byte UTF-8 char: $ echo '¿' | od -tx1 0000000 c2 bf 0a i.e. with "xxxx¿xxx" 8 chars plus one blank are printed to give %-10s, with "xxxx?xxx" 8 chars plus two blanks are printed. This means the output of printf(1) is byte oriented and not character oriented. Is there a way to print it like this: [xxxx¿xxx ] [xxxx?xxx ] Thanks matthias -- Matthias Apitz, ✉ guru@unixarea.de, http://www.unixarea.de/ +49-176-38902045 Public GnuPG key: http://www.unixarea.de/key.pub Без книги нет знания, без знания нет коммунизма (Влaдимир Ильич Ленин) Without books no knowledge - without knowledge no communism (Vladimir Ilyich Lenin) Sin libros no hay saber - sin saber no hay comunismo. (Vladimir Ilich Lenin) From owner-freebsd-questions@freebsd.org Sat Oct 17 22:35:00 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 8BE7C443FA8 for ; Sat, 17 Oct 2020 22:35:00 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.ilk.org (be-well.ilk.org [23.30.133.173]) by mx1.freebsd.org (Postfix) with ESMTP id 4CDHrz4NGgz3T7Z for ; Sat, 17 Oct 2020 22:34:59 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from lowell-desk.be-well.ilk.org (router.lan [172.30.250.2]) by be-well.ilk.org (Postfix) with ESMTP id E9BAB33C0A; Sat, 17 Oct 2020 18:34:47 -0400 (EDT) Received: by lowell-desk.be-well.ilk.org (Postfix, from userid 1147) id 581CD16323B5; Sat, 17 Oct 2020 18:34:47 -0400 (EDT) From: Lowell Gilbert To: Christoph Kukulies Cc: freebsd-questions@freebsd.org Subject: Re: Which ports to install to compile gnu binutils? References: <283908A2-7765-450B-9746-D51FF58C99B2@kukulies.org> <20201015214755.GB26691@geeks.org> <2F004468-03AA-4F02-9367-1A963F69ED38@kukulies.org> <448sc6szgz.fsf@be-well.ilk.org> Date: Sat, 17 Oct 2020 18:34:46 -0400 In-Reply-To: (Christoph Kukulies's message of "Sat, 17 Oct 2020 09:21:48 +0200") Message-ID: <44y2k4cwhl.fsf@be-well.ilk.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 4CDHrz4NGgz3T7Z X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-questions-local@be-well.ilk.org has no SPF policy when checking 23.30.133.173) smtp.mailfrom=freebsd-questions-local@be-well.ilk.org X-Spamd-Result: default: False [0.81 / 15.00]; SUBJECT_ENDS_QUESTION(1.00)[]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_MEDIUM(-0.48)[-0.481]; NEURAL_HAM_LONG(-0.37)[-0.369]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[ilk.org]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.34)[-0.345]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_COUNT_TWO(0.00)[2]; ASN(0.00)[asn:7922, ipnet:23.30.0.0/15, country:US]; MAILMAN_DEST(0.00)[freebsd-questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Oct 2020 22:35:00 -0000 Christoph Kukulies writes: >> Am 16.10.2020 um 22:11 schrieb Lowell Gilbert : >> Do you need that specific version? >>=20 > > Yes. Reason: I =84inherited=93 a project from someone, who passed away and > it is to me to continue the project. He had developed everything under > that specific > version of the gnu-arm toolchain. I moved everything to Unix and to be > sure that my build environment will produce the exact same results - > which isn=92t the > case at the moment (some instructions are assembled differently) - I=92m = in need of the exact version. But not necessarily permanently; only until you can verify that another version gives you good results. [Where "good" is for you to define based on the project's criteria.] >> If not, the devel/binutils port with the arm-none-eabi flavor will build >> it for you. I can't find the user documentation for using flavors at the >> moment, but >> # make -C /usr/ports/devel/binutils FLAVOR=3Darm_none_eabi install >> should do it, or the equivalent for your build system (e.g. >> # portmaster devel/binutils@arm_none_eabi >> will also work). >>=20 >> If you do need the specific version, then the (some would say optional) >> first step is to badmouth the person forcing you to use a specific old > > :) difficult. I could stand at his grave. May God bless him. Yeah, sounds inappropriate for this case. My sympathies to his memory. If he were around, I'm sure you wouldn't have the problem at all. >> version. After you've done that, you can either change the port or build >> it by hand. Both are fairly simple: the first involves changing the >> tarfile name in the Makefile and distinfo, while the second involves >> unpacking the tarball and following the README instructions, which will >> generally lead you to a 2-line command invocation. > > This gives me a little hope.=20 I suspect that doing everything out-of-tree until you've verified your changes is probably the way to go. I typically do this in my own home directory until I'm ready to package it up for production, but that's somewhat a matter of personal style. The tarball you quoted has a lot more than just binutils in it; the binutils tarball is included, but lots of other things are also. The instructions in the top directory of it seem to cover everything, including scripts to build it. They'll all need to be adapted slightly (for example, they assume that the base system's /bin/sh is bash, or can be made so), but there's a full set of build scripts included for Ubuntu, so it's a nice start. I'd go a little further in terms of helping, but some of the details depend on exactly what your "real" project is like and why you can't actually use other versions. Be well. Lowell