From owner-freebsd-hackers@freebsd.org Sun Jul 14 03:54:18 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 361C015D62FF for ; Sun, 14 Jul 2019 03:54:18 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: from mail-io1-xd35.google.com (mail-io1-xd35.google.com [IPv6:2607:f8b0:4864:20::d35]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 43D6085BF4 for ; Sun, 14 Jul 2019 03:54:17 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: by mail-io1-xd35.google.com with SMTP id f4so28654013ioh.6 for ; Sat, 13 Jul 2019 20:54:17 -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=WVtJrcN6HIoi965evPw4bTL4onWS98QcmXCAg/M+bOA=; b=cSkwdbngNtjlB9w0MDM30+uiIyXhcGdO2lXuDYWx+U+t4hegjakJJmYNRJQEgMbvlg DcV27oCOaFjiiL6hYiuQI27ajHunjcFrGtUPDfe3GA/J4EJhMBg84gyAJ67F85cmTWrJ 9j6Od+9BY9/m83dnB3s0Yf2+H1mwm6aspD6odwImuCQfNPLk9L8NLStd/osbV4+3ZV/A Iw9R4wi2zsSlBRXsT7oZBUSBLHyauXvNIaxMjvlQAEb3oA7OqL55MakaQEVRNL/gaYIW H3UdVGb375bGslmV3CrBMp8m7neiR22x0DU8wmcngzRpHX1k9GL4a7c5H4WEyphpdYWP NJxQ== 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=WVtJrcN6HIoi965evPw4bTL4onWS98QcmXCAg/M+bOA=; b=Qi3sezZY5Si06/rCYBwWdwPJo7n4eZ+QAvqXepGLWAqvsuM3sd1m9lfOq60s6ASPWg NzF3Rkq2W4T8+4sEb3W4kHaRoL7n9O+9rBy/nUu79apP1gfb+8/9OD278pq5NnGp84mm dTLTNFMytiFp6xa7+Nlmdd9usP21q0pVUkzdPfa/XokvCqJ50PkSKSuP4rf0s/5o7RlE 4oI4+8AlIH2JBkjqsV+WcIpRXrN+i+maGnws0uv8GuFMrOyTS1tGXmP7BBnM1etLFPw3 NHCMK1sJh2DMGTg3EwA77/9uifK5nebOotRlzMHaZ0ZpVatvZ1x83bgiCZ5ZhD5m1y3/ cGgg== X-Gm-Message-State: APjAAAX1aM3YHNsBhQXKihrY+qCx5XXKlSNklSOTwAhFHezaxkwD656y H3JgxPnsfqjYFSJSTCln7s2VUYnMh/+6xc5QNTnD X-Google-Smtp-Source: APXvYqzkru/KPZ7AEDfFg5lFC1qzoJHQ04L6VKsfRZUmt+QObUWwrL7my6V4SxyI6Bmz2aGILDe1GKyVXwgFfmQ25EQ= X-Received: by 2002:a6b:8f47:: with SMTP id r68mr19489482iod.204.1563076456316; Sat, 13 Jul 2019 20:54:16 -0700 (PDT) MIME-Version: 1.0 References: <13de3cde-185b-a986-cbce-6ad984792952@selasky.org> <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> In-Reply-To: <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> From: Zaphod Beeblebrox Date: Sat, 13 Jul 2019 23:54:04 -0400 Message-ID: Subject: Re: 4k sector support (not good?) To: Hans Petter Selasky Cc: FreeBSD Hackers X-Rspamd-Queue-Id: 43D6085BF4 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=cSkwdbng; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of zbeeble@gmail.com designates 2607:f8b0:4864:20::d35 as permitted sender) smtp.mailfrom=zbeeble@gmail.com X-Spamd-Result: default: False [-5.38 / 15.00]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; 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]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; FROM_EQ_ENVFROM(0.00)[]; IP_SCORE(-2.91)[ip: (-8.86), ipnet: 2607:f8b0::/32(-3.18), asn: 15169(-2.44), country: US(-0.06)]; MIME_TRACE(0.00)[0:+,1:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; SUBJECT_HAS_QUESTION(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_SPAM_SHORT(0.53)[0.533,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[5.3.d.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; RCVD_TLS_LAST(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Jul 2019 03:54:18 -0000 Thank-you. At this point, I wouldn't be booting from these disks. Right now I'm just trying to "gpart" or label them and get them ZFS formatted... so my test rig boots from it's own disks and the target machine boots from a different pair of disks. What I'm after is how to talk to these properly. On Sat, Jul 13, 2019 at 2:55 AM Hans Petter Selasky wrote: > On 2019-07-13 08:35, Hans Petter Selasky wrote: > > If you want to boot from a 4K disk you need this patch at least: > > https://reviews.freebsd.org/D19245 > > Note that this patch must also be installed before trying to create the > 4K bootable disk! > > --HPS > From owner-freebsd-hackers@freebsd.org Sun Jul 14 03:56:52 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6066315D65B3 for ; Sun, 14 Jul 2019 03:56:52 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: from mail-io1-xd36.google.com (mail-io1-xd36.google.com [IPv6:2607:f8b0:4864:20::d36]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 C908E85D9B for ; Sun, 14 Jul 2019 03:56:50 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: by mail-io1-xd36.google.com with SMTP id g20so28608863ioc.12 for ; Sat, 13 Jul 2019 20:56:50 -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=pCHchI32XC3tVS4hNfYU+HrlHz48n4SHbZAbFz0SL+o=; b=iHZZIt9kMgebuUvlm9FSP7nW4YPqYQ5fyliQ6PUn8cxsvPYTtCnKwkzPYcK2qYWfDA 9WIw/EM2ubUfZR3ODKLPSND9p8L+FoZ3RlSsg+OhceuRueQ+89xyXAZaxwc2tx2tdvda TJs+uyqwEidOLo+wBlgpQEzrJmUjpJZ6rGwd6TIG9Z8Q8tGKLEMrzo3yWYFG7Vlqi+EG 4xsyC51TCSEMfBfk8K9ht+D4azafDDrfLd2lywUNyb+NCR8B7cNR5vuYwHZqzkF8qRO6 jcz+k1JDODeQScsXJvCnuiqtCaTas5SPdXe/cyx/EfrOzUcqt4tdAakNcE0ejlNNkdgJ UO/w== 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=pCHchI32XC3tVS4hNfYU+HrlHz48n4SHbZAbFz0SL+o=; b=C4+j8v7PQbh7cbrFFZ3gE9jfOAgnS7/2BgXBYaYfddOZudldDzy6O3VvD1YipxgHm1 i1VMcoJkZII7UqRyQxyI386D2zRUO33lMoBPCl/idriuC1nhpDPwuSN8c3Yk96ODbrKK S21ZihQM0tCZstLgFQxi3AvJPYRD5T4Eo+yX96Myv8Kpy0CpmCvOlYsBlsyHaYfNFrd+ l31wHT8D3ESkfOyRNTkhB7nEUoWtvQmcpqPZrgwwqkvkC08irSi9D3jv6NjKXYhK3SxS /eK1JN6iYyWT7SRGVhuUR2LaaJ0SvM5SVBly0qpFk30UCBlIhTf58aWsiPq9ibt+9BQ0 l8qw== X-Gm-Message-State: APjAAAWIwaYjfnSkLAj5lGNsvjINNgE822HoYO7csayM2kv7UwgC5DsQ +AUaMzFf6uFWniY4Utt/kaiStAgAHKOlu7Eezpdg X-Google-Smtp-Source: APXvYqyvP9ErCtMjh0v3GFutVho6VpnEBPWXQ9e39+7WEUoZQFS5UDDpplM37yQ5CeWWVls3sjImHxln/boo2LpEGWc= X-Received: by 2002:a02:cc50:: with SMTP id i16mr20423107jaq.50.1563076610106; Sat, 13 Jul 2019 20:56:50 -0700 (PDT) MIME-Version: 1.0 References: <13de3cde-185b-a986-cbce-6ad984792952@selasky.org> <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> In-Reply-To: From: Zaphod Beeblebrox Date: Sat, 13 Jul 2019 23:56:38 -0400 Message-ID: Subject: Re: 4k sector support (not good?) To: Hans Petter Selasky Cc: FreeBSD Hackers X-Rspamd-Queue-Id: C908E85D9B X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=iHZZIt9k; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of zbeeble@gmail.com designates 2607:f8b0:4864:20::d36 as permitted sender) smtp.mailfrom=zbeeble@gmail.com X-Spamd-Result: default: False [-5.47 / 15.00]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; 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]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; FROM_EQ_ENVFROM(0.00)[]; IP_SCORE(-2.99)[ip: (-9.27), ipnet: 2607:f8b0::/32(-3.18), asn: 15169(-2.44), country: US(-0.06)]; MIME_TRACE(0.00)[0:+,1:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; SUBJECT_HAS_QUESTION(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_SPAM_SHORT(0.53)[0.528,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[6.3.d.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; RCVD_TLS_LAST(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Jul 2019 03:56:52 -0000 Wait... are you saying that our gpart isn't properly able to label a 4k sector disk? On Sat, Jul 13, 2019 at 11:54 PM Zaphod Beeblebrox wrote: > Thank-you. At this point, I wouldn't be booting from these disks. Right > now I'm just trying to "gpart" or label them and get them ZFS formatted... > so my test rig boots from it's own disks and the target machine boots from > a different pair of disks. > > What I'm after is how to talk to these properly. > > On Sat, Jul 13, 2019 at 2:55 AM Hans Petter Selasky > wrote: > >> On 2019-07-13 08:35, Hans Petter Selasky wrote: >> > If you want to boot from a 4K disk you need this patch at least: >> > https://reviews.freebsd.org/D19245 >> >> Note that this patch must also be installed before trying to create the >> 4K bootable disk! >> >> --HPS >> > From owner-freebsd-hackers@freebsd.org Sun Jul 14 04:03:47 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 107A415D6D13 for ; Sun, 14 Jul 2019 04:03:47 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x733.google.com (mail-qk1-x733.google.com [IPv6:2607:f8b0:4864:20::733]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 259E4863BC for ; Sun, 14 Jul 2019 04:03:46 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x733.google.com with SMTP id g18so9333293qkl.3 for ; Sat, 13 Jul 2019 21:03:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=JFYxeIFflTfZWuboELdie4P0SwQFDmL1y8ui4OdiWd8=; b=BQO/VU6pwDNldfCXgkaVhkrD42xOvtzDnGT25tnTmI+fOMM0ttOBUoeo3RFPgLpJRs QVfx2c0w2S5DsrURnT9z7ckJZrjR1AzTVhmvcblKhLv7Xzllj6DhS/Ug+T8oxXgz+Lfx jyYKJRjCGU2r60h3P8bMmttyud2rFnT4MeDI7Bq0QWSSApdAyw5jnxMdgqWxR2l9+k8i AlJajEZBNUn6wEdTipFGhWQBCqcm9U7RWF/gUwdcPx0+fh9ammgKlvy7zNd+JaPX42bb vm2EU8GiIW96FiYy2UMq+JpIYd44E/eFhy7qQYxoUkRNCA4comLji6eDCURzXy4oszTJ E1og== 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=JFYxeIFflTfZWuboELdie4P0SwQFDmL1y8ui4OdiWd8=; b=n+OWU27P96XMD3NztQFGdGaX3uPf3vC8C5/R0W/ESNpI0UTimmCGgwiIfXoWR2pJ/0 lPgGhz051uzJ/BoqEWLnLmrmB2XEJd8YWbRC+x1jfY08JNAi8Ismlmrw7RE6X0PVSDEe s61qOd3v/57wZ8kVTQrK+Tssf7EP8F06uiHh2Q4SBmcKgOv/CCKUEvJP+HtJywBwweln 5vo7Ogm22gXlH61YCa6aRL6bIfi/IzZvd4w0U/9qzSRwBpLREf7F0DDclrDJum8PGqmV SDziapRnBiVgUIeiWkDVdN+S6iaSPhiyrARVphXWuqmWW4zxwnZaUVY7oeRCRvsaQRoq HDxg== X-Gm-Message-State: APjAAAUVUMdcuVSHnjvOEOsivPavwQbDwk3sjV34+6riCyjDfgLNQzqz CyCEowMy+q3WQMA0QJSjUwGboDPIjW6zb49LKu9SHw== X-Google-Smtp-Source: APXvYqzxtXwEQnoeU3L1cCh48Bi/RtZ3YocJ1lhf+bnjQN5XpqvL/P60mlcheZB3/la+59EzPfvxB7x7FVSyCn7e8TE= X-Received: by 2002:a37:83c4:: with SMTP id f187mr11734248qkd.380.1563077025294; Sat, 13 Jul 2019 21:03:45 -0700 (PDT) MIME-Version: 1.0 References: <13de3cde-185b-a986-cbce-6ad984792952@selasky.org> <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> In-Reply-To: From: Warner Losh Date: Sat, 13 Jul 2019 22:03:32 -0600 Message-ID: Subject: Re: 4k sector support (not good?) To: Zaphod Beeblebrox Cc: Hans Petter Selasky , FreeBSD Hackers X-Rspamd-Queue-Id: 259E4863BC X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=BQO/VU6p X-Spamd-Result: default: False [-4.47 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.55)[0.554,0]; IP_SCORE(-3.01)[ip: (-9.37), ipnet: 2607:f8b0::/32(-3.18), asn: 15169(-2.44), country: US(-0.06)]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; MX_GOOD(-0.01)[cached: ALT1.aspmx.l.google.com]; RCVD_IN_DNSWL_NONE(0.00)[3.3.7.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; FREEMAIL_TO(0.00)[gmail.com]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; SUBJECT_HAS_QUESTION(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Jul 2019 04:03:47 -0000 On Sat, Jul 13, 2019, 9:59 PM Zaphod Beeblebrox wrote: > Wait... are you saying that our gpart isn't properly able to label a 4k > sector disk? > There are competing notions about what is right... Warner On Sat, Jul 13, 2019 at 11:54 PM Zaphod Beeblebrox > wrote: > > > Thank-you. At this point, I wouldn't be booting from these disks. Right > > now I'm just trying to "gpart" or label them and get them ZFS > formatted... > > so my test rig boots from it's own disks and the target machine boots > from > > a different pair of disks. > > > > What I'm after is how to talk to these properly. > > > > On Sat, Jul 13, 2019 at 2:55 AM Hans Petter Selasky > > wrote: > > > >> On 2019-07-13 08:35, Hans Petter Selasky wrote: > >> > If you want to boot from a 4K disk you need this patch at least: > >> > https://reviews.freebsd.org/D19245 > >> > >> Note that this patch must also be installed before trying to create the > >> 4K bootable disk! > >> > >> --HPS > >> > > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Sun Jul 14 04:09:49 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2B8B415D6EB4 for ; Sun, 14 Jul 2019 04:09:49 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x82f.google.com (mail-qt1-x82f.google.com [IPv6:2607:f8b0:4864:20::82f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 CCB6B865E7 for ; Sun, 14 Jul 2019 04:09:47 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x82f.google.com with SMTP id 44so12294222qtg.11 for ; Sat, 13 Jul 2019 21:09:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=iU6gWnvW53SGsAsX+04whLUBLBN/V5BrwbLENnFkoyw=; b=m6Cpb+0OD8y3MHMGCG4saOome4UoHaYi6TC3oMT6paJOVD3SMftY77J07FzAWHJJe6 nod8NTxYKGMSUv1TSQJjnBMYZtvXBgGoWEeKb65MiSjH78qKLU740vqdVZFcoX520wuC BhZli4mRWm7dLKlac86DSBrHVE3FvNSYcTrJnMoEWQZr5gp+jq9E6i7xu/IchKqdb4d8 Hm1RYd2A4s+8nlEuBgUxLFHRi+gzi9vS68f3ybi7K8fgGp6jINX37mtGYeB1FBCn+aiK r3smGSehLIissXx7SicSxIhpzYeDGyeHzm28ny6LQIheTou+Y1JpEXnftJhzniA5HooS ZabA== 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=iU6gWnvW53SGsAsX+04whLUBLBN/V5BrwbLENnFkoyw=; b=qQbPB58fQe4voj61wT5fSc711mHQfrS0Bf+9yUM75/xWMX3SHOQmR6mZW8WDeDPiUW tDAicN1zlxLx3MMZ34qft+4fpI6WNBZsIvoQyQArSPqdH7Y51DazI/zIDdxBQxu0Dpzv 34/nAPI5EIvX1HH4faSvuZ7a1/SDFndhbnY3X/cOr3WcisN8aJP5xAYmMfsNwNB++jj0 gcbKszBzlV+YnIXsbYywvApL3e1fwhYuwVZToKPyX9CYZ3n1tkVMwX9ZIhwEbuS6MTsZ VcMWR2TaNWlVgzAMvwYzv0BxNdXAW43QM3Z0b7Cd87hQ5g13SkwEFtt7hfXg+hHsYPfO uwhg== X-Gm-Message-State: APjAAAXAIxyiUqH6i5yJtzGZr9J2tFu/fGh66G/x59rrzeqYPUJLkgfh 5V0/YB8ZqbsZa0dyFBhLxAU3OTFIFocYKGjhvsA= X-Google-Smtp-Source: APXvYqxYDYmBchhnIz28P+LfFY7IF3EqjIQV2oxxbaUlcKeRt40dVVqmlfJu2SKmLyR50EfnzuZiuzyAqRPTlIsqyvk= X-Received: by 2002:ac8:244f:: with SMTP id d15mr12365357qtd.32.1563077387160; Sat, 13 Jul 2019 21:09:47 -0700 (PDT) MIME-Version: 1.0 References: <13de3cde-185b-a986-cbce-6ad984792952@selasky.org> <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> In-Reply-To: From: Warner Losh Date: Sat, 13 Jul 2019 22:09:35 -0600 Message-ID: Subject: Re: 4k sector support (not good?) To: Zaphod Beeblebrox Cc: Hans Petter Selasky , FreeBSD Hackers X-Rspamd-Queue-Id: CCB6B865E7 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=m6Cpb+0O X-Spamd-Result: default: False [-4.47 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.55)[0.554,0]; IP_SCORE(-3.02)[ip: (-9.40), ipnet: 2607:f8b0::/32(-3.18), asn: 15169(-2.44), country: US(-0.06)]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; MX_GOOD(-0.01)[cached: ALT1.aspmx.l.google.com]; RCVD_IN_DNSWL_NONE(0.00)[f.2.8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; FREEMAIL_TO(0.00)[gmail.com]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; SUBJECT_HAS_QUESTION(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Jul 2019 04:09:49 -0000 On Sat, Jul 13, 2019, 10:03 PM Warner Losh wrote: > > > On Sat, Jul 13, 2019, 9:59 PM Zaphod Beeblebrox wrote: > >> Wait... are you saying that our gpart isn't properly able to label a 4k >> sector disk? >> > > There are competing notions about what is right... > For MBR disks. Apple has one standard, which is what the patch is for. Those disks won't necessarily work on other BIOSes. GPT just works today... Warner Warner > > > On Sat, Jul 13, 2019 at 11:54 PM Zaphod Beeblebrox >> wrote: >> >> > Thank-you. At this point, I wouldn't be booting from these disks. Right >> > now I'm just trying to "gpart" or label them and get them ZFS >> formatted... >> > so my test rig boots from it's own disks and the target machine boots >> from >> > a different pair of disks. >> > >> > What I'm after is how to talk to these properly. >> > >> > On Sat, Jul 13, 2019 at 2:55 AM Hans Petter Selasky >> > wrote: >> > >> >> On 2019-07-13 08:35, Hans Petter Selasky wrote: >> >> > If you want to boot from a 4K disk you need this patch at least: >> >> > https://reviews.freebsd.org/D19245 >> >> >> >> Note that this patch must also be installed before trying to create the >> >> 4K bootable disk! >> >> >> >> --HPS >> >> >> > >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org >> " >> > From owner-freebsd-hackers@freebsd.org Sun Jul 14 04:34:40 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2B0D315D797F for ; Sun, 14 Jul 2019 04:34:40 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: from mail-io1-xd33.google.com (mail-io1-xd33.google.com [IPv6:2607:f8b0:4864:20::d33]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 20BB7873B1 for ; Sun, 14 Jul 2019 04:34:39 +0000 (UTC) (envelope-from zbeeble@gmail.com) Received: by mail-io1-xd33.google.com with SMTP id q22so28742540iog.4 for ; Sat, 13 Jul 2019 21:34:39 -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=L563b32ugPNDUGN9saThY7yHyvsPrYkNyUv7yI8ZS2k=; b=YNKFY0tSGAzsb7gO0Mgo++wUk8d+nr5AdI9FNcB8YgAWWciU/e9qWRnrt9Vtb/7iXb m2wn1Kfo9zIWsZzWzPLQ6A13joiRL2QJZ4zZWzecum9fP3kLEQdA5TjkEtfLA9xhZY/H 0TCovmvtn+0Hp9YAXWkdI1rLVcY0ulo2SHTcvk59fwXtHr6RjBeBaGzd1bEh24zuGYya BjQQQXsmIJj9cYC9IxkEQjvBiuWqm7SbjdUHAf2qh5xftH2v6m9zFBmp/jp8tcJ1dwRI 0zQsRfRBd1bwXnRxKRLPjrTpjFUrwcP7ADGHbMPGe4Slsv7fjgIgq4y+I03r+Nen3UUC nlNA== 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=L563b32ugPNDUGN9saThY7yHyvsPrYkNyUv7yI8ZS2k=; b=sKXnO7zbniiCm1pUykOYJL4Pu+8TWxdPXJrfA8mcWeNwra6kDug4AVLPchzs5P3o9l eaNmbEaUakE/9w/WBxBLDOC8PhKjsdSnc3nLjbeW56aAHbhu1fPcoGgdt4uu5//c+ige aC1nfoUOio0eVpiPW5Okczz/lQq9uLWWHPIjwLV0zKeRk99y9HnQCX02pxGLrZPyQgjZ trMorwkJpwJxC13KK4IPrrGWuG7yPXDSc75W0Loc31+S70hrH0Zi5Zg3TXSCLAPYKjuG w4yz2KGlY81V8Ntu4y8fczP9RmO9mtqGU66nRwMYRZuRsMdOKNRMJFWYt1n6WpodpfSj vJlA== X-Gm-Message-State: APjAAAXSlDnU9f7Nrseh+1lh8dRlo5zh5FGM/BtsR7dIO5vzId6N3QSC Zq/9HM7h92OgqkJKKEh0gwIeq+ovBieJS4YYeA== X-Google-Smtp-Source: APXvYqxCyyD0HDiQLhWsLlY9jeOU/tpe+VAoZV1fl6ZuhxSyZf59/z82P6ndUIQxOoZUVcEKbdUFTJirXyUvV5/TjII= X-Received: by 2002:a6b:ce19:: with SMTP id p25mr19385387iob.201.1563078877992; Sat, 13 Jul 2019 21:34:37 -0700 (PDT) MIME-Version: 1.0 References: <13de3cde-185b-a986-cbce-6ad984792952@selasky.org> <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> In-Reply-To: From: Zaphod Beeblebrox Date: Sun, 14 Jul 2019 00:34:26 -0400 Message-ID: Subject: Re: 4k sector support (not good?) To: Warner Losh Cc: Hans Petter Selasky , FreeBSD Hackers X-Rspamd-Queue-Id: 20BB7873B1 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=YNKFY0tS; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of zbeeble@gmail.com designates 2607:f8b0:4864:20::d33 as permitted sender) smtp.mailfrom=zbeeble@gmail.com X-Spamd-Result: default: False [-5.22 / 15.00]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; TO_DN_ALL(0.00)[]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; IP_SCORE(-2.79)[ip: (-8.28), ipnet: 2607:f8b0::/32(-3.18), asn: 15169(-2.44), country: US(-0.06)]; MIME_TRACE(0.00)[0:+,1:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; SUBJECT_HAS_QUESTION(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.58)[0.583,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[3.3.d.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; RCVD_TLS_LAST(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Jul 2019 04:34:40 -0000 So... you're saying that if I gpart create -s GPT on a disk with 4k sectors, it should do the right thing and just work? Keep in mind, I don't care what the BIOS thinks... I only care what FreeBSD sees when it comes online. On Sun, Jul 14, 2019 at 12:09 AM Warner Losh wrote: > > > On Sat, Jul 13, 2019, 10:03 PM Warner Losh wrote: > >> >> >> On Sat, Jul 13, 2019, 9:59 PM Zaphod Beeblebrox >> wrote: >> >>> Wait... are you saying that our gpart isn't properly able to label a 4k >>> sector disk? >>> >> >> There are competing notions about what is right... >> > > For MBR disks. Apple has one standard, which is what the patch is for. > Those disks won't necessarily work on other BIOSes. GPT just works today... > > From owner-freebsd-hackers@freebsd.org Sun Jul 14 04:57:14 2019 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DB19115D7F7B for ; Sun, 14 Jul 2019 04:57:13 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x82f.google.com (mail-qt1-x82f.google.com [IPv6:2607:f8b0:4864:20::82f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 B9A9D87EC3 for ; Sun, 14 Jul 2019 04:57:12 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x82f.google.com with SMTP id h18so12365301qtm.9 for ; Sat, 13 Jul 2019 21:57:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=H4OFV/JzoV0N1giIVXz+/cjTh4mcmn4RBhEjltdSJ+Q=; b=PgCkrjjq86+QzsidmCeOL2qlJFwewpHMDtQR1uy8KaYE8uq+8eMGETju/hQhsKqvJb Vl1O4soE9Qsdao1aTL8gitsYyXdnRU5dvnxAh7OcLt2RK96ezfEMKhqRE841JCgT8iMP 079zMiseY7r8HjiP3wD0DoyaNZH/NfdzTzANdCVQcV2YfCzhHMECi6o1OpJ1NtV2GUbp nXNNrZ7Gc0uc2p5h4AHLuQ5v/hixkMpbmSbw3imY9whton74bbItP5CV0l4aUQtJmXwr IF21blsNvcqDDCaazD5DMPt8K8+KnrkYY8N2HywaCGE+JjFijSo+MMlGrXFM8rBwHPQ+ WWsQ== 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=H4OFV/JzoV0N1giIVXz+/cjTh4mcmn4RBhEjltdSJ+Q=; b=NA6/EiyWO3cc9Vzvn6qPDwLJJP2pe6JU2lcW4CyjCYBnEG2h/n6DVDQNMaXjBqnnFd YREPmDIiUQH/R8udoxZpymHHbTYL7AbZ+E7kZYCv6+hSIGmPpoY6ZRxv0j3DUrG2HJI+ A8znRumUiV5USykwfjdBqlBKnqbfLnJxEAiVynnh0FWYM8HFWxrfINKlaxI12ENW2m7P y4lRctCxHkfTT6Jcl+44QIyNH/9LCJmhrEu0QixgXvtjdGOWu+kObNGClEX3I5isiJ9X y1jOA4r/S19GgupM0tHL8HWzWBsDgLlHB0oIbscfQb1p/ybyMnnbOBtO/tP+xihcapxK lQaQ== X-Gm-Message-State: APjAAAW3IKOsm3Rtx4AxDE3b6dd8Xk+UEg0xbO0nA7EsvfvsL7aGoE2y z8BDNysLH7edmrZI6rdzjPb4Q622H1fQeVHqAQU= X-Google-Smtp-Source: APXvYqzKFqlsyN5a7H2HTol6M6f9wYQDxRkWcTuYJjBmL9a8zHZ4TZLmfeTVPrxkKQiInQ0/HnoYENlNh39GdXIoaaw= X-Received: by 2002:aed:34a6:: with SMTP id x35mr12875136qtd.187.1563080232114; Sat, 13 Jul 2019 21:57:12 -0700 (PDT) MIME-Version: 1.0 References: <13de3cde-185b-a986-cbce-6ad984792952@selasky.org> <883fbfcf-cac6-99a9-cb6f-43e413be9bb0@selasky.org> In-Reply-To: From: Warner Losh Date: Sat, 13 Jul 2019 22:56:59 -0600 Message-ID: Subject: Re: 4k sector support (not good?) To: Zaphod Beeblebrox Cc: Hans Petter Selasky , FreeBSD Hackers X-Rspamd-Queue-Id: B9A9D87EC3 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=PgCkrjjq X-Spamd-Result: default: False [-4.46 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(0.56)[0.564,0]; IP_SCORE(-3.02)[ip: (-9.40), ipnet: 2607:f8b0::/32(-3.18), asn: 15169(-2.44), country: US(-0.06)]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; MX_GOOD(-0.01)[cached: ALT1.aspmx.l.google.com]; RCVD_IN_DNSWL_NONE(0.00)[f.2.8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; FREEMAIL_TO(0.00)[gmail.com]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; SUBJECT_HAS_QUESTION(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Jul 2019 04:57:14 -0000 On Sat, Jul 13, 2019, 10:34 PM Zaphod Beeblebrox wrote: > > So... you're saying that if I gpart create -s GPT on a disk with 4k > sectors, it should do the right thing and just work? > > Keep in mind, I don't care what the BIOS thinks... I only care what > FreeBSD sees when it comes online. > Yes. Warner On Sun, Jul 14, 2019 at 12:09 AM Warner Losh wrote: > >> >> >> On Sat, Jul 13, 2019, 10:03 PM Warner Losh wrote: >> >>> >>> >>> On Sat, Jul 13, 2019, 9:59 PM Zaphod Beeblebrox >>> wrote: >>> >>>> Wait... are you saying that our gpart isn't properly able to label a 4k >>>> sector disk? >>>> >>> >>> There are competing notions about what is right... >>> >> >> For MBR disks. Apple has one standard, which is what the patch is for. >> Those disks won't necessarily work on other BIOSes. GPT just works today... >> >> From owner-freebsd-hackers@freebsd.org Mon Jul 15 05:10:45 2019 Return-Path: Delivered-To: freebsd-hackers@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 BC724B0DC3 for ; Mon, 15 Jul 2019 05:10:45 +0000 (UTC) (envelope-from me@pacopascal.com) Received: from MTA-05-3.privateemail.com (mta-05-3.privateemail.com [68.65.122.15]) (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 78FA676C1B for ; Mon, 15 Jul 2019 05:10:44 +0000 (UTC) (envelope-from me@pacopascal.com) Received: from MTA-05.privateemail.com (localhost [127.0.0.1]) by MTA-05.privateemail.com (Postfix) with ESMTP id A48246006F for ; Mon, 15 Jul 2019 01:10:35 -0400 (EDT) Received: from gauss (unknown [10.20.151.209]) by MTA-05.privateemail.com (Postfix) with ESMTPA id 5438F60049 for ; Mon, 15 Jul 2019 05:10:35 +0000 (UTC) Date: Mon, 15 Jul 2019 01:10:33 -0400 From: Paco Pascal To: freebsd-hackers@freebsd.org Subject: What's the expected behavior of LINENO from /bin/sh? Message-ID: <20190715051033.GA2591@gauss> Mail-Followup-To: Paco Pascal , freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.12.0 (2019-05-25) X-Virus-Scanned: ClamAV using ClamSMTP X-Rspamd-Queue-Id: 78FA676C1B X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of me@pacopascal.com designates 68.65.122.15 as permitted sender) smtp.mailfrom=me@pacopascal.com X-Spamd-Result: default: False [-2.17 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; NEURAL_HAM_MEDIUM(-0.99)[-0.993,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:68.65.122.0/27]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; MIME_TRACE(0.00)[0:+]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCVD_COUNT_THREE(0.00)[3]; TO_DN_NONE(0.00)[]; MX_GOOD(-0.01)[mx1.privateemail.com]; NEURAL_HAM_SHORT(-0.67)[-0.665,0]; RCVD_IN_DNSWL_NONE(0.00)[15.122.65.68.list.dnswl.org : 127.0.5.0]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[pacopascal.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; ASN(0.00)[asn:22612, ipnet:68.65.122.0/24, country:US]; MID_RHS_NOT_FQDN(0.50)[]; IP_SCORE(-0.70)[ipnet: 68.65.122.0/24(-4.01), asn: 22612(0.58), country: US(-0.06)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Jul 2019 05:10:45 -0000 Hello, I'm new at attempting to contribute to the FreeBSD project. As an introduction to working on FreeBSD, I started searching the bug database and settled into bug #235589. If I've made an error in my approach to the community, just let me know. I'm not sure what the wisest method is to fix this, given I'm not familiar with the code-base. Also, it's not clear what the correct behavior of LINENO should be. FreeBSD's shell treats LINENO differently than bash. For example, cmd='echo $LINENO $((LINENO)) $(($LINENO))' f() { eval ${cmd} echo $LINENO $((LINENO)) $(($LINENO)) } eval ${cmd} echo $LINENO $((LINENO)) $(($LINENO)) f has the following output in bash, 8 8 8 9 9 9 4 4 4 5 5 5 while FreeBSD's shell outputs, 1 0 1 9 0 9 1 0 1 3 0 3 . The reason for the bug (and difference in behavior) is because LINENO isn't treated as other variables are; it's value can't be looked up using lookupvar() from var.c which is what arith() eventually does when trying to find the value of a variable that isn't preceded by a "$". So, the first thing I need to ask before I go any further is, what's the expected behavior in the above conditions? // Paco From owner-freebsd-hackers@freebsd.org Mon Jul 15 07:25:54 2019 Return-Path: Delivered-To: freebsd-hackers@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 7DF9BB2AAC for ; Mon, 15 Jul 2019 07:25:54 +0000 (UTC) (envelope-from clay.daniels.jr@gmail.com) Received: from mail-vs1-xe2a.google.com (mail-vs1-xe2a.google.com [IPv6:2607:f8b0:4864:20::e2a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 C07CB82AF3 for ; Mon, 15 Jul 2019 07:25:53 +0000 (UTC) (envelope-from clay.daniels.jr@gmail.com) Received: by mail-vs1-xe2a.google.com with SMTP id h28so10674662vsl.12 for ; Mon, 15 Jul 2019 00:25:53 -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=0SXd/Akaaxszc17mAl1n/HoIjG1xpjK39wnfrkjcbJo=; b=c6uoyvvqDHqg5MxlZA8KPe2ujlx6+tBd5Ozy7mvxdT3ddbrZyIONONjZhj+2aAeZ0x yudyySDE+UvCkA5lJNhWcWn1hxEGu9yEbUR1lLBkizwniQAWH+IbayQvkmYKvZBQp51g F5syFd7hWIFoFHkEKSJ3KGGdjJI6r+m+Nu5OHZC0UfNz18N/fYzONcEJgHukvJLqhxJs wvcXb+3c/ueC/PdPqzC3rjySCaAtUW3zZsgDtnOvzFo88upWAnjpUbiPvLUGMPTJN7VJ xZxtaAtPVUSTPceLcObyob6v+btop4s1FMzeN28AGISizdoOFx0WyEuf+l5AWGpPwuCg jutg== 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=0SXd/Akaaxszc17mAl1n/HoIjG1xpjK39wnfrkjcbJo=; b=BvyVuXkGXehlN9c1g/PPAomua0Cscuc9BEMpaPkAkH0kpxeb6pFQOLSJQbQt3y26ZJ Q2GaSrLLCyR7UUwBvlMHXke2KX5rKQi2xtUCUmoThNnCWk8cwGdAlTwlMrc5rVYmexWU dcIFkKQJAceeKN5HUfvKhvox87kLIF9e2CMXQTe7/JPAMrymPn5zxFRo5px6gyp43yWB vUx7gjtDNqm3kIHlRVZw1K4/Sg5uo9cCGhJvJSGuK+/p7AbnXuLti/uyiZ9/fthIfmc7 idGeuxnPABKty+sj+JwOyiYarUAhtE+s+jOBxPFaEmRqIoKShWUS2Xy/Hd9vdsJ1XOXk uxUg== X-Gm-Message-State: APjAAAWg9MM1pQKPVVesj5A6d3daFyZ9ydXb3MmMwRSpINVdx1KVtw8q Xf/renXsK+GBGLaUufErxlZuWVDKXt/yViGhmA== X-Google-Smtp-Source: APXvYqzXRwZRWA4BJ5kfakEYAqmC58/0D4mI8yyUh/JthCUUuKxsJh9R/xYos3PJavv/eu2yIn0PNREE08kz+ji1FKQ= X-Received: by 2002:a67:e244:: with SMTP id w4mr15349585vse.176.1563175552888; Mon, 15 Jul 2019 00:25:52 -0700 (PDT) MIME-Version: 1.0 References: <20190715051033.GA2591@gauss> In-Reply-To: <20190715051033.GA2591@gauss> From: "Clay Daniels Jr." Date: Mon, 15 Jul 2019 02:25:40 -0500 Message-ID: Subject: Re: What's the expected behavior of LINENO from /bin/sh? To: Paco Pascal , freebsd-hackers@freebsd.org X-Rspamd-Queue-Id: C07CB82AF3 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=c6uoyvvq; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of claydanielsjr@gmail.com designates 2607:f8b0:4864:20::e2a as permitted sender) smtp.mailfrom=claydanielsjr@gmail.com X-Spamd-Result: default: False [-5.11 / 15.00]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; NEURAL_HAM_SHORT(-0.02)[-0.016,0]; FROM_EQ_ENVFROM(0.00)[]; IP_SCORE(-3.08)[ip: (-9.73), ipnet: 2607:f8b0::/32(-3.17), asn: 15169(-2.44), country: US(-0.06)]; MIME_TRACE(0.00)[0:+,1:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; TAGGED_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[a.2.e.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; SUBJECT_ENDS_QUESTION(1.00)[]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_LAST(0.00)[] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Jul 2019 07:25:54 -0000 Paco, I got curious about $LINENO & noticed that it is only available in sh, but not csh nor tcsh: clay@bsd13:/usr/home/clay $ echo $SHELL /bin/sh clay@bsd13:/usr/home/clay $ echo $LINENO 2 clay@bsd13:/usr/home/clay $ cat /etc/shells # $FreeBSD: head/etc/shells 348185 2019-05-23 18:37:05Z bapt $ # # List of acceptable shells for chpass(1). # Ftpd will not allow users to connect who are not using # one of these shells. /bin/sh /bin/csh /bin/tcsh clay@bsd13:/usr/home/clay $ /bin/csh clay@bsd13:~ % echo $LINENO LINENO: Undefined variable. clay@bsd13:~ % /bin/tcsh clay@bsd13:~ % echo $LINENO LINENO: Undefined variable. clay@bsd13:~ % /bin/sh clay@bsd13:~ $ echo $LINENO $((LINENO)) $(($LINENO)) 1 0 1 clay@bsd13:~ $ On Mon, Jul 15, 2019 at 12:11 AM Paco Pascal wrote: > Hello, > > I'm new at attempting to contribute to the FreeBSD project. As an > introduction to working on FreeBSD, I started searching the bug > database and settled into bug #235589. If I've made an error in my > approach to the community, just let me know. > > I'm not sure what the wisest method is to fix this, given I'm not > familiar with the code-base. Also, it's not clear what the correct > behavior of LINENO should be. FreeBSD's shell treats LINENO differently > than bash. For example, > > cmd='echo $LINENO $((LINENO)) $(($LINENO))' > > f() { > eval ${cmd} > echo $LINENO $((LINENO)) $(($LINENO)) > } > > eval ${cmd} > echo $LINENO $((LINENO)) $(($LINENO)) > f > > has the following output in bash, > > 8 8 8 > 9 9 9 > 4 4 4 > 5 5 5 > > while FreeBSD's shell outputs, > > 1 0 1 > 9 0 9 > 1 0 1 > 3 0 3 . > > The reason for the bug (and difference in behavior) is because LINENO > isn't treated as other variables are; it's value can't be looked up > using lookupvar() from var.c which is what arith() eventually does > when trying to find the value of a variable that isn't preceded by a > "$". > > So, the first thing I need to ask before I go any further is, what's > the expected behavior in the above conditions? > > // Paco > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Mon Jul 15 20:29:32 2019 Return-Path: Delivered-To: freebsd-hackers@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 023AFC2FB8 for ; Mon, 15 Jul 2019 20:29:32 +0000 (UTC) (envelope-from ryan@ixsystems.com) Received: from mail-yb1-xb42.google.com (mail-yb1-xb42.google.com [IPv6:2607:f8b0:4864:20::b42]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 3D83175B00 for ; Mon, 15 Jul 2019 20:29:31 +0000 (UTC) (envelope-from ryan@ixsystems.com) Received: by mail-yb1-xb42.google.com with SMTP id 187so6485463ybw.4 for ; Mon, 15 Jul 2019 13:29:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ixsystems-com.20150623.gappssmtp.com; s=20150623; h=mime-version:from:date:message-id:subject:to; bh=3zMWodrznKCILENsvIxsoynLon7wg1rNSrQ/NMku+gY=; b=R7pgPnqqNj0qorfrMsgpvplEDlxSdFzC9CGJxWK389LZshue0KIzQe6UDPe3ba1edg tzwc6QF8/6UgoEUWyK95K0JTmDgVM8/q3gwy8dtHveSzHNr8QJcAu+gMrbPXS4AaA3KH cl8TnY4Jy8w3AdbExmjQ2injC6JT4BcvzibRtwTfZsSBSfNMGdlraAlRjXv/KiUEQ4kU B0UUK8m72Cnpo6NQskrnl7lqvbfQq9nzlIW8ZR0bHom9e5aUr4vtUaJVP0CNuMuS5+09 gYPuSiE6ZRN4IHTcNVoOXg1NRIvECYeksrf3wgtWDBO+wrtiaZiSlhj3k/L9k9+DpNR3 tBLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=3zMWodrznKCILENsvIxsoynLon7wg1rNSrQ/NMku+gY=; b=Nq190PNaaPTKQH6GIBnpu/nZq5MH+hNW4xii19gm594VhrpLMyyS9KaXRE1VqHV6iC VS4Qufr6zdDr62y+aV6EJxrgqvMuZ32yvIF+AIluIPkJRIonq2d/pYicj15rG0fC3DCO 0jOEoOvie9Sx33Gukfsx4xq+0IFVV2TlKgFLbSjBP+qaoJIkTqnJua4Iiol8yNVqb7GB hkCTbx17UPeb+GyISg1to0JcR5Xm3hTJ74CKPR1eDxr0c2/tBCfizalnRi0fYZOEaSsC +WDYMV3mitZ+7YtOazifpaFCc2COoLVe68RP9QPVic5Ml1BiIvQBWsCEgCd8HNO5nl/C Cn+w== X-Gm-Message-State: APjAAAVEqL9m4DXr4gHm6pUlxSnusN9UEeRIDtMPT3NxldhYiblJ9qoq GuzA676GReJL3MzVgPq3wKtPPciNE1A9ujiX0a30ilwn51E= X-Google-Smtp-Source: APXvYqxBGK3AlYHbgmJTlXlj5hqeXDoPrv7nl8yj024spT3jiAy9WSAiIqJqLa3rnBVm6+2E7ZiI9MiztIrUJt+42dw= X-Received: by 2002:a25:4503:: with SMTP id s3mr17545546yba.380.1563222570476; Mon, 15 Jul 2019 13:29:30 -0700 (PDT) MIME-Version: 1.0 From: Ryan Moeller Date: Mon, 15 Jul 2019 16:29:19 -0400 Message-ID: Subject: Resetting console on boot To: freebsd-hackers@freebsd.org X-Rspamd-Queue-Id: 3D83175B00 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=ixsystems-com.20150623.gappssmtp.com header.s=20150623 header.b=R7pgPnqq; dmarc=pass (policy=none) header.from=ixsystems.com; spf=pass (mx1.freebsd.org: domain of ryan@ixsystems.com designates 2607:f8b0:4864:20::b42 as permitted sender) smtp.mailfrom=ryan@ixsystems.com X-Spamd-Result: default: False [-4.46 / 15.00]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; TO_DN_NONE(0.00)[]; DKIM_TRACE(0.00)[ixsystems-com.20150623.gappssmtp.com:+]; MX_GOOD(-0.01)[cached: ALT3.ASPMX.L.GOOGLE.com]; DMARC_POLICY_ALLOW(-0.50)[ixsystems.com,none]; NEURAL_HAM_SHORT(-0.54)[-0.539,0]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; IP_SCORE(-0.94)[ip: (0.96), ipnet: 2607:f8b0::/32(-3.17), asn: 15169(-2.44), country: US(-0.06)]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.96)[-0.964,0]; R_DKIM_ALLOW(-0.20)[ixsystems-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; RCVD_IN_DNSWL_NONE(0.00)[2.4.b.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Jul 2019 20:29:32 -0000 Hello, What do people think about having an early boot stage send some escape sequence to reset terminals to some sane default terminal settings? Often firmware or other causes will leave an unreadable font color or break line feeds, and the terminal tends to stay that way until a shell clears and resets the screen. If a shell can do it, surely loader could do it (or even earlier, if it is not too complex). To my knowledge it should be just a matter of printing some escape codes before starting the normal boot menus when using a serial console. I believe this is already done when the console is set to vidconsole or efi. Thoughts? Suggestions? -- Ryan Moeller iXsystems, Inc. OS Developer Email: ryan@iXsystems.com From owner-freebsd-hackers@freebsd.org Mon Jul 15 21:26:19 2019 Return-Path: Delivered-To: freebsd-hackers@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 3B250C432E for ; Mon, 15 Jul 2019 21:26:19 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from outbound2m.ore.mailhop.org (outbound2m.ore.mailhop.org [54.149.155.156]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BB1E480029 for ; Mon, 15 Jul 2019 21:26:18 +0000 (UTC) (envelope-from ian@freebsd.org) ARC-Seal: i=1; a=rsa-sha256; t=1563225976; cv=none; d=outbound.mailhop.org; s=arc-outbound20181012; b=PKoitZGFcZ6roq7koL8sLqrp93g2FY8ASc3smbs9brxtje7AtS6CLovTBqrQaGzeMvAPNrnLRTlFP WysRYYPlHUbubD4XM37apeuN/etIOHPOrR7PIJmj4xtMeJ2Cg5ncJht6R4YOAgx8KE83SPH+S6N/H9 PYlQKJhCfNh5p//4GHGUtHTYuhbim/3GHz6QgbJ8e6MrTpilP5MMnWQIITJHH57HLcopneJN+msMqH mQJX/MvSOA/R2U5ENC94j5x3lxMrp2uogSkJgFLk0Zcl8KHWsLcaA2ICpPZxAp0eI/miQ8VhEC3OFO bzDvo7moJ2Nwe7t45q+cf/SLq+5oS0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=outbound.mailhop.org; s=arc-outbound20181012; h=content-transfer-encoding:mime-version:content-type:references:in-reply-to: date:to:from:subject:message-id:dkim-signature:from; bh=VWrWpox1KQdbvgsnViex0fOlWNyrIlASAqblreCwzms=; b=JtepGHxqwrSVv4EFzjuYMXC9sKORXa/rSX4FdLwY/VnsHbz+NuZWnY/YdvoGLg+ZEBpKvL05IUtGC dq2Hn0qA2r8mnJekAo0NMmRveCY4Xeqf/PP7a0XVCzxbRw5IWlg1cpfMpH+kOaO5i/8sXVZlRa/oeX CaTyZ4o5wq2dNH7bCl7CZYYPat8+6TtABmQhSL8WhPWcbuvs6T1FNQGVOTkgIwlYWxG9Xhw+UI2aIs PUX0mIQjfu5rKuJAN25mH/o8fkKrktE+j/SxYHTTwf+Qblb1v1NfjZA9xcybcKkO6A7wwqeVEwG9nK AHT4X/7srhwEFeznv5MKqIzPet2qLEA== ARC-Authentication-Results: i=1; outbound4.ore.mailhop.org; spf=softfail smtp.mailfrom=freebsd.org smtp.remote-ip=67.177.211.60; dmarc=none header.from=freebsd.org; arc=none header.oldest-pass=0; DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outbound.mailhop.org; s=dkim-high; h=content-transfer-encoding:mime-version:content-type:references:in-reply-to: date:to:from:subject:message-id:from; bh=VWrWpox1KQdbvgsnViex0fOlWNyrIlASAqblreCwzms=; b=cOoHq8Dpi1vU5DvPZJpcBZWZn/sFKQLqTYQQa/jECqlEEETzqMvn/liV8VhTQM7IgE6uYVDRNuff1 kxKdmti98l7bNDmrlm0lzDdSDM49Ly1FgvPaQX/r2w0KtPnJAGqCi+iDwPVKJAtKrSOeJjFuwXmBqx 2UvQqNkAB72DKS+6foj4rddz6cvmh3Q+tC7ihgGUtBFJEk4bshJHdrfB1vyCl3YI3cxGgJAlDRGLM7 0TCEHkD5bVH7VjvS6aVmF3iflzNK5IDVavs22l1X5egkofrBp6P2OsYmy+fjvKKmjSZ/TtScibUXYQ cPRmVYeoJh77BlsED0iXcExfQ8Xg2pg== X-MHO-RoutePath: aGlwcGll X-MHO-User: 2c541381-a747-11e9-907a-1ba68abff17b X-Report-Abuse-To: https://support.duocircle.com/support/solutions/articles/5000540958-duocircle-standard-smtp-abuse-information X-Originating-IP: 67.177.211.60 X-Mail-Handler: DuoCircle Outbound SMTP Received: from ilsoft.org (unknown [67.177.211.60]) by outbound4.ore.mailhop.org (Halon) with ESMTPSA id 2c541381-a747-11e9-907a-1ba68abff17b; Mon, 15 Jul 2019 21:26:15 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.15.2) with ESMTP id x6FLQDql033488; Mon, 15 Jul 2019 15:26:13 -0600 (MDT) (envelope-from ian@freebsd.org) Message-ID: <1eab7d6a8ab3bb3670402ea888f223023841b98a.camel@freebsd.org> Subject: Re: Resetting console on boot From: Ian Lepore To: Ryan Moeller , freebsd-hackers@freebsd.org Date: Mon, 15 Jul 2019 15:26:13 -0600 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5 FreeBSD GNOME Team Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: BB1E480029 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.99 / 15.00]; local_wl_from(0.00)[freebsd.org]; NEURAL_HAM_MEDIUM(-1.00)[-0.998,0]; NEURAL_HAM_SHORT(-0.99)[-0.990,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; ASN(0.00)[asn:16509, ipnet:54.148.0.0/15, country:US] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Jul 2019 21:26:19 -0000 On Mon, 2019-07-15 at 16:29 -0400, Ryan Moeller wrote: > Hello, > > What do people think about having an early boot stage send some escape > sequence to reset terminals to some sane default terminal settings? Often > firmware or other causes will leave an unreadable font color or break line > feeds, and the terminal tends to stay that way until a shell clears and > resets the screen. If a shell can do it, surely loader could do it (or even > earlier, if it is not too complex). To my knowledge it should be just a > matter of printing some escape codes before starting the normal boot menus > when using a serial console. I believe this is already done when the > console is set to vidconsole or efi. > > Thoughts? Suggestions? > Your "sane" is my "who f*cked with my terminal setup?", so it needs to be optional. In my experience, the modern lua loader does send a reset and other control commands, for both serial and video consoles, unless you set beastie_disable=YES and loader_color=NO in loader.conf. Before I discovered the loader_color=NO, I hated that loader would always reset my serial terminal to white-on-black. -- Ian From owner-freebsd-hackers@freebsd.org Mon Jul 15 21:36:49 2019 Return-Path: Delivered-To: freebsd-hackers@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 EA59FC46B5 for ; Mon, 15 Jul 2019 21:36:49 +0000 (UTC) (envelope-from phk@critter.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4EBBB8084D; Mon, 15 Jul 2019 21:36:48 +0000 (UTC) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (v-critter.freebsd.dk [192.168.55.3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by phk.freebsd.dk (Postfix) with ESMTPS id 9801B1AF3DF; Mon, 15 Jul 2019 21:36:40 +0000 (UTC) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.15.2/8.15.2) with ESMTPS id x6FLaeL8014323 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Mon, 15 Jul 2019 21:36:40 GMT (envelope-from phk@critter.freebsd.dk) Received: (from phk@localhost) by critter.freebsd.dk (8.15.2/8.15.2/Submit) id x6FLadVD014322; Mon, 15 Jul 2019 21:36:39 GMT (envelope-from phk) To: Ian Lepore cc: Ryan Moeller , freebsd-hackers@freebsd.org Subject: Re: Resetting console on boot In-reply-to: <1eab7d6a8ab3bb3670402ea888f223023841b98a.camel@freebsd.org> From: "Poul-Henning Kamp" References: <1eab7d6a8ab3bb3670402ea888f223023841b98a.camel@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <14320.1563226599.1@critter.freebsd.dk> Content-Transfer-Encoding: quoted-printable Date: Mon, 15 Jul 2019 21:36:39 +0000 Message-ID: <14321.1563226599@critter.freebsd.dk> X-Rspamd-Queue-Id: 4EBBB8084D X-Spamd-Bar: - Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of phk@critter.freebsd.dk designates 130.225.244.222 as permitted sender) smtp.mailfrom=phk@critter.freebsd.dk X-Spamd-Result: default: False [-1.01 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.70)[-0.701,0]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; R_SPF_ALLOW(-0.20)[+mx]; NEURAL_HAM_LONG(-0.90)[-0.897,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[freebsd.dk]; TO_DN_SOME(0.00)[]; NEURAL_SPAM_SHORT(0.54)[0.537,0]; RCVD_COUNT_THREE(0.00)[4]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[phk.freebsd.dk]; IP_SCORE(0.06)[ip: (0.10), ipnet: 130.225.0.0/16(0.05), asn: 1835(0.15), country: EU(-0.01)]; FORGED_SENDER(0.30)[phk@phk.freebsd.dk,phk@critter.freebsd.dk]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:1835, ipnet:130.225.0.0/16, country:EU]; FROM_NEQ_ENVFROM(0.00)[phk@phk.freebsd.dk,phk@critter.freebsd.dk] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Jul 2019 21:36:50 -0000 -------- In message <1eab7d6a8ab3bb3670402ea888f223023841b98a.camel@freebsd.org>, I= an Le pore writes: >Your "sane" is my "who f*cked with my terminal setup?", = I agree in principle, but right now some combinations of our loaders leave a serial terminal with a scrolling region set and that is f*cked on an absolute scale... -- = Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe = Never attribute to malice what can adequately be explained by incompetence= . From owner-freebsd-hackers@freebsd.org Tue Jul 16 10:55:29 2019 Return-Path: Delivered-To: freebsd-hackers@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 7C749AC31E for ; Tue, 16 Jul 2019 10:55:29 +0000 (UTC) (envelope-from lev@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) server-signature RSA-PSS (4096 bits) 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 4E53B77437; Tue, 16 Jul 2019 10:55:29 +0000 (UTC) (envelope-from lev@FreeBSD.org) Received: from onlyone.not-for.work (onlyone.not-for.work [IPv6:2a01:4f8:201:6350::2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: lev/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id D94AAC275; Tue, 16 Jul 2019 10:55:28 +0000 (UTC) (envelope-from lev@FreeBSD.org) Received: from [192.168.23.186] (unknown [89.113.128.32]) (Authenticated sender: lev@serebryakov.spb.ru) by onlyone.not-for.work (Postfix) with ESMTPSA id 9948020F56; Tue, 16 Jul 2019 13:55:25 +0300 (MSK) Reply-To: lev@FreeBSD.org Subject: Re: Resetting console on boot To: Ryan Moeller , freebsd-hackers@freebsd.org References: From: Lev Serebryakov Openpgp: preference=signencrypt Autocrypt: addr=lev@FreeBSD.org; prefer-encrypt=mutual; keydata= mQINBFKbGksBEADeguVs+XyJc3mL3iiOBqDd16wSk97YTJYOi4VsHsINzJr09oFvNDiaDBIi fLn2p8XcJvehcsF2GSgrfXfw+uK4O1jyNIKJmiYA0EtE+ZbRtvDrrE0w6Q8+SDeKA21SWh3Y vSQ0DJUontbgW55ER2CbEiIUTIn34uQ0kmESAaw/v5p/9ue8yPTmURvv130FqPFz8VPzltqL NxyGt54TxPfKAzAHEIwxlEZ63JOwzloKh1UDBExcsf9nJO08/TAVgR5UZ5njFBPzaaquhRoP qPJLEQQDqxPIlvMNtHKf7iIebE4BHeqgCdJA0BoiR6gpa0wlsZtdrTPK3n4wYSphLvGbhfOZ YW/hbcu7HYS/FImkVxB3iY17kcC1UTnx4ZaYeASPBGOOPbXky1lLfmDGWIFT//70yx+G17qD OZzF1SvJJhGvh6ilFYaWMX7T+nIp6Mcafc4D7AakXM+XdubNXOMlCJhzPcZ0skgAEnYV587w V7em5fDVwQccwvtfezzqKeJAU5TGiywBHSR5Svzk2FwRNf6M//hWkpq0SRR63iOhkHGOAEBi 69GfEIwH2/w24rLxP0E+Hqq8n+EWNkPatw1Mhcl5PKkdvGCjJUaGNMkpBffjyYo254JXRscR eEnwdIkJt4ErDvjb2/UrOFq31wWMOiLzJeVchAgvTHBMRfP9aQARAQABtCFMZXYgU2VyZWJy eWFrb3YgPGxldkBGcmVlQlNELm9yZz6JAlYEEwEIAEACGwMHCwkIBwMCAQYVCAIJCgsEFgID AQIeAQIXgBYhBPltHKC19DGLZ0szCuqwPFi/3EePBQJb/TeXBQkPBbfGAAoJEOqwPFi/3EeP LtEQANQLS89OCDSnLDZLyCj7sH5GZbTikJp9Or2McqEOpjgtfY/OgqCe7lfo8f71tTN3gL2t VGtNEtsl6CqKeBdm6fqsetCAed2+waJfbXLZWReLRSFQJ/cbof8MB3h/uEw8Zng1ZbyEU0eG rc41Mhk8bTfxjNRjkXDbp0+2xug+eRr2RYhiY2SxH+iy57AbRIu9gkjfL05VztfvsV5dPxt7 +reHf2Vhtu+qCRtCytGQqDvYWGpVZ8U5fHJxFdsJpn66LAe8w+iRGCbppB5TKeHkqWqDb++u sd5ZHzwep/7qcLBeKggi8+a2C3J1J4TpYBwdPgusrGtBPf2EYSTc/0mW5j86g1l8UDN9qXAI FvWbKf22p5SlYUzf5qRLny4ZdDl1mH13lmJV7ZkZGMKnt0IjJ2x0LRgLGhiSm/D4Lh8yc/MX uhj9BB020XbWcMUPpA7S7YaWeIXbnK3NrPU0yk77prFJblfskOwuaxJIwa2mX+cCAQA95As5 2talifo4Kh8OLSvS1gpbMo64LllTzuGbCWuKecH3fpMlZlD7/10z9lBvkSXA7KgadDfN0yHO xGCK8KE9gXXmEVRlbgGDYOJw9FLWHuSZHUvQTkmr4goXrmMIKa9A4BKO3s9vowP4pJ0vp3kz MIBeEwKSvAeZZfgKbIKggKUuQ5gsAqvF360sG3+UuQINBFKbGksBEAC0a9wfjo2P3JyT7Lc+ QlbFVshGbSbazb4ma7QYG5IZZD5vfLBFkePoG6cnrn3WCXp4A43hszAynCwe4eXyAkv4+gPF 3ZSeNE5Wz3zYG+jh2nm2iGCkyaVykfbA+2chor2DKH5tHpuNMBlF+wSJHZKJmlo/sFIktAnV 1NBVg4/cL+9/hIpvl82cl3hYCD7/e7/qRE+w38CpAAzn65FvbODn7xlY3fsJt+cHPBJ4EBM9 KnTwcce+F+72RQMZQEl7vIAwSRmLdgZHN0MFC533l62SVoKjT0eaOOIBrvesmojhWjfwugib Xr+WRF/tGcW77Bxwe2eQLbEVESqWeMORxRxocx7Q7aACoHmf4G4U1Vzx7zUEfNfHjfjZeQVf AURf/MoUelZSW/BmMIfKCg3lRlWAt+Pq2h2UADPVqAZze45beE/c8z8LZsOZiGoRhYL8NSg6 +ziLTdmYLWdtFGAuZhqOtNp5h6tGj21OksBotcaIa5YjbCmmnImIjGlSBkUKvIhq/RXth5b2 gNwaQdu+Yv4AlZVHRsuVywL/skDFL5+We11bDK6MQ5PzvmntRJcgbyoisn1hiV04OV1LpJJM kJn1j8VlBqDQNT/z+BjB0ru/0anv+5uLj7v0ck06rEo4yiXT/ZAcBM76j7V7FaGbkoba6bUU CQ2H5YYBOKpikjCnpwARAQABiQI8BBgBCAAmAhsMFiEE+W0coLX0MYtnSzMK6rA8WL/cR48F Alv9N7IFCQ8Ft+cACgkQ6rA8WL/cR49wpw//W7QrZHKYUWEVHtPLVMlcM1f7MgwnYlIRe/I6 gykwvt87sqxSYu7eHxfX6JZR2M9UYuUYscSR57gxXKu2Uzqaz2KjvEIXJCwCTsuXZjkQ19oL hAPsucw2AcMI6YqPXbZ7hO0Mh8jMeJzD6vDvx3zvunQxGQoZKxr3BvRUyO7NCYbA7N8ccI3E Tmdjj9JTbtue9WaUeGLszFDiITmkASBdsK07y4ylLAJzUGCvYLBU3gx0bBOB2S8SbxHYmQlj ewjovbp+MbT+CoXNxZp+gDRModGyIMdRIotkRiDbgNl0VWIT0SS1GUUlUHKzQ/ZPUvpvk6Gq s/SYBS7rBQNSoXXmJxNW6I6atVNW7JhInC1tkHxBlbpik4FK07J6NHFTx+9ygyCxbxwNA/Le FGkL3kU0VFXR2dNiAVbeueUPF6tU5Bye5ftgpLKOSAbo1g++EKUkc8335/4oYRBMcGEk4xUr NAvzoFPhA2W3KtklruJ9ThrFt9+//NB5ySlVgTwGWMuBJoskEmNOTBv34/UQPUIuE4xSwy6y H+nRQJooiMFo5QCosslJPlwyV63NS9lYXB6n3QWOCP6sFdWACNUCOFv4uk7LQdY9BsCmt2Tk cLuHmoS+fvUesQXnYV2aQi9HciriPIj2gvJ6WjgiaC/PpePil0fzyrfG/JMyHL0qcgmYoj0= Organization: FreeBSD Message-ID: <721ab68d-cde4-41bb-c105-d15cf07903fa@FreeBSD.org> Date: Tue, 16 Jul 2019 13:55:18 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="grXAJDOzSzhqznQfibWhVIucPk1MXALwQ" X-Rspamd-Queue-Id: 4E53B77437 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.92 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; NEURAL_HAM_SHORT(-0.92)[-0.923,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; NEURAL_HAM_LONG(-1.00)[-1.000,0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 10:55:29 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --grXAJDOzSzhqznQfibWhVIucPk1MXALwQ Content-Type: multipart/mixed; boundary="Cg87AEtozegIdeyABaPYWrbNymp257Ap2"; protected-headers="v1" From: Lev Serebryakov Reply-To: lev@FreeBSD.org To: Ryan Moeller , freebsd-hackers@freebsd.org Message-ID: <721ab68d-cde4-41bb-c105-d15cf07903fa@FreeBSD.org> Subject: Re: Resetting console on boot References: In-Reply-To: --Cg87AEtozegIdeyABaPYWrbNymp257Ap2 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 15.07.2019 23:29, Ryan Moeller wrote: > What do people think about having an early boot stage send some escape > sequence to reset terminals to some sane default terminal settings? Oft= en > firmware or other causes will leave an unreadable font color or break l= ine > feeds, and the terminal tends to stay that way until a shell clears and= > resets the screen. If a shell can do it, surely loader could do it (or = even > earlier, if it is not too complex). To my knowledge it should be just a= > matter of printing some escape codes before starting the normal boot me= nus > when using a serial console. I believe this is already done when the > console is set to vidconsole or efi. >=20 > Thoughts? Suggestions? I've proposed this long ago for serial terminals: https://reviews.freebsd.org/D17102 https://reviews.freebsd.org/D17103 I have hardware which sets "black on black" before passing control to OS= =2E --=20 // Lev Serebryakov --Cg87AEtozegIdeyABaPYWrbNymp257Ap2-- --grXAJDOzSzhqznQfibWhVIucPk1MXALwQ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEE+W0coLX0MYtnSzMK6rA8WL/cR48FAl0trRxfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEY5 NkQxQ0EwQjVGNDMxOEI2NzRCMzMwQUVBQjAzQzU4QkZEQzQ3OEYACgkQ6rA8WL/c R4+MqQ//dPwj2ItGkK9QmdQUxsOeCnLMCETOJFdqycuSdRh5f2lWzSWK96K8e1Ec oxN6fWI4s+73rN99btXM5elh6Bx1b5wV0qhPIZPe3R1dQSXiGPTGyhRqIWXaLEpr 5euFtlqV5lce/1TUlpl7rK1edY7iAh+maZSkAPRurVeUydpbLtwj/X/W2DfSTc4l dOmut/0m+7k/2UlykSbhEcCkGSjKhR+UJRPRBOLSKBmyWtMBfptUbrcgqPEBjwtx hGzT2qVvh6Mba+XLgQ7qZLpemgKxzTyhZ/TaKxMcN1RcZS8LNYT9hxe0nOrGhsPK 775ybS4KMUc+loRbpVJR8gKw5MQ6r6OMjMWRCFUKySZy88EnurZ3DCjxpsjEyWNs MPAD9/ptOaPouXuU090aIptd8EfKliGi2k+SzjH192uwvehKkTNTMMLZMvm2tZrX brGM4DpJV2B26IUF6+r3CIM33IYXpa+osh8pIzaQyrRHRAJpB2Ukk1810089j1p7 MOG21uedd9AYmqyrf/JeWYqkhyoyBIi1kM2LmuI5HrdZUayNG8gx2GBKvTmfloQk 30nIJZCmKF5BeH4NNrf2SD1WYMwKlWAZefpOC/3sO0MeaGYtkHBHkVdotQoCCDbP gMM9IIhgqWLKmEvGTIzyQvwc3BuhT2aw9XyzQ+IrlejNKePdodQ= =gkBh -----END PGP SIGNATURE----- --grXAJDOzSzhqznQfibWhVIucPk1MXALwQ-- From owner-freebsd-hackers@freebsd.org Tue Jul 16 12:22:27 2019 Return-Path: Delivered-To: freebsd-hackers@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 16B23AE8F1 for ; Tue, 16 Jul 2019 12:22:27 +0000 (UTC) (envelope-from vijaykumar9597@gmail.com) Received: from mail-qt1-x82f.google.com (mail-qt1-x82f.google.com [IPv6:2607:f8b0:4864:20::82f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 9CD1182A87 for ; Tue, 16 Jul 2019 12:22:25 +0000 (UTC) (envelope-from vijaykumar9597@gmail.com) Received: by mail-qt1-x82f.google.com with SMTP id r6so15086896qtt.0 for ; Tue, 16 Jul 2019 05:22:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=UQw5WTWTI1loFbITSbkg4bOc1yA70SmpA/y7lu0sou4=; b=Ja2k2X47awdw697/gljtXFHm5/x+xazUIytcJip+OVc8dJHQlhjahcR6UBuI43esk/ QisDsOh2TI7DOIuci+O0pAENANxUDGhsIfIHcUwfX3Xawr2drmPCY+vI94Tj+H/ubVC7 bu8n+hycjdIX9xlB0IhfHsnSzsMKrcV3j3dye+bjCHHj6HvSs3Ioo7+i0EtAj9RnU2Jh /Az7tAA0PciO6E1cOEzzw/GT0XmY826VeqXt3Db1/W7GLA+vrAxxNuaOhn9Hp8i8lqjg zCMSI7et6Kwuz/VkFjZ+jzQ28GA5X+Ak5MEuoI/jcDlHJO9WjeHFqvCE1CzFu69pOE+A AWhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=UQw5WTWTI1loFbITSbkg4bOc1yA70SmpA/y7lu0sou4=; b=dYK2//oMgOCnlN8VcOlk4K78OVEgBwdd1emGQeSvAUGOEfifwz7IHhG25wLljztUpT 2gzQJyOj4wL+UkEDL1SuM4nvMRl8I8rxBgVrwLipsehVCUNcn3P552XVXirXEfYII45q qoPnwp0DSm9riQ70xmL5yO3NLbkOQ/JVt3S1j/Pr3rdotBsF/w13AAPQq2VJ+BpcVYZy UOWIgYRG5tYp5jq0H9qjs5DI1xLbt0O3MFVhGb1I0K3rHBRqjKipXTW5HuxK/6l5geVa DXSNZUWTkNpd5ieRmZEjG1ofrmWnzvBCoK6RS2vyqmtBvGW5xER7B+s/DC2+npj4tWUA GCtA== X-Gm-Message-State: APjAAAWLpYVudiO2HlU2HLGLzfbrBBINeCB16wbwScD+Hlqhx+EISyuC 1bh5NoGB0rCJNvZKWqOAX9uEfcG0J7QSbO2bsE49D69vVDo= X-Google-Smtp-Source: APXvYqxKmg/7XXM6vEZhh+RkKdselbfaY8hvPJZF4nve5YhFDcgXo17kx9UyCsxSC1+o6O6zpou9eKV7TeY0awYTUBE= X-Received: by 2002:ac8:359a:: with SMTP id k26mr21762768qtb.87.1563279744854; Tue, 16 Jul 2019 05:22:24 -0700 (PDT) MIME-Version: 1.0 From: Vijay Kumar Banerjee Date: Tue, 16 Jul 2019 17:52:13 +0530 Message-ID: Subject: Question regarding framebuffer driver. To: freebsd-hackers@freebsd.org X-Rspamd-Queue-Id: 9CD1182A87 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=Ja2k2X47; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of vijaykumar9597@gmail.com designates 2607:f8b0:4864:20::82f as permitted sender) smtp.mailfrom=vijaykumar9597@gmail.com X-Spamd-Result: default: False [-6.86 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.98)[-0.983,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCVD_TLS_LAST(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; RCVD_IN_DNSWL_NONE(0.00)[f.2.8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; IP_SCORE(-3.01)[ip: (-9.40), ipnet: 2607:f8b0::/32(-3.17), asn: 15169(-2.44), country: US(-0.06)]; NEURAL_HAM_SHORT(-0.86)[-0.856,0]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_TWO(0.00)[2]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 12:22:27 -0000 Hello everyone, I'm working on porting the framebuffer driver to RTEMS with Beaglebone Black as the target device. I have have already ported the am335x_lcd, tda19988, fbd and VT drivers, but the screen doesn't seem to "power up". >From the FreeBSD bootlog (12-RELEASE), I see that the screen is turning on after the VT initialization message, so I guess it's something that happens after the vt initialization that turns the screen on. So far I have ported the vt_fb and vt_core and it boots up well with the message : VT: initialize with new VT driver "fb". But the screen doesn't seem to turn on. Can someone please tell me or point me to the right place in code that is responsible for turning the screen on after VT initialization? Thank you, Vijay From owner-freebsd-hackers@freebsd.org Tue Jul 16 15:08:21 2019 Return-Path: Delivered-To: freebsd-hackers@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 40131B1D5E for ; Tue, 16 Jul 2019 15:08:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x733.google.com (mail-qk1-x733.google.com [IPv6:2607:f8b0:4864:20::733]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 4AF4D88FD6 for ; Tue, 16 Jul 2019 15:08:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x733.google.com with SMTP id 201so14825496qkm.9 for ; Tue, 16 Jul 2019 08:08:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=KrYwM5M7s3rGSrIeyA/oyqe7uQq7X0AlbsKpOamJ/Xo=; b=oLykKSIt9Nj+f05Ot8nztsW3rkHKmE2TZTKQzCn5m2nxRelOdjE8o33CrYr5ML+Y/S kvQFtFKabXll3Mlqn4pSjY6z4DyuMgclGHwPo+wTIeLOGKRDT5ZFjRh7n8IS2T0G2Tz8 GJByMmFItcNrabkOFCpYF3UZ5YtaXwoUqiifDixvVg1N0ncW7UT6sVwFwQI8og2p+IdV CcQd+aXMJEXyKKlpfViwDIzK8BEI1FP68tWFjytJPaY6Xq8aIGZYMXyAkeHLwZ2P7Yfl 9hEs8sMTABIeniaGFoN+YKkZQf/r6Wuqkisdyb1LF8OPYiSn+tUttSeqzLJffDA3coLg 7nJQ== 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=KrYwM5M7s3rGSrIeyA/oyqe7uQq7X0AlbsKpOamJ/Xo=; b=K6lVw58a6u5UMtH0qfa0IS9i7G4oNq9Y6MYvnylrYr4CmsUZckMIRdyuGZQR+teqzj rDvQWL+MussiCewiBhMPe/W9WK8V6JOahE00iyBVkGDQiCs89c5YOwxC5glSv3lrgEF7 z+ZfvRYcw1LMGi85HgopGpPmBZ9e7AQpncZnqBLA4kE2Vz8bRuK+GVFm7u98GDGTLIFZ RvApF95NIM2KdrOG69W7iKQKGUOC4W8Xk+AbKa5cPvWxmDftG9hfB3ZgWpskBIO4S/dU J4CF8Yj61R2YRvuUXSfmYBeDf5PXFXWbrTBaudK6rz0JgDyFQ/iFqkOSorsuyuanqDzo jUxw== X-Gm-Message-State: APjAAAVnpWpkOKFYH4kZ/ATSP4knNj7KCnUzWnAAp6bFNk00FXgB8Gwy zLoxwgib/OkyH0Sn7ekYUDYdUqHbYjQBzZa/pCY= X-Google-Smtp-Source: APXvYqxa3JL018pj+7YIzhfadKGM78GlYDpU89fM61lVoGSwx6zA+uBUZKWNWIkAdH2xklyCgQzGNFUX8nKrN0Zolg8= X-Received: by 2002:a05:620a:1017:: with SMTP id z23mr22512681qkj.60.1563289698260; Tue, 16 Jul 2019 08:08:18 -0700 (PDT) MIME-Version: 1.0 References: <721ab68d-cde4-41bb-c105-d15cf07903fa@FreeBSD.org> In-Reply-To: <721ab68d-cde4-41bb-c105-d15cf07903fa@FreeBSD.org> From: Warner Losh Date: Tue, 16 Jul 2019 09:08:06 -0600 Message-ID: Subject: Re: Resetting console on boot To: Lev Serebryakov Cc: Ryan Moeller , "freebsd-hackers@freebsd.org" X-Rspamd-Queue-Id: 4AF4D88FD6 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=oLykKSIt X-Spamd-Result: default: False [-5.62 / 15.00]; ARC_NA(0.00)[]; TO_DN_EQ_ADDR_SOME(0.00)[]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; NEURAL_HAM_MEDIUM(-0.96)[-0.958,0]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_DN_SOME(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: ALT1.aspmx.l.google.com]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; RCVD_IN_DNSWL_NONE(0.00)[3.3.7.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; NEURAL_HAM_SHORT(-0.65)[-0.645,0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; IP_SCORE(-3.01)[ip: (-9.37), ipnet: 2607:f8b0::/32(-3.17), asn: 15169(-2.45), country: US(-0.06)]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 15:08:21 -0000 On Tue, Jul 16, 2019 at 4:55 AM Lev Serebryakov wrote: > On 15.07.2019 23:29, Ryan Moeller wrote: > > > What do people think about having an early boot stage send some escape > > sequence to reset terminals to some sane default terminal settings? Often > > firmware or other causes will leave an unreadable font color or break > line > > feeds, and the terminal tends to stay that way until a shell clears and > > resets the screen. If a shell can do it, surely loader could do it (or > even > > earlier, if it is not too complex). To my knowledge it should be just a > > matter of printing some escape codes before starting the normal boot > menus > > when using a serial console. I believe this is already done when the > > console is set to vidconsole or efi. > > > > Thoughts? Suggestions? > > I've proposed this long ago for serial terminals: > > https://reviews.freebsd.org/D17102 > https://reviews.freebsd.org/D17103 > > I have hardware which sets "black on black" before passing control to OS. > That would work for the BIOS case, but not the UEFI case, which is where I see the biggest issues. Warner From owner-freebsd-hackers@freebsd.org Tue Jul 16 16:24:38 2019 Return-Path: Delivered-To: freebsd-hackers@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 D41CDB40C5 for ; Tue, 16 Jul 2019 16:24:38 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 956AD8E059 for ; Tue, 16 Jul 2019 16:24:38 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id 9338AB40C4; Tue, 16 Jul 2019 16:24:38 +0000 (UTC) Delivered-To: hackers@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 92F3CB40C3 for ; Tue, 16 Jul 2019 16:24:38 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x52c.google.com (mail-ed1-x52c.google.com [IPv6:2a00:1450:4864:20::52c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 088058E058 for ; Tue, 16 Jul 2019 16:24:38 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x52c.google.com with SMTP id k8so20868411edr.11 for ; Tue, 16 Jul 2019 09:24:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version :content-transfer-encoding; bh=60Efyn5JTvnIgyHksbj7kI3g3LOHf38GmDbthtRM2Rw=; b=PXr8gfLSu2d6cM/z6NWyqdLWUcER0rIxyf+lGEqfrKgndMfJz8Zx8KBd9F9Sj97Du8 5qDX81Je+7ARNGbREei4mpT73hW7BDsalt06eO9eYVOvPcnOp9LjNmUR7YQHK/h+tTK7 3/rQQEoWXzGHdg1meNWeC/V5fepn1VMCe3rkYf9bjRheVAuONLKztqUCozjkJaOeeOc2 qHfbVtds3K4zrHDIGuJIDOUibfa0Bs/TOAw0YoSGbFOt7rZQjmd8629FOKDSO92JRaGS p24nbMFn+Y0Mwk4cAszmWejqSeUftJF3vpCTha73sKZzWsinh1zaxO2Rlq0mW64O+8tJ or5Q== 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:mime-version :content-transfer-encoding; bh=60Efyn5JTvnIgyHksbj7kI3g3LOHf38GmDbthtRM2Rw=; b=arSr1fiWgY19G9LHnBJbj0odm2ePmn8yLAcZgzGrjoW/znLNszyAC9mz9LbMFDA9hk esYOXblLl1kmos6rmQDp3WkmCdKj/1SMQb8+1Oq+i1QeQoMAwJw3K6ZvgT9N9zPqR78x hz/2vrc812vuHd97XQorl52awe5PCKGzuWfn5xGB+SQfLjy8fhTg4SeeIln6NhIW5gHf qi4HfeAw2Pihnd72PNjNTT2YtV4SnS2ejv2gKbIkHMtgRRyJIOIE+lkn+BiP+Lwv8ClB QKv9I5FpvRxi2EPJyF/UE7K0EybOiiMYPe5vEfe3di12N/lOIpklblrWErTC4YSaobjV FFVw== X-Gm-Message-State: APjAAAXxADl7pJWlucwta3FZgkI0OlXZ7XfaIIbPOTidr2gM9OiEBdbA k+CiheJE6SnaBWjR8EilZaMkIblr X-Google-Smtp-Source: APXvYqybDS5xlzKvWZzlXkETZU9Ler+knPRgpvuvq0yQYUDfLQjw6iGvFGvIx3LuvIimqXVha7FvQg== X-Received: by 2002:a50:8be8:: with SMTP id n37mr30090700edn.216.1563294276916; Tue, 16 Jul 2019 09:24:36 -0700 (PDT) Received: from localhost ([213.149.52.156]) by smtp.gmail.com with ESMTPSA id n16sm6022182edo.81.2019.07.16.09.24.36 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 16 Jul 2019 09:24:36 -0700 (PDT) Date: Tue, 16 Jul 2019 18:23:50 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: hackers@freebsd.org Subject: Device's "stolen" sector Message-ID: <20190716182350.000054f8@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 088058E058 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=PXr8gfLS; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rank1seeker@gmail.com designates 2a00:1450:4864:20::52c as permitted sender) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-6.95 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; 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]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; NEURAL_HAM_SHORT(-0.97)[-0.970,0]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; 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)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[hackers@freebsd.org]; RCPT_COUNT_ONE(0.00)[1]; IP_SCORE(-2.97)[ip: (-9.44), ipnet: 2a00:1450::/32(-2.92), asn: 15169(-2.45), country: US(-0.06)]; RCVD_IN_DNSWL_NONE(0.00)[c.2.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 16:24:38 -0000 11.2-RELEASE-p9 Tested with >1 disks: -- SATA disk connected directly with SATA cable to MBO, shows correct amount o= f sectors. diskinfo -v ada1 When I connect it to the same MBO over USB to SATA adapter, 1 sector is mis= sing (the last one) diskinfo -v da0 Having last sector inaccessible is a huge problem as many "things" use it f= or a metadata. This has many times caused MBR disks occasionally to not be visible at all = while being 'da0' (gpart: No such geom: da0.) And also GPT disks to be in a [CORRUPT] state upon reattach directly to SAT= A interface. Before submitting a bug, there is only 1 variable left that I can't test, b= ecause I have only 1 USB to SATA adapter. It might be a hardware issue, so can someone else test this too? Domagoj Smol=C4=8Di=C4=87 From owner-freebsd-hackers@freebsd.org Tue Jul 16 16:45:21 2019 Return-Path: Delivered-To: freebsd-hackers@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 13197B49D0 for ; Tue, 16 Jul 2019 16:45:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id B0A668F7A6 for ; Tue, 16 Jul 2019 16:45:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mailman.nyi.freebsd.org (Postfix) id B035CB49CF; Tue, 16 Jul 2019 16:45:20 +0000 (UTC) Delivered-To: hackers@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 AFD97B49CE for ; Tue, 16 Jul 2019 16:45:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x72d.google.com (mail-qk1-x72d.google.com [IPv6:2607:f8b0:4864:20::72d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 917AA8F7A5 for ; Tue, 16 Jul 2019 16:45:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x72d.google.com with SMTP id d15so15103735qkl.4 for ; Tue, 16 Jul 2019 09:45:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=uK/84ajvIFJD5X6OL51D4WrJpdQ1l4UDvFV8IWDfjiU=; b=ESW82jJ96a0avHCi9KwkOMlUjGPg/7c7pdzXWFKrWrWvZacHTmj5b4+2D7PYEuFDoG sZFMb3UwgJE/wtpcQe8m2GW+1wc3k49DadOLp4J3izF3WN2OvdTSjHw0oMFz6aKe1tQM euWVopt4rBg+cw7fq8iwugVDLDWu6JW2j058+Wo31ztSPGmkBwGFbe2JNjVE8uItqN3F au3jByQ4r9hTKnFZ7cwX6A458gCM3dDr/ZCYAzTX73qeLt44Jqu2AJwLEuC/FLhf5CQl 8/pDOeGZGoh75mxy2pS5kn9zgvg+QvDaM0+UgCECiVBoJLX8XFru48Ez5jw6tYoKqVwB mBZg== 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=uK/84ajvIFJD5X6OL51D4WrJpdQ1l4UDvFV8IWDfjiU=; b=jWW1Khib/c6/XWKt8JyuAan9kBRRcKHEhix2CD0kTnZ2OR5rFwq+RxPBhNgemwiQe5 k9aXtRTMtCQHIW/UyVnkPrMsJV+cb2xHg6708T0Tvm+MViChlHJPga0lBZEVLdQEIGyR pL2ln5Ub9CE+v3UGfmLIS5ns4QRf0FyZ0Ni3HzlWj2+cI7kwRHQF1FugirnmB2ThqhXb U7SBEjbkW6Gj+h87bfbB9Vi/2YW4jEgwIty46rqxmZp0EELo/9ROAxmhfiplItT3VXHm TAGRtvkENIXumYQxN4lVPq5TKWD/XS+0P9qvY+aG/0XJJSFEI0PrK01TjWvWnhkrfnKg odZw== X-Gm-Message-State: APjAAAU8bHGMRIfTUqRN7RCPhS3tiZ8q8PNhVD95zHQ5qWifZ0aGyAMy GMDpQQ7Ei9+D0kkCupI6wPf8UvBNZTuLofLx3vM= X-Google-Smtp-Source: APXvYqx1wGLK6SVmHAK4g0LFrSLJkaiwOKbMdnSTZET2evaofQ0iqi0u3mej2ksoryHG97uXxtzoquj7OsviEco6yuo= X-Received: by 2002:a37:c87:: with SMTP id 129mr20245414qkm.240.1563295518943; Tue, 16 Jul 2019 09:45:18 -0700 (PDT) MIME-Version: 1.0 References: <20190716182350.000054f8@gmail.com> In-Reply-To: <20190716182350.000054f8@gmail.com> From: Warner Losh Date: Tue, 16 Jul 2019 10:45:07 -0600 Message-ID: Subject: Re: Device's "stolen" sector To: =?UTF-8?B?RG9tYWdvaiBTbW9sxI1pxIc=?= Cc: "freebsd-hackers@freebsd.org" X-Rspamd-Queue-Id: 917AA8F7A5 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.84 / 15.00]; NEURAL_HAM_MEDIUM(-0.99)[-0.988,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[]; NEURAL_HAM_SHORT(-0.85)[-0.851,0] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 16:45:21 -0000 On Tue, Jul 16, 2019 at 10:25 AM Domagoj Smol=C4=8Di=C4=87 wrote: > 11.2-RELEASE-p9 > > Tested with >1 disks: > -- > SATA disk connected directly with SATA cable to MBO, shows correct amount > of sectors. > diskinfo -v ada1 > > When I connect it to the same MBO over USB to SATA adapter, 1 sector is > missing (the last one) > diskinfo -v da0 > > Having last sector inaccessible is a huge problem as many "things" use it > for a metadata. > This has many times caused MBR disks occasionally to not be visible at al= l > while being 'da0' (gpart: No such geom: da0.) > And also GPT disks to be in a [CORRUPT] state upon reattach directly to > SATA interface. > > Before submitting a bug, there is only 1 variable left that I can't test, > because I have only 1 USB to SATA adapter. > It might be a hardware issue, so can someone else test this too? > On 11.x, I'd install the sg3_util port. You'll need the sg device in your kernel. Use sg_readcap on /dev/da0 to see if the numbers match the devinfo from ada1. If they match, then we have a bug in the da driver. If they differ, you have hardware issues in the USB to SATA adapter. Warner From owner-freebsd-hackers@freebsd.org Tue Jul 16 17:04:48 2019 Return-Path: Delivered-To: freebsd-hackers@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 90CB8B5281 for ; Tue, 16 Jul 2019 17:04:48 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 59F7069BCC for ; Tue, 16 Jul 2019 17:04:48 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: by mailman.nyi.freebsd.org (Postfix) id 57C60B5280; Tue, 16 Jul 2019 17:04:48 +0000 (UTC) Delivered-To: hackers@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 577E8B527F for ; Tue, 16 Jul 2019 17:04:48 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: from puchar.net (puchar.net [194.1.144.90]) (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 EBCFE69BCB for ; Tue, 16 Jul 2019 17:04:47 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: Received: from 127.0.0.1 (localhost [127.0.0.1]) by puchar.net (8.15.2/8.15.2) with ESMTPS id x6GGhQxA007056 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 16 Jul 2019 18:43:26 +0200 (CEST) (envelope-from puchar-wojtek@puchar.net) Received: from localhost (puchar-wojtek@localhost) by puchar.net (8.15.2/8.15.2/Submit) with ESMTP id x6GGhQXw007053; Tue, 16 Jul 2019 18:43:26 +0200 (CEST) (envelope-from puchar-wojtek@puchar.net) Date: Tue, 16 Jul 2019 18:43:26 +0200 (CEST) From: Wojciech Puchar To: =?ISO-8859-2?Q?Domagoj_Smol=E8i=E6?= cc: hackers@freebsd.org Subject: Re: Device's "stolen" sector In-Reply-To: <20190716182350.000054f8@gmail.com> Message-ID: References: <20190716182350.000054f8@gmail.com> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 X-Rspamd-Queue-Id: EBCFE69BCB X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.95 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-0.998,0]; NEURAL_HAM_SHORT(-0.95)[-0.952,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[] Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8BIT X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 17:04:48 -0000 On Tue, 16 Jul 2019, Domagoj Smolčić wrote: > 11.2-RELEASE-p9 > > Tested with >1 disks: > -- > SATA disk connected directly with SATA cable to MBO, shows correct amount of sectors. > diskinfo -v ada1 > > When I connect it to the same MBO over USB to SATA adapter, 1 sector is missing (the last one) > diskinfo -v da0 > > Having last sector inaccessible is a huge problem as many "things" use it for a metadata. > This has many times caused MBR disks occasionally to not be visible at all while being 'da0' (gpart: No such geom: da0.) > And also GPT disks to be in a [CORRUPT] state upon reattach directly to SATA interface. > > Before submitting a bug, there is only 1 variable left that I can't test, because I have only 1 USB to SATA adapter. > It might be a hardware issue, so can someone else test this too? > i have two external disk chassis with USB-SATA bridge, works just fine recently connected through it disk that was geli encrypted when directly connected to server. geli worked so all is fine as geli header is in last sector 11.2-STABLE From owner-freebsd-hackers@freebsd.org Tue Jul 16 17:09:43 2019 Return-Path: Delivered-To: freebsd-hackers@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 17871B53C3 for ; Tue, 16 Jul 2019 17:09:43 +0000 (UTC) (envelope-from rank1seeker@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 B3AB369E87 for ; Tue, 16 Jul 2019 17:09:42 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id B28EDB53C2; Tue, 16 Jul 2019 17:09:42 +0000 (UTC) Delivered-To: hackers@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 B2528B53C1 for ; Tue, 16 Jul 2019 17:09:42 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x52c.google.com (mail-ed1-x52c.google.com [IPv6:2a00:1450:4864:20::52c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 DB81669E86 for ; Tue, 16 Jul 2019 17:09:41 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x52c.google.com with SMTP id k21so21106432edq.3 for ; Tue, 16 Jul 2019 10:09:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version :content-transfer-encoding; bh=nEAIr3r28XDLt8XMS/jO6dbz9kQHwTt17LSkZpY8owA=; b=WHJyKEdTurWaT3uyHyKMHyUML12cmEDS2/GmTvVGWCUQfiakx/kj4aH8gWRBkmLo7z Q7k9yDPIRB95R1EOGRQeL6SFMCLHrJWosIZ/DQtvN3HCMC7Gu659mMyZE4I8podhRre/ tZKF52vYgg1tkBlSIlD1dhwy7vRHJxlHxFZdlgpfQUO3EjK5bIre6eRyBzdBrS4i2RFF c3AXQyRSaa98E1nlzHeLiKWg0JHMH9QR20rb7CpBz+7NHH3oPmCyzswOsjqg+oE2bU/I rbXqJnp9pjxd0YK8rnK2CzNahjJeh8Go4tItgGUiejvEuTWjgOG6e70eihdewe8Qi3GG rJEg== 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:mime-version :content-transfer-encoding; bh=nEAIr3r28XDLt8XMS/jO6dbz9kQHwTt17LSkZpY8owA=; b=IAwWdoldemmbMhUrRqoxo6kpC+giyYOR/8bI0H6pWlTXo3amIEf8xMq12/VuDqz+f/ HbfKDuWnsV1PoO38wactQNHgtL9VwVECBmEGwVV2Glec6fUUz+4bCD7bMiFnE5MZhD65 yrBC5+pKm2cwrdU5gpJaaCj+ZGjWWI2R0nLCfUCWJexCd5iSeb2cAEkOXi4GWibBXMIi HKGem/x8mf7G70S37xY9kmig9cicYeNvFPuCut4PDgF+MAYzVYAIUWFuHb/yvSGUp1Eh vKWT3k7M3UGaF9hrslapRDvJpsMxlY5k2FE5YFEP79qiZ6KLo9ePNMr4xSTjK8znjKDZ M4Zg== X-Gm-Message-State: APjAAAXC2FxEvGXNe0iAuAh8HD84qZONKUu5IPF+ZoVzclU9Q0XKb3xj o/2g6u2UVfp+sxK2ld4SUR3d3yMN X-Google-Smtp-Source: APXvYqwE7/WLQtL/CBMiwQKjX3Ic2An6k+yUHb2/qs/f0ZiICo2gf9kjyUqn4//Ivjhe2s3CYuooGw== X-Received: by 2002:a17:906:b211:: with SMTP id p17mr26607603ejz.11.1563296980650; Tue, 16 Jul 2019 10:09:40 -0700 (PDT) Received: from localhost ([213.149.52.156]) by smtp.gmail.com with ESMTPSA id e29sm5708680eda.51.2019.07.16.10.09.40 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 16 Jul 2019 10:09:40 -0700 (PDT) Date: Tue, 16 Jul 2019 19:08:54 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: hackers@freebsd.org Subject: For a first time completed S.M.A.R.T captive test Message-ID: <20190716190854.000061b2@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: B3AB369E87 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=WHJyKEdT; dmarc=pass (policy=none) header.from=gmail.com; spf=softfail (mx1.freebsd.org: 2610:1c1:1:606c::50:13 is neither permitted nor denied by domain of rank1seeker@gmail.com) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-4.78 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; FORGED_RECIPIENTS_FORWARDING(0.00)[]; FORWARDED(0.00)[hackers@mailman.nyi.freebsd.org]; FREEMAIL_FROM(0.00)[gmail.com]; SPF_FAIL_FORWARDING(0.00)[]; TO_DN_NONE(0.00)[]; R_SPF_SOFTFAIL(0.00)[~all]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(0.00)[gmail.com,none]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DMARC_POLICY_ALLOW_WITH_FAILURES(-0.50)[]; NEURAL_HAM_SHORT(-0.65)[-0.652,0]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; FORGED_RECIPIENTS(0.00)[hackers@freebsd.org,freebsd-hackers@freebsd.org]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.997,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; RCVD_COUNT_FIVE(0.00)[6]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; IP_SCORE(-1.42)[ip: (-0.15), ipnet: 2610:1c1:1::/48(-3.90), asn: 11403(-2.99), country: US(-0.06)]; RCPT_COUNT_ONE(0.00)[1] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 17:09:43 -0000 11.2-RELEASE-p9 =46rom the first time I started to use FreeBSD and upon to just recently, wit= h smartmontools, I have NEVER successfully completed captive test. No matter which HDD or smartmontools version I used, upon initiating 'Exten= ded captive' test, I would ALWAYS get error: 'Interrupted (host reset)' This implies nothing is being mounted from device, so only it's node exist = in /dev/ and nothing "chats" with it except kernel. Stopping smartd service also didn't help. Searching on the internet, I have never found anyone succeeding with it. Just a "solutions" that it should never be used?! So I started to think a little bit out of the box ... HDD has it's OWN board with it's OWN BIOS + firmware, which actually holds = S.M.A.R.T version/ability and IT executes issued test from OS, using it's o= wn firmware to actually run a test. Once HDD receives test request from OS, HDD doesn't need OS at all! So, in order to get rid of a results like: Num Test_Description Status Remaining LifeTime(ho= urs) LBA_of_first_error # 2 Extended captive Interrupted (host reset) 90% 40743 = - And suspecting OS (kernel?!) is pestering HDD during it's captive test, thu= s interrupting it, AS SOON as captive CMD is issued and hangs occurs (it is= too late when hang passes by itself!), I've pulled out SATA DATA cable and= left SATA POWER cable attached. Hang is stopped as soon as SATA DATA cable is unplugged and it's used only = to transfer test request anyway to HDD and all HDD needs from that point on= , is JUST a power and it's "piece of mind"! RESULT: -- SMART Self-test log structure revision number 1 Num Test_Description Status Remaining LifeTime(ho= urs) LBA_of_first_error # 1 Extended captive Completed without error 00% 40744 = - # 2 Extended captive Interrupted (host reset) 90% 40743 = - -- FINALLY! =3D=3D> '# 1 Extended captive Completed without error' So ..., what to conclude from this? Does kernel really must "chat" with HDD in order to keep alive it's device = node in /dev/ or is it something else? If HDD supports captive test and during it, why it simply doesn't ignore OS= /kernel (it is up to HDD's firmware code to make that decision). Is this, I'm not even sure how to name it ..., a borderline bug? Anyway, it is a little bit "impractical" to use terminal with one hand and = with other to pull out SATA data cable. Domagoj Smol=C4=8Di=C4=87 From owner-freebsd-hackers@freebsd.org Tue Jul 16 18:07:53 2019 Return-Path: Delivered-To: freebsd-hackers@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 D7352B69DC for ; Tue, 16 Jul 2019 18:07:53 +0000 (UTC) (envelope-from larry.maloney@hackerdojo.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 57AC46D333 for ; Tue, 16 Jul 2019 18:07:53 +0000 (UTC) (envelope-from larry.maloney@hackerdojo.com) Received: by mailman.nyi.freebsd.org (Postfix) id 5575CB69D9; Tue, 16 Jul 2019 18:07:53 +0000 (UTC) Delivered-To: hackers@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 551E4B69D8 for ; Tue, 16 Jul 2019 18:07:53 +0000 (UTC) (envelope-from larry.maloney@hackerdojo.com) Received: from mail-pf1-x444.google.com (mail-pf1-x444.google.com [IPv6:2607:f8b0:4864:20::444]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 F37496D330 for ; Tue, 16 Jul 2019 18:07:51 +0000 (UTC) (envelope-from larry.maloney@hackerdojo.com) Received: by mail-pf1-x444.google.com with SMTP id b13so9492911pfo.1 for ; Tue, 16 Jul 2019 11:07:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hackerdojo.com; s=google; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=5x7rM2jCKPCUUSBOQBoOe8IMrQgrK1h3IZCn1C9Tc/g=; b=BH67N1MJeR6b/j2AkHwRKG9WzCMP4GuaLLlJnOPCxyMHjXVuNrddOIbY0nxjpsPns9 HADF5LrHINXyTYX8iVuq8CtiF0SmEkx0Dgvbil8eQpgGjNVzOfVw1TB9iGsZDS83CIOE UGloxPMrjXwFAOOcOEI2xynCFsrz0rfJqVI5U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=5x7rM2jCKPCUUSBOQBoOe8IMrQgrK1h3IZCn1C9Tc/g=; b=kwqXWp4AACh+afP0cyp+4bggd5gjH7o6UQaD/oov+cfQCANbZwMBg32Cf8exMsMXNN XO6sHODfeXwKJecBMlqqrwdm/IoYz827ujKkVh+8PTIfclcTNBjWchSRc9JqmnkBBZjp 4z7i72nBfj/FH7hGT1cAN3K8SauzPUmdlLRbBX/UkBttu4QXvkebo07ZCKT+x1XgKEEq 8T3LoL7sflE8TqIrYiIxbjFV1OLKRjYiSfxk4xVjgCgWsxqAEMdcnxlgSDDMCNj8IozI iBQugJNAWTyi3lQYIEr1BZPmo3WMNcqOH/1Uh6ETzhaAp1VBGo114xeF2MUHkUpiGD9I rgyw== X-Gm-Message-State: APjAAAXCsflLPg6PSI0SkhSpT5nVKe57ILv9/I7kSQLzUV5Newiw7XU8 EyZXmQEhpzgkEJ3LQnI2urCcMGA3JYZcTPqp X-Google-Smtp-Source: APXvYqywjaJVRsMAfnyiwaz+SndNfOEjtV5uXAAe1ghglMCfGPzvdALJSyixpJQyH4F0I/sijRaDjA== X-Received: by 2002:a65:4786:: with SMTP id e6mr34858030pgs.448.1563300470249; Tue, 16 Jul 2019 11:07:50 -0700 (PDT) Received: from [192.168.1.140] ([73.162.69.0]) by smtp.gmail.com with ESMTPSA id m9sm39289205pgr.24.2019.07.16.11.07.48 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 16 Jul 2019 11:07:48 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (1.0) Subject: Re: For a first time completed S.M.A.R.T captive test From: Larry Maloney X-Mailer: iPhone Mail (16F250) In-Reply-To: <20190716190854.000061b2@gmail.com> Date: Tue, 16 Jul 2019 11:07:47 -0700 Cc: hackers@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <20190716190854.000061b2@gmail.com> To: =?utf-8?Q?Domagoj_Smol=C4=8Di=C4=87?= X-Rspamd-Queue-Id: 57AC46D333 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=hackerdojo.com header.s=google header.b=BH67N1MJ; spf=softfail (mx1.freebsd.org: 2610:1c1:1:606c::50:13 is neither permitted nor denied by domain of larry.maloney@hackerdojo.com) smtp.mailfrom=larry.maloney@hackerdojo.com X-Spamd-Result: default: False [-4.11 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; FORGED_RECIPIENTS_FORWARDING(0.00)[]; FORWARDED(0.00)[hackers@mailman.nyi.freebsd.org]; TO_DN_SOME(0.00)[]; MV_CASE(0.50)[]; SPF_FAIL_FORWARDING(0.00)[]; R_SPF_SOFTFAIL(0.00)[~all]; DKIM_TRACE(0.00)[hackerdojo.com:+]; MX_GOOD(-0.01)[cached: alt1.aspmx.l.google.com]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.99)[-0.985,0]; FREEMAIL_TO(0.00)[gmail.com]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; IP_SCORE(-1.42)[ip: (-0.14), ipnet: 2610:1c1:1::/48(-3.90), asn: 11403(-2.99), country: US(-0.06)]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; FORGED_RECIPIENTS(0.00)[hackers@freebsd.org ..,freebsd-hackers@freebsd.org]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.996,0]; R_DKIM_ALLOW(-0.20)[hackerdojo.com:s=google]; RCVD_COUNT_FIVE(0.00)[6]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; DMARC_NA(0.00)[hackerdojo.com] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 18:07:53 -0000 It=E2=80=99s been a while,so I could be wrong, but I seem to recall having t= o unmount the device before testing. /Larry Sent from my iPhone > On Jul 16, 2019, at 10:08 AM, Domagoj Smol=C4=8Di=C4=87 wrote: >=20 > 11.2-RELEASE-p9 >=20 > =46rom the first time I started to use FreeBSD and upon to just recently, w= ith smartmontools, I have NEVER successfully completed captive test. > No matter which HDD or smartmontools version I used, upon initiating 'Exte= nded captive' test, I would ALWAYS get error: 'Interrupted (host reset)' > This implies nothing is being mounted from device, so only it's node exist= in /dev/ and nothing "chats" with it except kernel. > Stopping smartd service also didn't help. >=20 > Searching on the internet, I have never found anyone succeeding with it. > Just a "solutions" that it should never be used?! >=20 > So I started to think a little bit out of the box ... > HDD has it's OWN board with it's OWN BIOS + firmware, which actually holds= S.M.A.R.T version/ability and IT executes issued test from OS, using it's o= wn firmware to actually run a test. > Once HDD receives test request from OS, HDD doesn't need OS at all! >=20 > So, in order to get rid of a results like: > Num Test_Description Status Remaining LifeTime(ho= urs) LBA_of_first_error > # 2 Extended captive Interrupted (host reset) 90% 40743 = - >=20 > And suspecting OS (kernel?!) is pestering HDD during it's captive test, th= us interrupting it, AS SOON as captive CMD is issued and hangs occurs (it is= too late when hang passes by itself!), I've pulled out SATA DATA cable and l= eft SATA POWER cable attached. > Hang is stopped as soon as SATA DATA cable is unplugged and it's used only= to transfer test request anyway to HDD and all HDD needs from that point on= , is JUST a power and it's "piece of mind"! > RESULT: > -- > SMART Self-test log structure revision number 1 > Num Test_Description Status Remaining LifeTime(ho= urs) LBA_of_first_error > # 1 Extended captive Completed without error 00% 40744 = - > # 2 Extended captive Interrupted (host reset) 90% 40743 = - > -- >=20 > FINALLY! =3D=3D> '# 1 Extended captive Completed without error' >=20 > So ..., what to conclude from this? > Does kernel really must "chat" with HDD in order to keep alive it's device= node in /dev/ or is it something else? > If HDD supports captive test and during it, why it simply doesn't ignore O= S/kernel (it is up to HDD's firmware code to make that decision). >=20 > Is this, I'm not even sure how to name it ..., a borderline bug? >=20 > Anyway, it is a little bit "impractical" to use terminal with one hand and= with other to pull out SATA data cable. >=20 >=20 > Domagoj Smol=C4=8Di=C4=87 > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"= From owner-freebsd-hackers@freebsd.org Tue Jul 16 19:27:56 2019 Return-Path: Delivered-To: freebsd-hackers@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 000FEB85DE for ; Tue, 16 Jul 2019 19:27:55 +0000 (UTC) (envelope-from wlosh@bsdimp.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 D658C70C8A for ; Tue, 16 Jul 2019 19:27:55 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mailman.nyi.freebsd.org (Postfix) id D5DEEB85DD; Tue, 16 Jul 2019 19:27:55 +0000 (UTC) Delivered-To: hackers@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 D59D0B85DC for ; Tue, 16 Jul 2019 19:27:55 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x82a.google.com (mail-qt1-x82a.google.com [IPv6:2607:f8b0:4864:20::82a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 B633870C89 for ; Tue, 16 Jul 2019 19:27:55 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x82a.google.com with SMTP id d17so20771241qtj.8 for ; Tue, 16 Jul 2019 12:27:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=3RuKgS7SAG7AZppToyzCl5DGlo2kF3lqyM6Dx6LcBCY=; b=v6rP4nAtOFCFAl3OBUR+VZh0EauT/XYrYH+NjrdEBomMWvP5y8JChlwDHdB9Dyyyuj ZJDjCsFcryYJfsjzCd2U/Mmsei93xJ8h0ueM0rYVBaghDDfe2QiOo2YNOED4CUXWsgrZ 4STPtiGgxBiuMU8K7yJCaxMq9BmUfSHTzAeDtvoJXXyWqxMilnS+gs6K9DeEn6SlgJkv 6alln9kAca45o35pI7szRB3hZydb9rxjbPM2gA/nsiUSfusmMIV1G9+g5cJwUx8OWblZ llGsX+M7EZeHLf1v63FqZvMAWtiIpv5flGgsrdi5CLhEAtkx6/gH9pdKZ2SO+mYFDrq9 jRhA== 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=3RuKgS7SAG7AZppToyzCl5DGlo2kF3lqyM6Dx6LcBCY=; b=XgDE0QO8BH4UjZ6k/PXK/rHrz7sqM5kgPOuANkviLIHvJEgbx+tQeNdDGtjcDHe2AK QsBhTqWqCZcGzabS3yHp/vIwDEOCws1XwyHCeJMK6SYH856KPJpA6CWxF9O7SzAh44qw dRQMVrTiiKRy95GWr36rBEOabpoDboqeHo+RJiOQigMHrVAa4mdiU1MOvmE3v7mbO+4m UF0YhKxOS8kAwZjT/rKmLMdwH0disehnfbnpbZgesHnndgLmQ9df32uiOocTVnOv5Yj5 LJVI7QnSn9iHA9+GVisKRZ57223Ex2H8Ctg1dtcjhe4GTYkCKElNJp91AhtKFneo2JOy xKwg== X-Gm-Message-State: APjAAAVF1ZPcoAQKVT0hFfLZJ5uKch+fROQh2shN3K80ns5JaoXq+0DK fIl4GPc2sIMe5PamZU62qJTl07VnZvb7tZjxUAffKw== X-Google-Smtp-Source: APXvYqzh7C7x41NOg05nGs8oF6QLX0cjRjj+B52RCNQDoQWeMvxWfA2O525QAdDJvpViVcnRdwnI6yvbtfi/R9O8COM= X-Received: by 2002:aed:34a6:: with SMTP id x35mr24359316qtd.187.1563305274822; Tue, 16 Jul 2019 12:27:54 -0700 (PDT) MIME-Version: 1.0 References: <20190716182350.000054f8@gmail.com> In-Reply-To: From: Warner Losh Date: Tue, 16 Jul 2019 13:27:43 -0600 Message-ID: Subject: Re: Device's "stolen" sector To: Wojciech Puchar Cc: =?UTF-8?B?RG9tYWdvaiBTbW9sxI1pxIc=?= , "freebsd-hackers@freebsd.org" X-Rspamd-Queue-Id: D658C70C8A X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.99 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; NEURAL_HAM_SHORT(-0.99)[-0.993,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 19:27:56 -0000 On Tue, Jul 16, 2019 at 11:05 AM Wojciech Puchar wrote: > > > On Tue, 16 Jul 2019, Domagoj Smol=C4=8Di=C4=87 wrote: > > > 11.2-RELEASE-p9 > > > > Tested with >1 disks: > > -- > > SATA disk connected directly with SATA cable to MBO, shows correct > amount of sectors. > > diskinfo -v ada1 > > > > When I connect it to the same MBO over USB to SATA adapter, 1 sector is > missing (the last one) > > diskinfo -v da0 > > > > Having last sector inaccessible is a huge problem as many "things" use > it for a metadata. > > This has many times caused MBR disks occasionally to not be visible at > all while being 'da0' (gpart: No such geom: da0.) > > And also GPT disks to be in a [CORRUPT] state upon reattach directly to > SATA interface. > > > > Before submitting a bug, there is only 1 variable left that I can't > test, because I have only 1 USB to SATA adapter. > > It might be a hardware issue, so can someone else test this too? > > > i have two external disk chassis with USB-SATA bridge, works just fine > > recently connected through it disk that was geli encrypted when directly > connected to server. geli worked so all is fine as geli header is in last > sector > It all depends... There's huge variation in the quality of USB-SATA bridges. Some get in the way and do things like round off the last sector when the reported capacity is odd, for example. Which is why I'm trying to see if there's an issue with that, or if the issue is something in the da driver. For drives with an even number of sectors, there's likely no issues at all... Warner From owner-freebsd-hackers@freebsd.org Tue Jul 16 20:44:21 2019 Return-Path: Delivered-To: freebsd-hackers@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 4D324B9F5C for ; Tue, 16 Jul 2019 20:44:21 +0000 (UTC) (envelope-from rank1seeker@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 E6048743B7 for ; Tue, 16 Jul 2019 20:44:20 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id E59A3B9F5B; Tue, 16 Jul 2019 20:44:20 +0000 (UTC) Delivered-To: hackers@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 E55B8B9F5A for ; Tue, 16 Jul 2019 20:44:20 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 28055743B5 for ; Tue, 16 Jul 2019 20:44:20 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x542.google.com with SMTP id r12so21918944edo.5 for ; Tue, 16 Jul 2019 13:44:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=cSM0JCTszuZxjvWxThjsxEWya/KM4CJjWUtRdBWjnvU=; b=MOCPt8qinPPpAxQtiPWF1ASeDNs9d3MY7v9EzkfKPM1ywh5E2J5vIruGhvDbh/oSlJ 5CzCgzepprrnOorVk/0WWuaicUo8IqF+KkOVeNYuqFZmI3vSr39kuS25jX/oHwfgsjvS wJR/DyBk+iv6pWyBHRDlBz+s+5j9NGsn0YgTISJphRSQ1HCIEGAT3CSAw/5XfZUHcB0Q ZW9N25VCUq3oi40Xq9LVIJmvR0oqbPsxbPGiT8oQYdZWf0z6AJBFHkqXtpMdO4kwFy2s PgnjHL48VNgTwR5Nxc5y9iT+k/0Fmd2OS3cm5dyt0toxliixlB7tGUNpAmw3giRBemri SYlw== 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:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=cSM0JCTszuZxjvWxThjsxEWya/KM4CJjWUtRdBWjnvU=; b=HMmaDvMWk6yekrBpO9SGoQb1UEucZLykWyd7sPQZcd8k55ssxl7unH3YMOnFYXcnCt LgjLcLIQiwd1g7abunWLWEjFOgOyyfZe+AYQehSjPWCeD+2OfRKIIBmmGDCcvKWci75A yDQ246y6epLGCcTUajYFZ5AKng0sD3PhV0ajM9WkBFEDYa5GIzg3X+saXsWAXKqjvJJD JC5llIJ5KllnVe+0NZYfYOgW0JpdYkoTd9osflRQtc2k5I8xwITdw6/hbKYbmYbR8UpJ w9lPkeHe+tsxlJL+KjKa3xJGjDLWuj4+BuGh6bCR3YrzKoZWEvCsK7sPgoP/ta8MVBQr eZHA== X-Gm-Message-State: APjAAAXOjkyJfew64iZiukNG+TW+Aln1lphLchPFExxn/sZsdQIxUlog eh3jp3axQR3f+ZyK1XTmIHc= X-Google-Smtp-Source: APXvYqxB+fArMkWdmYeXUSw2bY8Ysyeln8Yfd57n10Fg0NLeWwNJldEMsdiAeIjPfJGYKMHTFzdZEQ== X-Received: by 2002:a17:907:20a6:: with SMTP id pw6mr17828351ejb.111.1563309859101; Tue, 16 Jul 2019 13:44:19 -0700 (PDT) Received: from localhost ([213.149.52.156]) by smtp.gmail.com with ESMTPSA id h15sm6436136edb.57.2019.07.16.13.44.18 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 16 Jul 2019 13:44:18 -0700 (PDT) Date: Tue, 16 Jul 2019 22:43:32 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: Warner Losh Cc: Wojciech Puchar , hackers@freebsd.org Subject: Re: Device's "stolen" sector Message-ID: <20190716224332.00000326@gmail.com> In-Reply-To: References: <20190716182350.000054f8@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: E6048743B7 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=MOCPt8qi; dmarc=pass (policy=none) header.from=gmail.com; spf=softfail (mx1.freebsd.org: 2610:1c1:1:606c::50:13 is neither permitted nor denied by domain of rank1seeker@gmail.com) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-5.13 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; FORGED_RECIPIENTS_FORWARDING(0.00)[]; FORWARDED(0.00)[hackers@mailman.nyi.freebsd.org]; TO_DN_SOME(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; SPF_FAIL_FORWARDING(0.00)[]; R_SPF_SOFTFAIL(0.00)[~all]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(0.00)[gmail.com,none]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DMARC_POLICY_ALLOW_WITH_FAILURES(-0.50)[]; NEURAL_HAM_SHORT(-0.83)[-0.829,0]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; FORGED_RECIPIENTS(0.00)[imp@bsdimp.com ..,freebsd-hackers@freebsd.org]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; RCVD_COUNT_FIVE(0.00)[6]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; IP_SCORE(-1.59)[ip: (-1.03), ipnet: 2610:1c1:1::/48(-3.90), asn: 11403(-2.99), country: US(-0.06)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 20:44:21 -0000 On Tue, 16 Jul 2019 13:27:43 -0600 Warner Losh wrote: > On Tue, Jul 16, 2019 at 11:05 AM Wojciech Puchar > wrote: >=20 > > > > > > On Tue, 16 Jul 2019, Domagoj Smol=C4=8Di=C4=87 wrote: > > =20 > > > 11.2-RELEASE-p9 > > > > > > Tested with >1 disks: > > > -- > > > SATA disk connected directly with SATA cable to MBO, shows > > > correct =20 > > amount of sectors. =20 > > > diskinfo -v ada1 > > > > > > When I connect it to the same MBO over USB to SATA adapter, 1 > > > sector is =20 > > missing (the last one) =20 > > > diskinfo -v da0 > > > > > > Having last sector inaccessible is a huge problem as many > > > "things" use =20 > > it for a metadata. =20 > > > This has many times caused MBR disks occasionally to not be > > > visible at =20 > > all while being 'da0' (gpart: No such geom: da0.) =20 > > > And also GPT disks to be in a [CORRUPT] state upon reattach > > > directly to =20 > > SATA interface. =20 > > > > > > Before submitting a bug, there is only 1 variable left that I > > > can't =20 > > test, because I have only 1 USB to SATA adapter. =20 > > > It might be a hardware issue, so can someone else test this too? > > > =20 > > i have two external disk chassis with USB-SATA bridge, works just > > fine > > > > recently connected through it disk that was geli encrypted when > > directly connected to server. geli worked so all is fine as geli > > header is in last sector > > =20 >=20 > It all depends... There's huge variation in the quality of USB-SATA > bridges. Some get in the way and do things like round off the last > sector when the reported capacity is odd, for example. Which is why > I'm trying to see if there's an issue with that, or if the issue is > something in the da driver. For drives with an even number of > sectors, there's likely no issues at all... >=20 > Warner >=20 Well, I've installed sysutils/sg3_utils, but required sg device will have t= o wait, as I can't recompile kernel ATM. Regarding quality ..., this one was so cheap that I've got it for free. ;) Regarding capacity ..., HDD has EVEN number of sectors. Last HDD checked (just before posting) Hitachi: =3D=3D=3D=3D=3D=3D=3D=3D # diskinfo -v ada1 | awk '/mediasize in sectors/{print $1}' 312581808 # gpart show -p ada1 =3D> 63 312581745 ada1 MBR (149G) 312581745 + 63 =3D 312581808 All OK! # diskinfo -v da0 | awk '/mediasize in sectors/{print $1}' 312581807 # gpart show -p da0 gpart: No such geom: da0. Showed nothing (usually it does even in this cases) Domagoj Smol=C4=8Di=C4=87 From owner-freebsd-hackers@freebsd.org Tue Jul 16 21:34:59 2019 Return-Path: Delivered-To: freebsd-hackers@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 D51EBBB04E for ; Tue, 16 Jul 2019 21:34:59 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 98C9776351 for ; Tue, 16 Jul 2019 21:34:59 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mailman.nyi.freebsd.org (Postfix) id 98423BB04D; Tue, 16 Jul 2019 21:34:59 +0000 (UTC) Delivered-To: hackers@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 97F4CBB04C for ; Tue, 16 Jul 2019 21:34:59 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x72d.google.com (mail-qk1-x72d.google.com [IPv6:2607:f8b0:4864:20::72d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 B9A557634E for ; Tue, 16 Jul 2019 21:34:58 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x72d.google.com with SMTP id v22so15815645qkj.8 for ; Tue, 16 Jul 2019 14:34:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Ln6HA7s00YCMCJv3L3Rp9oQswctk2i2KOicjLzGm6uI=; b=hGwqDcIZYlu3L9k7FFaRDaP4+Rp6w/KBRmXKt5UnOtVmxlDTum3LihS5W21a9KWV6k CO8eQKQKMB3AlzTO1/enNWvOX3r9GofIHstD0Khu5ET2Y0E2nfo9xOxqbJkE1bSTdrUG Srymi1qmaClC+H485d+y24bpmHDOUU+ecGf5jiUUYacPIV2yKVfl3gqH50mcbAzIuFUO 9HdU9ArSwfDXRUTrciTTQtQc66bk/HXbwrcZHHCwbRwLroxjB2jnZK1JwQQJZm02+4ad V42y7AH7e5DfjpV08Pf4GQf7yBcoBYg+Lf4IDKkx4U9rHp5k9ck61t+ezGNA73vZtB7Q V+bg== 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=Ln6HA7s00YCMCJv3L3Rp9oQswctk2i2KOicjLzGm6uI=; b=FV7PuG/RcUNfoTIeLfW1zVYyYZgPRSopG3HFrEv7/+Lc/XWCsAlwJGcP9zKQdlcouB ipBVqpH5cCdjMQk3Er0bvSbJzR6bRyPq4KFmRc/4RZYzBQnGKorIGxFlTh5o3aDxcVgJ iR90InsBzIWbXWZ+0zFMn1L4sNaBZ7eKFWLiiFzy65Qv3o1Vs1ctGOG9vn5J/rDCFWx3 M48DByFDvgNU8nP2KNmocjxIPXhCGQ+2h+UChdning9MQlSnjKOitZJqfTkRsOkr+7PW Vh4PBN7G4iOK1i1l2JGB7tYNqKD1BXeBohGDuQ/2nNBz8YrJ4o8GYro7wav8ggGPnidi zL7w== X-Gm-Message-State: APjAAAXyHLgOfotIXAkpy6n+ML29F+DMAEzos6bpoadtKJw68k7aoZpm p84bDeCrLQPJcxzbyouoFB8sc8k//ejA4slP0W40lQ== X-Google-Smtp-Source: APXvYqy7NRHUCBR2LxtwwK2tOukgvrSavcs6PqDWK28WBjIK4Qb7maN8RumVP9Op9ZZps65UkOlgruJi0x3Gix0Rm5w= X-Received: by 2002:a37:9307:: with SMTP id v7mr13232112qkd.495.1563312898028; Tue, 16 Jul 2019 14:34:58 -0700 (PDT) MIME-Version: 1.0 References: <20190716182350.000054f8@gmail.com> <20190716224332.00000326@gmail.com> In-Reply-To: <20190716224332.00000326@gmail.com> From: Warner Losh Date: Tue, 16 Jul 2019 15:34:47 -0600 Message-ID: Subject: Re: Device's "stolen" sector To: =?UTF-8?B?RG9tYWdvaiBTbW9sxI1pxIc=?= Cc: Wojciech Puchar , "freebsd-hackers@freebsd.org" X-Rspamd-Queue-Id: B9A557634E X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=hGwqDcIZ X-Spamd-Result: default: False [-5.51 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.95)[-0.953,0]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[hackers@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; MX_GOOD(-0.01)[cached: ALT1.aspmx.l.google.com]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; RCVD_IN_DNSWL_NONE(0.00)[d.2.7.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; NEURAL_HAM_SHORT(-0.53)[-0.528,0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; FREEMAIL_TO(0.00)[gmail.com]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; IP_SCORE(-3.02)[ip: (-9.41), ipnet: 2607:f8b0::/32(-3.17), asn: 15169(-2.45), country: US(-0.06)]; 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.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Jul 2019 21:34:59 -0000 On Tue, Jul 16, 2019 at 2:44 PM Domagoj Smol=C4=8Di=C4=87 wrote: > On Tue, 16 Jul 2019 13:27:43 -0600 > Warner Losh wrote: > > > On Tue, Jul 16, 2019 at 11:05 AM Wojciech Puchar > > wrote: > > > > > > > > > > > On Tue, 16 Jul 2019, Domagoj Smol=C4=8Di=C4=87 wrote: > > > > > > > 11.2-RELEASE-p9 > > > > > > > > Tested with >1 disks: > > > > -- > > > > SATA disk connected directly with SATA cable to MBO, shows > > > > correct > > > amount of sectors. > > > > diskinfo -v ada1 > > > > > > > > When I connect it to the same MBO over USB to SATA adapter, 1 > > > > sector is > > > missing (the last one) > > > > diskinfo -v da0 > > > > > > > > Having last sector inaccessible is a huge problem as many > > > > "things" use > > > it for a metadata. > > > > This has many times caused MBR disks occasionally to not be > > > > visible at > > > all while being 'da0' (gpart: No such geom: da0.) > > > > And also GPT disks to be in a [CORRUPT] state upon reattach > > > > directly to > > > SATA interface. > > > > > > > > Before submitting a bug, there is only 1 variable left that I > > > > can't > > > test, because I have only 1 USB to SATA adapter. > > > > It might be a hardware issue, so can someone else test this too? > > > > > > > i have two external disk chassis with USB-SATA bridge, works just > > > fine > > > > > > recently connected through it disk that was geli encrypted when > > > directly connected to server. geli worked so all is fine as geli > > > header is in last sector > > > > > > > It all depends... There's huge variation in the quality of USB-SATA > > bridges. Some get in the way and do things like round off the last > > sector when the reported capacity is odd, for example. Which is why > > I'm trying to see if there's an issue with that, or if the issue is > > something in the da driver. For drives with an even number of > > sectors, there's likely no issues at all... > > > > Warner > > > > Well, I've installed sysutils/sg3_utils, but required sg device will have > to wait, > as I can't recompile kernel ATM. > > Regarding quality ..., this one was so cheap that I've got it for free. ;= ) > Regarding capacity ..., HDD has EVEN number of sectors. > > Last HDD checked (just before posting) Hitachi: > =3D=3D=3D=3D=3D=3D=3D=3D > # diskinfo -v ada1 | awk '/mediasize in sectors/{print $1}' > 312581808 > > # gpart show -p ada1 > =3D> 63 312581745 ada1 MBR (149G) > 312581745 + 63 =3D 312581808 > > All OK! > > > # diskinfo -v da0 | awk '/mediasize in sectors/{print $1}' > 312581807 > > # gpart show -p da0 > gpart: No such geom: da0. > Showed nothing (usually it does even in this cases) > What does sg_readcap from sg3_utils package say? Warner From owner-freebsd-hackers@freebsd.org Wed Jul 17 06:32:15 2019 Return-Path: Delivered-To: freebsd-hackers@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 687B5A4AEC for ; Wed, 17 Jul 2019 06:32:15 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) 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 AA99F69EDE for ; Wed, 17 Jul 2019 06:32:14 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: by mailman.nyi.freebsd.org (Postfix) id AA23BA4AEB; Wed, 17 Jul 2019 06:32:14 +0000 (UTC) Delivered-To: hackers@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 A9E4CA4AEA for ; Wed, 17 Jul 2019 06:32:14 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from kabab.cs.huji.ac.il (kabab.cs.huji.ac.il [132.65.116.210]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EA13869ECA for ; Wed, 17 Jul 2019 06:32:06 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=cs.huji.ac.il; s=57791128; h=To:Date:Message-Id:Subject:Mime-Version:Content-Transfer-Encoding:Content-Type:From; bh=dXkkgNXbsB3twWxHL/IPBrtbMZF4S9Xh4Nl9BMRhPKo=; b=uz1/0yBISX3/rxXZbvgvyBEmQvmzFUwYxDTBDYxUaXtM5vwAZx/bsqcQJ0MN6Uxb+6iauuso2IBJa2gU8MpzcizlLypURYTgBIFTqS9KK7KmdHGMhpEOsgWMNhhA94w1YQ1OdIieSnRWE4NfDOP/9PEH9vP/VrI2cOmy81yJEy+Vf2AAIK8pyctL086HEe69U1hM9aeSYziH4ecxTUIwymyOGjYwdWYJRnLMejBOL87laIIbVyZBS649miKxrvnchpeJae72rIJEHM43HYRvztUdmgPAMSX+Jtdy9qrPsvRCJBEHrBfxGYKigPTyWoXj8wcQz+5q/q+Eka3za2g1Eg==; Received: from bach.cs.huji.ac.il ([132.65.80.20]) by kabab.cs.huji.ac.il with esmtp id 1hndTi-000Iwx-KA for hackers@freebsd.org; Wed, 17 Jul 2019 09:31:50 +0300 From: Daniel Braniss Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\)) Subject: dell r710/h700 upgrade blues Message-Id: <82B19F33-19B4-4297-93D3-E80CF81719FC@cs.huji.ac.il> Date: Wed, 17 Jul 2019 09:31:49 +0300 To: hackers@freebsd.org X-Mailer: Apple Mail (2.3445.9.1) X-Rspamd-Queue-Id: AA99F69EDE X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=cs.huji.ac.il header.s=57791128 header.b=uz1/0yBI X-Spamd-Result: default: False [-4.26 / 15.00]; ARC_NA(0.00)[]; FORGED_RECIPIENTS_FORWARDING(0.00)[]; R_DKIM_ALLOW(-0.20)[cs.huji.ac.il:s=57791128]; RCVD_COUNT_FIVE(0.00)[5]; FROM_HAS_DN(0.00)[]; FORWARDED(0.00)[hackers@mailman.nyi.freebsd.org]; MV_CASE(0.50)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[huji.ac.il]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_MEDIUM(-1.00)[-0.997,0]; DKIM_TRACE(0.00)[cs.huji.ac.il:+]; MX_GOOD(-0.01)[cached: kabab.cs.huji.ac.il]; NEURAL_HAM_SHORT(-0.89)[-0.889,0]; R_SPF_NA(0.00)[]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; IP_SCORE(-1.67)[ip: (-1.41), ipnet: 2610:1c1:1::/48(-3.89), asn: 11403(-2.99), country: US(-0.06)]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; FORGED_RECIPIENTS(0.00)[hackers@freebsd.org,freebsd-hackers@freebsd.org]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Jul 2019 06:32:15 -0000 hi, this host is running FreeBSD. I managed to upgrade the bios to 6.6.0, but failing miserably trying to = update the perc/h700, so any success stories out there? cheers, danny From owner-freebsd-hackers@freebsd.org Wed Jul 17 16:19:24 2019 Return-Path: Delivered-To: freebsd-hackers@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 C0497B051C for ; Wed, 17 Jul 2019 16:19:24 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 2140488AE0 for ; Wed, 17 Jul 2019 16:19:24 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id 20D15B051B; Wed, 17 Jul 2019 16:19:24 +0000 (UTC) Delivered-To: hackers@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 20976B051A for ; Wed, 17 Jul 2019 16:19:24 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x544.google.com (mail-ed1-x544.google.com [IPv6:2a00:1450:4864:20::544]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 D16F688ADD for ; Wed, 17 Jul 2019 16:19:23 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x544.google.com with SMTP id p15so26421363eds.8 for ; Wed, 17 Jul 2019 09:19:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=JbVUX6QHHleRCOwfkhVpMWqtbbHzXnXVkcxjOA1p4cI=; b=nOILN5p9fYQc9Og7ic7L/DVKuGf3bqNNM4mNJz3lW+t6O5MXF1IbyrXhDiRqriMQnL IHtzQH3iYgyUZWmc9bbN8RHBBX1mCa8dI0hAbNrlYv6tl7VAuFcMxF9RqTKuvRZdGt27 glcuhknpaUDslbHowMS0Yb8tLMvVEOl6CSvDqBKlhOgUT4Jd1EKWL+5AQVOCcAIjvOME r9a2P1RY8k0klRk/DOggbSU9vBpvye9xJ35eo2Li1S1l0xH1KwYDx7w3cp3UOVbhJ9sT LJg06F8Xfss7JPlfCP6m/vCPL86i5qnXPfh7g3YjeTaQ4kOvWePLnEgdNrGE5r1XuPVy XHyg== 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:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JbVUX6QHHleRCOwfkhVpMWqtbbHzXnXVkcxjOA1p4cI=; b=Njo4YTcUwNkh0sVfPzsCPWnFqniT7yYxXmo5GjJZXW7/OqnaIgrs0qGKIPqCpOQJX9 hSMk/RotI9lpnJ4FcH24sL5BGetrA9Y2x1lwKjdaMd5mBqBp8SEOPM3psVe4HmaEtLBU 2i17Td23xkouy0QXaTdQOWuvZXU8QNRKcAfkwbzpwgFcg49KygHYblTIjp4Jv5sGP4xi 3oBe6lu3GpO/Xnb3KpAYDsbS7O+m/qQY0iMYdKoYFEh9Axuby9d+hQ8lSU3Ulsn2iwvZ /G/+XRaOCsjBDJVXSiU9DKA/l3WCAXuyiUJRPHqmIvpNc1zarkW+GYN4VLJnCIyJFxqg /5fQ== X-Gm-Message-State: APjAAAV5xMBHeRgLLLy+mhAMnWMTSg3UZiflaMXz+s5sFWONX/NJNoFY IBvAxdmbIJIYaRg77ug+vl15QW6lH9w= X-Google-Smtp-Source: APXvYqzHVUePWKEb958U+/uW+eg6i0yOJ1PjSbhTTTzV9NndyB4X9GU0iBEt2FjoKpIOOea0u3tDWg== X-Received: by 2002:a17:906:ece7:: with SMTP id qt7mr32211090ejb.155.1563380362761; Wed, 17 Jul 2019 09:19:22 -0700 (PDT) Received: from localhost ([213.149.52.156]) by smtp.gmail.com with ESMTPSA id t13sm6965381edd.13.2019.07.17.09.19.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 17 Jul 2019 09:19:22 -0700 (PDT) Date: Wed, 17 Jul 2019 18:18:34 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: Warner Losh Cc: Wojciech Puchar , hackers@freebsd.org Subject: Re: Device's "stolen" sector Message-ID: <20190717181834.00002698@gmail.com> In-Reply-To: References: <20190716182350.000054f8@gmail.com> <20190716224332.00000326@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: D16F688ADD X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.99 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_SHORT(-0.99)[-0.994,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; REPLY(-4.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Jul 2019 16:19:24 -0000 On Tue, 16 Jul 2019 15:34:47 -0600 Warner Losh wrote: > On Tue, Jul 16, 2019 at 2:44 PM Domagoj Smol=C4=8Di=C4=87 > wrote: >=20 > > On Tue, 16 Jul 2019 13:27:43 -0600 > > Warner Losh wrote: > > =20 > > > On Tue, Jul 16, 2019 at 11:05 AM Wojciech Puchar > > > wrote: > > > =20 > > > > > > > > > > > > On Tue, 16 Jul 2019, Domagoj Smol=C4=8Di=C4=87 wrote: > > > > =20 > > > > > 11.2-RELEASE-p9 > > > > > > > > > > Tested with >1 disks: > > > > > -- > > > > > SATA disk connected directly with SATA cable to MBO, shows > > > > > correct =20 > > > > amount of sectors. =20 > > > > > diskinfo -v ada1 > > > > > > > > > > When I connect it to the same MBO over USB to SATA adapter, 1 > > > > > sector is =20 > > > > missing (the last one) =20 > > > > > diskinfo -v da0 > > > > > > > > > > Having last sector inaccessible is a huge problem as many > > > > > "things" use =20 > > > > it for a metadata. =20 > > > > > This has many times caused MBR disks occasionally to not be > > > > > visible at =20 > > > > all while being 'da0' (gpart: No such geom: da0.) =20 > > > > > And also GPT disks to be in a [CORRUPT] state upon reattach > > > > > directly to =20 > > > > SATA interface. =20 > > > > > > > > > > Before submitting a bug, there is only 1 variable left that I > > > > > can't =20 > > > > test, because I have only 1 USB to SATA adapter. =20 > > > > > It might be a hardware issue, so can someone else test this > > > > > too?=20 > > > > i have two external disk chassis with USB-SATA bridge, works > > > > just fine > > > > > > > > recently connected through it disk that was geli encrypted when > > > > directly connected to server. geli worked so all is fine as geli > > > > header is in last sector > > > > =20 > > > > > > It all depends... There's huge variation in the quality of > > > USB-SATA bridges. Some get in the way and do things like round > > > off the last sector when the reported capacity is odd, for > > > example. Which is why I'm trying to see if there's an issue with > > > that, or if the issue is something in the da driver. For drives > > > with an even number of sectors, there's likely no issues at all... > > > > > > Warner > > > =20 > > > > Well, I've installed sysutils/sg3_utils, but required sg device > > will have to wait, > > as I can't recompile kernel ATM. > > > > Regarding quality ..., this one was so cheap that I've got it for > > free. ;) Regarding capacity ..., HDD has EVEN number of sectors. > > > > Last HDD checked (just before posting) Hitachi: > > =3D=3D=3D=3D=3D=3D=3D=3D > > # diskinfo -v ada1 | awk '/mediasize in sectors/{print $1}' > > 312581808 > > > > # gpart show -p ada1 =20 > > =3D> 63 312581745 ada1 MBR (149G) =20 > > 312581745 + 63 =3D 312581808 > > > > All OK! > > > > > > # diskinfo -v da0 | awk '/mediasize in sectors/{print $1}' > > 312581807 > > > > # gpart show -p da0 > > gpart: No such geom: da0. > > Showed nothing (usually it does even in this cases) > > =20 >=20 > What does sg_readcap from sg3_utils package say? Wait. When I intended to recompile kernel with sg device, I also decided to bring 11.2 to latest patch version and this also includes world recompilation. But I just saw 11.3 is production ready, so If I'm already doing world+kernel why to not migrate to 11.3 in a process. You'll have it tomorrow. Domagoj > Warner >=20 From owner-freebsd-hackers@freebsd.org Wed Jul 17 16:28:16 2019 Return-Path: Delivered-To: freebsd-hackers@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 F16EAB08B9 for ; Wed, 17 Jul 2019 16:28:16 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id B3E618907B for ; Wed, 17 Jul 2019 16:28:16 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id B37BFB08B8; Wed, 17 Jul 2019 16:28:16 +0000 (UTC) Delivered-To: hackers@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 B33FAB08B7 for ; Wed, 17 Jul 2019 16:28:16 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 1A49289078 for ; Wed, 17 Jul 2019 16:28:15 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x542.google.com with SMTP id m10so26466801edv.6 for ; Wed, 17 Jul 2019 09:28:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zPePuL0fQCcYzyUETzNpu34szn6vI/oYHaCruDsLG8c=; b=CrNUJe6X/2Hx2tcHpFR6pMl45+W5tHgqngb1LkwkJoOnTBNs55bJMYf5tNmLusKSd0 0+G61xYo2Qc/ugOvGKQGXtUIw3oW2PNddUocrGI0s3zLKuI6NVYRs1Hoywh22Zeu3FgY YI8FyKk1IaUoIGPPIrkO0C0z/qsv05kz5cAdaOHCMYiMmjL3dlVM62p7eNSlPfHpUjSo 0yqD6MHAfUehh/SQhlcKk54LFkIpyDaFXA343mlAF1CP7aAmv073fxpzDUljWvIab+Do 4m8Sxg/cP7NXMmAEpLqMRO10++6ejt+SlDq27G/HEersOgXhMDDUdvoRkq3CulokzTYc MUWA== 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:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zPePuL0fQCcYzyUETzNpu34szn6vI/oYHaCruDsLG8c=; b=C8iQ9146/yKkuzu55Z+CF3lwC+WD1xbP7YFC130GNQOE2LP7tt1vKg4J53FIZYhrLx gZL5Pw+b0fTu02wIEIyrSSfet3shl4l/yinRyMCQ0Mnnq6Yq5qdwrJZDRKNTd6Npijzv QZ8mWajYjwsAE8wfi+hhxim9PNPswC0a54bTuVTO9vkdKdXACyKhK2XkImJ2xfIX20du HEyQI4ImB+xd/4f9sxA79VxmnGyHLPmqiJUnUjd28/DUoCVeMvR3QcdLUoNVg271IcjG N4E9FQFHiEiKFaQGU1uU7wF5azmgBcIdFZk0oB5UmDjesWvtvAHDxrAxTH/Uz8e8Ogr6 sJPg== X-Gm-Message-State: APjAAAUrwD/39Tz7MMfRdAZ5IW8O4Owqkp3tIikPEQwWkAL7fUcTWA8R Tuqdhz0XVg/pO1a1eq4Yt4MTOCIBZ8o= X-Google-Smtp-Source: APXvYqze33H/L2vYkosm44bYvqVcItwznt2iTP8rV9yPm5TzELrZtGVtb3VqU5m7Azc5FhthLReXRA== X-Received: by 2002:a17:907:447f:: with SMTP id oo23mr22056471ejb.193.1563380894140; Wed, 17 Jul 2019 09:28:14 -0700 (PDT) Received: from localhost ([213.149.52.156]) by smtp.gmail.com with ESMTPSA id q56sm6984781eda.28.2019.07.17.09.28.13 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 17 Jul 2019 09:28:13 -0700 (PDT) Date: Wed, 17 Jul 2019 18:27:26 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: Larry Maloney Cc: hackers@freebsd.org Subject: Re: For a first time completed S.M.A.R.T captive test Message-ID: <20190717182726.00003ad1@gmail.com> In-Reply-To: References: <20190716190854.000061b2@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 1A49289078 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=CrNUJe6X; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rank1seeker@gmail.com designates 2a00:1450:4864:20::542 as permitted sender) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-5.05 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.92)[-0.923,0]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2.4.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0]; IP_SCORE(-1.12)[ip: (-0.19), ipnet: 2a00:1450::/32(-2.92), asn: 15169(-2.44), country: US(-0.05)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Jul 2019 16:28:17 -0000 On Tue, 16 Jul 2019 11:07:47 -0700 Larry Maloney wrote: > It=E2=80=99s been a while,so I could be wrong, but I seem to recall havin= g to > unmount the device before testing. If you read below, this is implied. Only device node exists. Keyword here is CAPTIVE =3D=3D> '-C' flag. Regular tests always finish /w problems, even with mounted FS-es, i.e; # smartctl -t long /dev/... Try with captive, then you'll see if you can finish it: # smartctl -C -t long /dev/... Domagoj Smol=C4=8Di=C4=87 > /Larry >=20 > Sent from my iPhone >=20 > > On Jul 16, 2019, at 10:08 AM, Domagoj Smol=C4=8Di=C4=87 > > wrote: > >=20 > > 11.2-RELEASE-p9 > >=20 > > From the first time I started to use FreeBSD and upon to just > > recently, with smartmontools, I have NEVER successfully completed > > captive test. No matter which HDD or smartmontools version I used, > > upon initiating 'Extended captive' test, I would ALWAYS get error: > > 'Interrupted (host reset)' This implies nothing is being mounted > > from device, so only it's node exist in /dev/ and nothing "chats" > > with it except kernel. Stopping smartd service also didn't help. > >=20 > > Searching on the internet, I have never found anyone succeeding > > with it. Just a "solutions" that it should never be used?! > >=20 > > So I started to think a little bit out of the box ... > > HDD has it's OWN board with it's OWN BIOS + firmware, which > > actually holds S.M.A.R.T version/ability and IT executes issued > > test from OS, using it's own firmware to actually run a test. Once > > HDD receives test request from OS, HDD doesn't need OS at all! > >=20 > > So, in order to get rid of a results like: > > Num Test_Description Status Remaining > > LifeTime(hours) LBA_of_first_error # 2 Extended captive > > Interrupted (host reset) 90% 40743 - > >=20 > > And suspecting OS (kernel?!) is pestering HDD during it's captive > > test, thus interrupting it, AS SOON as captive CMD is issued and > > hangs occurs (it is too late when hang passes by itself!), I've > > pulled out SATA DATA cable and left SATA POWER cable attached. Hang > > is stopped as soon as SATA DATA cable is unplugged and it's used > > only to transfer test request anyway to HDD and all HDD needs from > > that point on, is JUST a power and it's "piece of mind"! RESULT: -- > > SMART Self-test log structure revision number 1 Num > > Test_Description Status Remaining > > LifeTime(hours) LBA_of_first_error # 1 Extended captive > > Completed without error 00% 40744 - # 2 Extended > > captive Interrupted (host reset) 90% 40743 - -- > >=20 > > FINALLY! =3D=3D> '# 1 Extended captive Completed without error' > >=20 > > So ..., what to conclude from this? > > Does kernel really must "chat" with HDD in order to keep alive it's > > device node in /dev/ or is it something else? If HDD supports > > captive test and during it, why it simply doesn't ignore OS/kernel > > (it is up to HDD's firmware code to make that decision). > >=20 > > Is this, I'm not even sure how to name it ..., a borderline bug? > >=20 > > Anyway, it is a little bit "impractical" to use terminal with one > > hand and with other to pull out SATA data cable. > >=20 > >=20 > > Domagoj Smol=C4=8Di=C4=87 > > _______________________________________________ > > freebsd-hackers@freebsd.org mailing list > > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > > To unsubscribe, send any mail to > > "freebsd-hackers-unsubscribe@freebsd.org" =20 From owner-freebsd-hackers@freebsd.org Thu Jul 18 02:37:30 2019 Return-Path: Delivered-To: freebsd-hackers@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 C4B3BBC227 for ; Thu, 18 Jul 2019 02:37:30 +0000 (UTC) (envelope-from rpokala@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) 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 34E3F6F34F; Thu, 18 Jul 2019 02:37:30 +0000 (UTC) (envelope-from rpokala@freebsd.org) Received: from [172.17.133.69] (unknown [12.202.168.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: rpokala) by smtp.freebsd.org (Postfix) with ESMTPSA id 93F771E11E; Thu, 18 Jul 2019 02:37:29 +0000 (UTC) (envelope-from rpokala@freebsd.org) User-Agent: Microsoft-MacOutlook/10.1b.0.190715 Date: Wed, 17 Jul 2019 19:37:25 -0700 Subject: Re: For a first time completed S.M.A.R.T captive test From: Ravi Pokala To: "freebsd-hackers@freebsd.org" , , Message-ID: <481465DB-D5EE-4019-A2DB-DBA4D46FE312@freebsd.org> Thread-Topic: For a first time completed S.M.A.R.T captive test Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: 7bit X-Rspamd-Queue-Id: 34E3F6F34F X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.92 / 15.00]; local_wl_from(0.00)[freebsd.org]; NEURAL_HAM_MEDIUM(-1.00)[-0.997,0]; NEURAL_HAM_SHORT(-0.92)[-0.921,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; ASN(0.00)[asn:11403, ipnet:96.47.64.0/20, country:US] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 02:37:30 -0000 Hi Domagoj The "captive" test is blocking -- meaning the drive won't indicate command completion for multiple hours in the case of modern large HDDs -- so the FreeBSD driver will almost certainly timeout before completion. That in turn will trigger recovery mechanisms, which will include a soft-reset, which is where the "Interrupted (host reset)" comes from. You almost always want to do the "off-line" test; that tells the drive firmware to start the test and run it in the background. It will indicate command completion in a second or two, but the test will still take the same amount of time. But in the case of the "off-line" test, the drive is responsive to the host even while the test runs. When the drive receives a command from the host, it will pause the test, service the host request, and then resume the test. I work at a storage company, I've been running ATA self-test for 15+ years, and I've never understood why the "captive" test even exists. *Maybe* there were dedicated drive test systems that had huge timeouts, back in the PATA days? Or even horrible DOS stuff that didn't even have a timeout, and just waited for the interrupt forever? In any case, I would simply not bother with the "captive" test modes. -Ravi (rpokala@) From owner-freebsd-hackers@freebsd.org Thu Jul 18 10:38:32 2019 Return-Path: Delivered-To: freebsd-hackers@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 DFF51A5222 for ; Thu, 18 Jul 2019 10:38:32 +0000 (UTC) (envelope-from vince@unsane.co.uk) Received: from unsane.co.uk (tunnel7249-pt.tunnel.tserv5.lon1.ipv6.he.net [IPv6:2001:470:1f08:110::2]) by mx1.freebsd.org (Postfix) with ESMTP id 1935B83903 for ; Thu, 18 Jul 2019 10:38:31 +0000 (UTC) (envelope-from vince@unsane.co.uk) Received: from vhoffman.lon.namesco.net (lon.namesco.net [195.7.254.102]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by unsane.co.uk (Postfix) with ESMTPSA id 9CBF7301A5 for ; Thu, 18 Jul 2019 11:38:24 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=unsane.co.uk; s=251017; t=1563446305; bh=qJm1Lb6Cg7bLfy9XFehvWScbHYQeNNpBu+YUgKGh9NE=; h=Subject:To:References:From:Date:In-Reply-To; b=T/3rJ37aEjhZ+IR/YA0DKFtAIvUcM9LoWtxm33hu+jlIIfTTD2/qnguIbYnd2Oqpv BKZ8Zb2KvQjzb4l3pKhOI5ULA2W2oapFhhOYvhiZm4GwFrQnvaHiu4tavui0H1vL2F wfPhs2z6QU97mfaqYTkzG/q74ygsA++Ef31PFiXg= Subject: Re: dell r710/h700 upgrade blues To: freebsd-hackers@freebsd.org References: <82B19F33-19B4-4297-93D3-E80CF81719FC@cs.huji.ac.il> From: Vincent Hoffman-Kazlauskas Openpgp: preference=signencrypt Autocrypt: addr=vince@unsane.co.uk; prefer-encrypt=mutual; keydata= mQGiBESPz78RBADybNTkAA4eQLuwYC1Qsn7qaDLzBvq2RmA0niwngigEPy/tLh9aF2zR85fL PTvxh9MyLzFZHc5RVO0tKM93CSRXjTo5xo2P1/YTopPyzTBB3eOB7uqJRi+suBnKPfXvkeW1 g5yo3pKINsqW0ed91lDwrQ1NofbIFkOOYnhQpccdiwCg0GF13Vk9Rz683bkSawFethAcVx8E AKGPTj6KfVmnhB8a3y0UeZ46LMfoZnjLF4ZDMtrZHY639zbZBJiKJ/M1B8z3GJgmRmOEXoW4 Mdoi0XaSkinIWmtdI+vhIfb/7ufFzujM0wEbEnpJ/mvTuSas6DG7MPMiJMavz3Hf/dVOX7Dd Ma+z03JKIHuMj8HVMFccjgFJLmteBADkdDBQin+YzgGuPs/Sf8KvVPVRDT5QJkHUEU/gcmSP YbPfmwC7tl1iXR9Gu4foQyk2UJJezCRUWggNScybcrLp2jQ0XWkw18uus/QC2ZCfW/f2vXg8 uL5W7cLGbeSKh3K0CFMbACmcrcMZk7JwW9a/VlAhmqOUk1MYJ1rR2ZZIp7QmVmluY2VudCBI b2ZmbWFuIDx2aG9mZm1hbkBuYW1lcy5jby51az6IYAQTEQIAIAUCRI/PvwIbAwYLCQgHAwIE FQIIAwQWAgMBAh4BAheAAAoJEMQkmEPMfxC+ik0An0EFsHC1cTRRq+MgAWoM3WRvOeQFAJ9D 2GwjK6Zaiu6s+KaxeWh4yrk0JbkCDQREj8/REAgA5AQP4RpCo/O9U/Zd4s0mArJpGQhAnYb8 2r+u3e/MyGK5hTH+ODAOZ1TeiPb75xYQ9QGOX+ygpCSDmDjG+MJyPivdZMuuwnhisYZPNuhE Tw/CdP5mekqPzZAvIqBi5q6Bdmz0tORu4L6y/zPnQ8qrkBnibK9AOKz1XkguOlzcIlfxpsOC AgTRWoOpW8oQtQl80Ik22prSExgKllBfq3/sRix28r86L51P5hHG7mlWtbv8txaLyihBO3aw mkTXLAk5IMgrlillkDvMYUsO7lOkwk54C3oq+lYarNJ4Ul7Wfyg1ufjCc8CynXrlgFMJ+wbg Uhk4lbidSuGRkT10yqlNrwAECwf/YA3W3eSNQIn6s5eBTR+Qocmp+11zTNQMwB3xRzKQFBBd UwTbFiyhxMS7+xJzEUzuhTOy/OI/QCto595C/68y53TU0fwII0e2XLRYDIWO1FqSCGyDMviO 1ixnSHMkXeIEPbalF9n+KB2ozX0OOxl3oA7wt/DmOq8nLNzCMOKHD6mJRnBAp0En9WYpnbSl nucjh2+Ry9XAK5HCZ9k1SWxFPCEvxv4nwhZnYFdm5O4M6MHw8T/viWIBa96yt2CTGP7gOz+s YKcjUTQ7UdtYFVguGW9uehvtqbCLv69clBCmooRYAmTkiupI8R1zIfKVDjllDONWoPZfCz2d LwHnLW/ZMohJBBgRAgAJBQJEj8/RAhsMAAoJEMQkmEPMfxC+he0An3g4+nwMH9lsde9IFgQY TDhDySz9AKCZSsEaPlGPvj7Fd7c47Eh4Nt9j9w== Message-ID: Date: Thu, 18 Jul 2019 11:38:24 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <82B19F33-19B4-4297-93D3-E80CF81719FC@cs.huji.ac.il> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 10:38:32 -0000 On 17/07/2019 07:31, Daniel Braniss wrote: > hi, > this host is running FreeBSD. > > I managed to upgrade the bios to 6.6.0, but failing miserably trying to update the perc/h700, > so any success stories out there? > Honestly for Dells I tend to reboot to a USB Centos6 install and use Dells DSU util for firmware updates. https://linux.dell.com/repo/hardware/dsu/ I'd be interested to hear of more FreeBSD based ways to to it. Vince > cheers, > danny > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Thu Jul 18 13:52:50 2019 Return-Path: Delivered-To: freebsd-hackers@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 BE1B1A94A8 for ; Thu, 18 Jul 2019 13:52:50 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from exch.demig.de (exch.demig.de [130.180.89.86]) (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 6E0E28A3F1 for ; Thu, 18 Jul 2019 13:52:49 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from [192.168.148.248] (port=14723 helo=SRV-FS-2.Demig.intra) by exch.demig.de with esmtps (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.82_1-5b7a7c0-XX) (envelope-from ) id 1ho6ph-0007We-2i for freebsd-hackers@freebsd.org; Thu, 18 Jul 2019 15:52:30 +0200 Received: from [192.168.148.215] (192.168.148.215) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 18 Jul 2019 15:52:23 +0200 X-CTCH-RefID: str=0001.0A0C020C.5D30799E.0019, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 From: Norbert Koch Subject: build custom kernel under FreeBSD 12 To: Message-ID: <14ad0148-ebe6-5d13-54fa-f6711c4b43ab@demig.de> Date: Thu, 18 Jul 2019 15:52:23 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: quoted-printable X-C2ProcessedOrg: e1e98c77-ec17-4cb1-9b24-fe57656077ed X-Rspamd-Queue-Id: 6E0E28A3F1 X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of nkoch@demig.de designates 130.180.89.86 as permitted sender) smtp.mailfrom=nkoch@demig.de X-Spamd-Result: default: False [2.41 / 15.00]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[demig.de]; NEURAL_SPAM_MEDIUM(0.71)[0.709,0]; RCPT_COUNT_ONE(0.00)[1]; RCVD_COUNT_THREE(0.00)[3]; RCVD_TLS_LAST(0.00)[]; NEURAL_SPAM_SHORT(0.59)[0.588,0]; MX_GOOD(-0.01)[mx1.demig.de,mx2.demig.de]; NEURAL_SPAM_LONG(0.68)[0.679,0]; IP_SCORE(0.75)[asn: 6830(3.82), country: AT(-0.10)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:6830, ipnet:130.180.64.0/18, country:AT]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 13:52:50 -0000 Hello. I am obviously too stupid to figure out how to build a custom kernel as non-root user in a non-standard directory. Under FreeBSD9/10/11 I could put src/ under my own directory and start a kernel-compilation by just setting $MAKEOBJDIRPREFIX accordingly. Doing this under FreeBSD12 gives me 'permission denied' with 'config -d /usr/src/sys/GENERIC ...'. Seems like ${KRNLOBJDIR} is not set correctly while the other parameters to config are. I see that Makefiles differ between 12 and older releases. ${OBJTOP} vs. ${OBJTREE}? So, what am I doing wrong? Thank you for any help. *********************************************************************** * demig Prozessautomatisierung GmbH * demig Anlagentechnik GmbH * * * * * Anschrift: Haardtstrasse 40 * Haardtstrasse 40 * * D-57076 Siegen * D-57076 Siegen * * Registergericht: Siegen HRB 2819 * Siegen HRB 5532 * * Geschaeftsfuehrer: Joachim Herbst, * Joachim Herbst, * * Winfried Held * Winfried Held * * Telefon: +49 271 772020 * +49 271 772020 * * Telefax: +49 271 74704 * +49 271 74704 * * E-Mail: info@demig.de * at@demig.de * * http://www.demig.de * http://www.demig.de * *********************************************************************** From owner-freebsd-hackers@freebsd.org Thu Jul 18 14:57:19 2019 Return-Path: Delivered-To: freebsd-hackers@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 22659AA5C3 for ; Thu, 18 Jul 2019 14:57:19 +0000 (UTC) (envelope-from ryan@ixsystems.com) Received: from mail-yw1-xc2a.google.com (mail-yw1-xc2a.google.com [IPv6:2607:f8b0:4864:20::c2a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 C96FC8C0AD for ; Thu, 18 Jul 2019 14:57:17 +0000 (UTC) (envelope-from ryan@ixsystems.com) Received: by mail-yw1-xc2a.google.com with SMTP id x67so10940799ywd.3 for ; Thu, 18 Jul 2019 07:57:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ixsystems-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=WOwKaio7tm3JoNR0pd9/Adr5TgMUqbd8rzAICbot5nY=; b=itKx6K64gR2W/6IeCMbJbde/ceedeqiB6rs3czrugQSqzhCcTT5IsLCYC8JT3plx9Q cU5gDhDZ9Z6MS+6V9Xnhkx/Y80o88ITvimo2fsmZd13i2fQf/bWBZIiDjwGhKWwrv9GW bBE/QtEM5U9GioUgBKZjDsLl/+f5Zqlovu2dgHdlMDOKAIm9jNbVac6uIt95RU0jjZhx N9sb2V7d6Y3Zdjwq4sacFnqz64Ukc2GEjczdQKKjNfmTjpbnRQKC/SCILEiqv/iuNCtq QzZi2ooFS4M8Jf+esm4a0lEmLMZU6U9CnWBMtUl7sveRbK03egrtvcs75Kovt4LOX0b7 BkzQ== 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=WOwKaio7tm3JoNR0pd9/Adr5TgMUqbd8rzAICbot5nY=; b=O+bUZety9ETa4w0cOrYRf3yUVmLxxEmUklC7Az20bDaQf/VsrQET2u0QKahNYOaAXS NM5jwCjjoGhdt5wVYP/Ry89tDlLTw1Kfq7+Ya03G9nPukuX6ortSAggM/L2nvt/jucXz zK91c3VyyNb4b2FL4CUffhePO9utfHXqsdCFMxXvcCM9GpuxddNyXdSAFvlxp23paczB 1h0vamXOr+U6g9Z4chQvImk0CD3GuO/Fka8OSGvB+vgXAWLUWGZ2310gAmsP9jxgdp3J ZFGGQPfFd0/a7D7+5fI2krHnMwZ/ohvZbsz1ZCdJIFFpbpjXMiWZCG3yw5YGscC9bhML 8ePw== X-Gm-Message-State: APjAAAWbx+L/pmv+R+vFUDzTjqkOOFtBOgteFVzcpMbC2tkTJStB1gL3 SKebXhSWp0nAA5j7of4wli0eURMqvOMIaVzdDtdHYdJM0BI= X-Google-Smtp-Source: APXvYqzcBpna6npCAP972Fy/Z8OOwIVie6jdfD6S45iNLEIDXBP2CIXIADzsNnoyi//8QYkQ0VxV/foTypDmx1kxINM= X-Received: by 2002:a81:4947:: with SMTP id w68mr29518941ywa.399.1563461836930; Thu, 18 Jul 2019 07:57:16 -0700 (PDT) MIME-Version: 1.0 References: <721ab68d-cde4-41bb-c105-d15cf07903fa@FreeBSD.org> In-Reply-To: From: Ryan Moeller Date: Thu, 18 Jul 2019 10:57:06 -0400 Message-ID: Subject: Re: Resetting console on boot To: "freebsd-hackers@freebsd.org" X-Rspamd-Queue-Id: C96FC8C0AD X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=ixsystems-com.20150623.gappssmtp.com header.s=20150623 header.b=itKx6K64; dmarc=pass (policy=none) header.from=ixsystems.com; spf=pass (mx1.freebsd.org: domain of ryan@ixsystems.com designates 2607:f8b0:4864:20::c2a as permitted sender) smtp.mailfrom=ryan@ixsystems.com X-Spamd-Result: default: False [-6.79 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[ixsystems-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCPT_COUNT_ONE(0.00)[1]; IP_SCORE(-2.82)[ip: (-8.45), ipnet: 2607:f8b0::/32(-3.15), asn: 15169(-2.44), country: US(-0.05)]; DKIM_TRACE(0.00)[ixsystems-com.20150623.gappssmtp.com:+]; MX_GOOD(-0.01)[cached: ALT3.ASPMX.L.GOOGLE.com]; RCVD_IN_DNSWL_NONE(0.00)[a.2.c.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; NEURAL_HAM_SHORT(-0.96)[-0.959,0]; TO_DN_EQ_ADDR_ALL(0.00)[]; DMARC_POLICY_ALLOW(-0.50)[ixsystems.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 14:57:19 -0000 Apparently this also could be wanted with vidconsole, as some IPMI console redirection to com1 and serial over lan redirects from the vidconsole. I just discovered this while testing Lev's patches. -Ryan On Tue, Jul 16, 2019 at 11:08 AM Warner Losh wrote: > > > On Tue, Jul 16, 2019 at 4:55 AM Lev Serebryakov wrote: > >> On 15.07.2019 23:29, Ryan Moeller wrote: >> >> > What do people think about having an early boot stage send some escape >> > sequence to reset terminals to some sane default terminal settings? >> Often >> > firmware or other causes will leave an unreadable font color or break >> line >> > feeds, and the terminal tends to stay that way until a shell clears and >> > resets the screen. If a shell can do it, surely loader could do it (or >> even >> > earlier, if it is not too complex). To my knowledge it should be just a >> > matter of printing some escape codes before starting the normal boot >> menus >> > when using a serial console. I believe this is already done when the >> > console is set to vidconsole or efi. >> > >> > Thoughts? Suggestions? >> >> I've proposed this long ago for serial terminals: >> >> https://reviews.freebsd.org/D17102 >> https://reviews.freebsd.org/D17103 >> >> I have hardware which sets "black on black" before passing control to OS. >> > > That would work for the BIOS case, but not the UEFI case, which is where I > see the biggest issues. > > Warner > -- Ryan Moeller iXsystems, Inc. OS Developer Email: ryan@iXsystems.com From owner-freebsd-hackers@freebsd.org Thu Jul 18 15:48:21 2019 Return-Path: Delivered-To: freebsd-hackers@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 60ACBAB2C3 for ; Thu, 18 Jul 2019 15:48:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x832.google.com (mail-qt1-x832.google.com [IPv6:2607:f8b0:4864:20::832]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 580D88D95B for ; Thu, 18 Jul 2019 15:48:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x832.google.com with SMTP id h21so27645804qtn.13 for ; Thu, 18 Jul 2019 08:48:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=R6FjXMd4SVd9EcnJuk+UkcxnT0+hHw9K94N7AglPMCk=; b=krBKPkNQVPGn+iUvIj+JfJPE9CTdRiNK6OMTucJq09rEjVv5ynr6vHBk+p9qy0yIdc CwO38oQRpoJ2Fb+XUrQzZTmGOUxwUT34LVdEvcZuVfBFV1L1abzXpgi8Pw7PCwFk5WL7 67KC/liUsbRku9tRTnZcfcdty7oQKvZNTZlWJrld0Hx2NsANK27dSg0MeaynKYH4sN2Q vEDwzGepozV1/LXaY+ikJh+xQ97u32wI8ruQdahbRBGJPbIeff/Tw56trcqpKzt/xYW9 j9hLHFCwaFXfs7dRlHMGrhDtXvLkXsAlayDSINf0ffMBoE+5jme4nekA/W0/k+ZtOao0 ljag== 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=R6FjXMd4SVd9EcnJuk+UkcxnT0+hHw9K94N7AglPMCk=; b=YDVKjJp2pPQoMlsGjDonjnsY8TRYVPIQXXdwdTf16NINvNc/L/5dTkyXGYaizDOxel IB65xyzMgtTTqqVbYLwAsIS8z+WpYPWhFbp48hZD0R5GKN9wb4QRtBlYulmOdGPUJo0P Xp1Uf0x7w6nlE5euRt7dfGo4E5/xG5AWVAZhW/SiQLys5bvn30vV6HibPsg9IpAz61Bg G56pHXPtBcxzfMinndKVP9xbbn7Z0B0CsDbEN5D7b50TcGEq7f9bpC/dDmO+QCukMbDv RK13dQHH+/Tv6p0VIDCpQxbXXtOhp0SJy5ZZKtFvxYp+7C8ImexggGrFbg+Ja7QKrHQH FoEA== X-Gm-Message-State: APjAAAXuI++nl1DQY2jCDoUp9HPC50pgfjkAaNcefyvhhLMp+6/E7+16 7ZKFKZzmEPD/c60BIavqhVLI/oaRX9MmGi4wEWRMdg== X-Google-Smtp-Source: APXvYqyx8zptIK3w5vUtWk3PhZAa/hB3/A5yVkpF+VFkRqZoaLjHN8vE3cmvhvPhSOKRrIj5EtmBYHxF2q44v2pBTVE= X-Received: by 2002:ac8:140a:: with SMTP id k10mr14189281qtj.175.1563464899306; Thu, 18 Jul 2019 08:48:19 -0700 (PDT) MIME-Version: 1.0 References: <721ab68d-cde4-41bb-c105-d15cf07903fa@FreeBSD.org> In-Reply-To: From: Warner Losh Date: Thu, 18 Jul 2019 09:48:07 -0600 Message-ID: Subject: Re: Resetting console on boot To: Ryan Moeller Cc: "freebsd-hackers@freebsd.org" X-Rspamd-Queue-Id: 580D88D95B X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=krBKPkNQ X-Spamd-Result: default: False [-5.96 / 15.00]; ARC_NA(0.00)[]; TO_DN_EQ_ADDR_SOME(0.00)[]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; NEURAL_HAM_MEDIUM(-1.00)[-0.996,0]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_SHORT(-0.95)[-0.949,0]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[2.3.8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; MX_GOOD(-0.01)[ALT1.aspmx.l.google.com,aspmx.l.google.com,ALT2.aspmx.l.google.com]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; IP_SCORE(-3.01)[ip: (-9.41), ipnet: 2607:f8b0::/32(-3.15), asn: 15169(-2.44), country: US(-0.05)]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 15:48:21 -0000 And sometimes having both leads to the problem... vidconsole is not a total solution. Warner On Thu, Jul 18, 2019 at 8:57 AM Ryan Moeller wrote: > Apparently this also could be wanted with vidconsole, as some IPMI console > redirection to com1 and serial over lan redirects from the vidconsole. I > just discovered this while testing Lev's patches. > > -Ryan > > On Tue, Jul 16, 2019 at 11:08 AM Warner Losh wrote: > > > > > > > On Tue, Jul 16, 2019 at 4:55 AM Lev Serebryakov wrote: > > > >> On 15.07.2019 23:29, Ryan Moeller wrote: > >> > >> > What do people think about having an early boot stage send some escape > >> > sequence to reset terminals to some sane default terminal settings? > >> Often > >> > firmware or other causes will leave an unreadable font color or break > >> line > >> > feeds, and the terminal tends to stay that way until a shell clears > and > >> > resets the screen. If a shell can do it, surely loader could do it (or > >> even > >> > earlier, if it is not too complex). To my knowledge it should be just > a > >> > matter of printing some escape codes before starting the normal boot > >> menus > >> > when using a serial console. I believe this is already done when the > >> > console is set to vidconsole or efi. > >> > > >> > Thoughts? Suggestions? > >> > >> I've proposed this long ago for serial terminals: > >> > >> https://reviews.freebsd.org/D17102 > >> https://reviews.freebsd.org/D17103 > >> > >> I have hardware which sets "black on black" before passing control to > OS. > >> > > > > That would work for the BIOS case, but not the UEFI case, which is where > I > > see the biggest issues. > > > > Warner > > > > > -- > Ryan Moeller > iXsystems, Inc. > OS Developer > Email: ryan@iXsystems.com > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > From owner-freebsd-hackers@freebsd.org Thu Jul 18 17:22:57 2019 Return-Path: Delivered-To: freebsd-hackers@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 67617AD79C for ; Thu, 18 Jul 2019 17:22:57 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-qt1-x82e.google.com (mail-qt1-x82e.google.com [IPv6:2607:f8b0:4864:20::82e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 A71616A8C9 for ; Thu, 18 Jul 2019 17:22:56 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: by mail-qt1-x82e.google.com with SMTP id z4so28066655qtc.3 for ; Thu, 18 Jul 2019 10:22:56 -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=lrbMoYgD5MhrSzFalLlv+vGXH6DpzFuxgT+yGbQw58Y=; b=KgCUgq7NVDTAkSxNRD/T7US84+c53g++vsZ9mOOcW/RpAXjzRFelQ5FJkD92yx9YT2 uS5F4Lsjv+aodYPlNWSD2exWkvMvV2Dq+mVAptBZG5bempFrc9L3CWg3DOmL/G6eHW6X mKIjNBe/LV1dwAPrateV27k5ne5+ioXQi0dvTkY34Bow2DqT2XSxkRDl5GfQ8VIBWJWC GGICeUj1UM9skcYi/Qmr/oGSkjTxkWp/gt7a83k+I6eg6uUd4KNedH8EnOznfr61Wed8 bQtPcxvX4qBdcVabzUUs8kTuCTsyQVZRrpvml3Svy4am61QlD9egAhLZbGAw6k5sB3Zc KwHA== 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=lrbMoYgD5MhrSzFalLlv+vGXH6DpzFuxgT+yGbQw58Y=; b=qg5+N24OZbQ5ZE7rqaoMrQxJJg07+h6TxTVR8m45O51Y5CsrS43ZMmgnvhzFoafPiy 7hQ8ZUg8Bb3z4d2Id7BgWwpZV3pQ3EhsceAzLJk9E3a+kFpMoXPm4bSzFy+XcujBOb+u cdrTfHsGGggjvQA4yQsV+1CnJY9aIWUMdrOZYDTRJE9z5vayHqc9tGLPTZPjBfMzN11p FIRm00rajklbS9uUlrKyJaijO6SGjGfAF4Tb0LjeTpnqgXLzSFK7WSGN2Kocwb1zZjZU HDfK1zWE10IZ1xoqrvJmLJiCRFQfvkRzg9MhCbHfdt1zoewJV4USr1AaNGwScqDw4SxC bCWg== X-Gm-Message-State: APjAAAXoT3CqZkaoi4l2iyROr2eBETrjH5b54cVCrI6R33/nlekNYpcJ 24Bm8lCa2gc2wXBYccm9StbPPuySPdN1yOvX3xgqiQ== X-Google-Smtp-Source: APXvYqzwltgLj2uqt2mzIm/axMQRyD7yR3kZrVnIPCFML+RukaGCaSU8Aq+Z6rPh9DXj7jDAHhuQQNFiQzsjatESCM8= X-Received: by 2002:ac8:1c4:: with SMTP id b4mr32758277qtg.42.1563470576156; Thu, 18 Jul 2019 10:22:56 -0700 (PDT) MIME-Version: 1.0 References: <14ad0148-ebe6-5d13-54fa-f6711c4b43ab@demig.de> In-Reply-To: <14ad0148-ebe6-5d13-54fa-f6711c4b43ab@demig.de> From: Ryan Stone Date: Thu, 18 Jul 2019 13:22:45 -0400 Message-ID: Subject: Re: build custom kernel under FreeBSD 12 To: Norbert Koch Cc: freebsd-hackers@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: A71616A8C9 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=KgCUgq7N; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rysto32@gmail.com designates 2607:f8b0:4864:20::82e as permitted sender) smtp.mailfrom=rysto32@gmail.com X-Spamd-Result: default: False [-7.00 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2607:f8b0:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[e.2.8.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; RCVD_TLS_LAST(0.00)[]; NEURAL_HAM_SHORT(-0.99)[-0.990,0]; 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]; RCVD_COUNT_TWO(0.00)[2]; IP_SCORE(-3.00)[ip: (-9.35), ipnet: 2607:f8b0::/32(-3.14), asn: 15169(-2.44), country: US(-0.05)]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 17:22:57 -0000 How are you setting MAKEOBJDIRPREFIX? It needs to be set in your environment, i.e. $ export MAKEOBJDIRPREFIX=$HOME/obj $ make buildkernel Trying 'make MAKEOBJDIRPREFIX=$HOME/obj buildkernel' will fail in strange ways due to how make passes arguments to sub-makes. On Thu, Jul 18, 2019 at 9:53 AM Norbert Koch wrote: > > Hello. > > I am obviously too stupid to figure out how to build a custom kernel > as non-root user in a non-standard directory. > Under FreeBSD9/10/11 I could put src/ under my own directory > and start a kernel-compilation by just setting $MAKEOBJDIRPREFIX > accordingly. Doing this under FreeBSD12 gives me 'permission denied' > with 'config -d /usr/src/sys/GENERIC ...'. Seems like ${KRNLOBJDIR} is > not set correctly while the other parameters to config are. > I see that Makefiles differ between 12 and older releases. > ${OBJTOP} vs. ${OBJTREE}? > > So, what am I doing wrong? > > Thank you for any help. > > > *********************************************************************** > * demig Prozessautomatisierung GmbH * demig Anlagentechnik GmbH * > * * * > * Anschrift: Haardtstrasse 40 * Haardtstrasse 40 * > * D-57076 Siegen * D-57076 Siegen * > * Registergericht: Siegen HRB 2819 * Siegen HRB 5532 * > * Geschaeftsfuehrer: Joachim Herbst, * Joachim Herbst, * > * Winfried Held * Winfried Held * > * Telefon: +49 271 772020 * +49 271 772020 * > * Telefax: +49 271 74704 * +49 271 74704 * > * E-Mail: info@demig.de * at@demig.de * > * http://www.demig.de * http://www.demig.de * > *********************************************************************** > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@freebsd.org Thu Jul 18 19:29:59 2019 Return-Path: Delivered-To: freebsd-hackers@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 A80ACAF520 for ; Thu, 18 Jul 2019 19:29:59 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: from puchar.net (puchar.net [194.1.144.90]) (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 AB87A6E4C8 for ; Thu, 18 Jul 2019 19:29:58 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: Received: from 127.0.0.1 (localhost [127.0.0.1]) by puchar.net (8.15.2/8.15.2) with ESMTPS id x6IJTt7U040173 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Thu, 18 Jul 2019 21:29:55 +0200 (CEST) (envelope-from puchar-wojtek@puchar.net) Received: from localhost (puchar-wojtek@localhost) by puchar.net (8.15.2/8.15.2/Submit) with ESMTP id x6IJTtM6040170 for ; Thu, 18 Jul 2019 21:29:55 +0200 (CEST) (envelope-from puchar-wojtek@puchar.net) Date: Thu, 18 Jul 2019 21:29:55 +0200 (CEST) From: Wojciech Puchar To: freebsd-hackers@freebsd.org Subject: please help translate smartctl output to human language Message-ID: User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII X-Rspamd-Queue-Id: AB87A6E4C8 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of wojtek@puchar.net designates 194.1.144.90 as permitted sender) smtp.mailfrom=wojtek@puchar.net X-Spamd-Result: default: False [-6.74 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCVD_COUNT_THREE(0.00)[3]; RCVD_TLS_LAST(0.00)[]; MX_GOOD(-0.01)[puchar.net]; NEURAL_HAM_SHORT(-0.96)[-0.956,0]; RCVD_IN_DNSWL_NONE(0.00)[90.144.1.194.list.dnswl.org : 127.0.10.0]; IP_SCORE(-3.47)[ip: (-9.17), ipnet: 194.1.144.0/24(-4.59), asn: 43476(-3.67), country: PL(0.06)]; DMARC_NA(0.00)[puchar.net]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:43476, ipnet:194.1.144.0/24, country:PL]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2019 19:29:59 -0000 i am interested how much write-wear does my samsung SSD experienced relative to maximum allowed. on my 500GB samsung SSD smartctl says ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE 5 Reallocated_Sector_Ct 0x0033 100 100 010 Pre-fail Always - 0 9 Power_On_Hours 0x0032 093 093 000 Old_age Always - 31126 12 Power_Cycle_Count 0x0032 099 099 000 Old_age Always - 59 177 Wear_Leveling_Count 0x0013 095 095 000 Pre-fail Always - 88 179 Used_Rsvd_Blk_Cnt_Tot 0x0013 100 100 010 Pre-fail Always - 0 181 Program_Fail_Cnt_Total 0x0032 100 100 010 Old_age Always - 0 182 Erase_Fail_Count_Total 0x0032 100 100 010 Old_age Always - 0 183 Runtime_Bad_Block 0x0013 100 100 010 Pre-fail Always - 0 187 Uncorrectable_Error_Cnt 0x0032 100 100 000 Old_age Always - 0 190 Airflow_Temperature_Cel 0x0032 073 051 000 Old_age Always - 27 195 ECC_Error_Rate 0x001a 200 200 000 Old_age Always - 0 199 CRC_Error_Count 0x003e 100 100 000 Old_age Always - 0 235 POR_Recovery_Count 0x0012 099 099 000 Old_age Always - 28 241 Total_LBAs_Written 0x0032 099 099 000 Old_age Always - 115175140988 All seems fine but i'm not sure if i correctly understand VALUE, WORST, THRESH data for Total_LBAs_Written 50TB was written, so it's 100 times capacity. taking some write amplification in account (i use geli so no in drive compression have effect) it would be probably like 150-200. Value is 99. It was 100 when i bought it. Does it mean that in is 1% worn and can take 100 times more writes until it fails? or i am too optimistic? From owner-freebsd-hackers@freebsd.org Fri Jul 19 06:40:25 2019 Return-Path: Delivered-To: freebsd-hackers@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 89390BA76A for ; Fri, 19 Jul 2019 06:40:25 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from exch.demig.de (exch.demig.de [130.180.89.86]) (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 84A3689233 for ; Fri, 19 Jul 2019 06:40:23 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from [192.168.148.248] (port=55758 helo=SRV-FS-2.Demig.intra) by exch.demig.de with esmtps (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.82_1-5b7a7c0-XX) (envelope-from ) id 1hoMYs-0004i5-1B for freebsd-hackers@freebsd.org; Fri, 19 Jul 2019 08:40:10 +0200 Received: from [192.168.148.215] (192.168.148.215) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.439.0; Fri, 19 Jul 2019 08:40:05 +0200 X-CTCH-RefID: str=0001.0A0B0213.5D3165CA.0042, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 Subject: Re: build custom kernel under FreeBSD 12 To: References: <14ad0148-ebe6-5d13-54fa-f6711c4b43ab@demig.de> From: Norbert Koch Message-ID: Date: Fri, 19 Jul 2019 08:40:05 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: quoted-printable X-C2ProcessedOrg: e1e98c77-ec17-4cb1-9b24-fe57656077ed X-Rspamd-Queue-Id: 84A3689233 X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of nkoch@demig.de designates 130.180.89.86 as permitted sender) smtp.mailfrom=nkoch@demig.de X-Spamd-Result: default: False [2.30 / 15.00]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[demig.de]; NEURAL_SPAM_MEDIUM(0.37)[0.372,0]; RCPT_COUNT_ONE(0.00)[1]; RCVD_COUNT_THREE(0.00)[3]; RCVD_TLS_LAST(0.00)[]; NEURAL_SPAM_SHORT(0.93)[0.926,0]; MX_GOOD(-0.01)[cached: mx1.demig.de]; NEURAL_SPAM_LONG(0.56)[0.563,0]; IP_SCORE(0.75)[asn: 6830(3.82), country: AT(-0.10)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:6830, ipnet:130.180.64.0/18, country:AT]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 06:40:25 -0000 Here is a typescript: =1B12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ export=20 MAKEOBJDIRPREFIX=3D`realpath tmp` 12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ echo $MAKEOBJDIRPREFIX /usr/home/nk/src/kernel/src/tmp =1B12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ make buildkernel make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 341:=20 SYSTEM_COMPILER: Determined that CC=3Dcc matches the source tree. Not=20 bootstrapping a cross-compiler. make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 348:=20 SYSTEM_LINKER: libclang will be built for bootstrapping a cross-linker. -------------------------------------------------------------- >>> Kernel build for GENERIC started on Fri Jul 19 08:34:27 CEST 2019 -------------------------------------------------------------- =3D=3D=3D> GENERIC mkdir -p /usr/src/sys -------------------------------------------------------------- >>> stage 1: configuring the kernel -------------------------------------------------------------- cd /usr/home/nk/src/kernel/src/sys/i386/conf;=20 PATH=3D/usr/src/tmp/legacy/usr/sbin:/usr/src/tmp/legacy/usr/bin:/usr/src/tm= p/legacy/bin:/usr/src/tmp/usr/sbin:/usr/src/tmp/usr/bin:/sbin:/bin:/usr/sbi= n:/usr/bin=20 config=C2=A0 -d /usr/src/sys/GENERIC=C2=A0 -I=20 '/usr/home/nk/src/kernel/src/sys/i386/conf'=20 '/usr/home/nk/src/kernel/src/sys/i386/conf/GENERIC' config: /usr/src/sys/GENERIC: Permission denied *** Error code 2 Stop. make[1]: stopped in /usr/home/nk/src/kernel/src *** Error code 1 Stop. make: stopped in /usr/home/nk/src/kernel/src Am 2019-07-18 um 19:22 schrieb Ryan Stone: > How are you setting MAKEOBJDIRPREFIX? It needs to be set in your > environment, i.e. > > $ export MAKEOBJDIRPREFIX=3D$HOME/obj > $ make buildkernel > > Trying 'make MAKEOBJDIRPREFIX=3D$HOME/obj buildkernel' will fail in > strange ways due to how make passes arguments to sub-makes. > > On Thu, Jul 18, 2019 at 9:53 AM Norbert Koch wrote: >> Hello. >> >> I am obviously too stupid to figure out how to build a custom kernel >> as non-root user in a non-standard directory. >> Under FreeBSD9/10/11 I could put src/ under my own directory >> and start a kernel-compilation by just setting $MAKEOBJDIRPREFIX >> accordingly. Doing this under FreeBSD12 gives me 'permission denied' >> with 'config -d /usr/src/sys/GENERIC ...'. Seems like ${KRNLOBJDIR} is >> not set correctly while the other parameters to config are. >> I see that Makefiles differ between 12 and older releases. >> ${OBJTOP} vs. ${OBJTREE}? >> >> So, what am I doing wrong? >> >> Thank you for any help. >> >> >> *********************************************************************** >> * demig Prozessautomatisierung GmbH * demig Anlagentechnik GmbH * >> * * * >> * Anschrift: Haardtstrasse 40 * Haardtstrasse 40 * >> * D-57076 Siegen * D-57076 Siegen * >> * Registergericht: Siegen HRB 2819 * Siegen HRB 5532 * >> * Geschaeftsfuehrer: Joachim Herbst, * Joachim Herbst, * >> * Winfried Held * Winfried Held * >> * Telefon: +49 271 772020 * +49 271 772020 * >> * Telefax: +49 271 74704 * +49 271 74704 * >> * E-Mail: info@demig.de * at@demig.de * >> * http://www.demig.de * http://www.demig.de * >> *********************************************************************** >> _______________________________________________ >> freebsd-hackers@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.or= g" --=20 Dipl.-Ing. Norbert Koch Entwicklung Prozessregler From owner-freebsd-hackers@freebsd.org Fri Jul 19 07:28:04 2019 Return-Path: Delivered-To: freebsd-hackers@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 5590DBB760 for ; Fri, 19 Jul 2019 07:28:04 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: from mail-ed1-x543.google.com (mail-ed1-x543.google.com [IPv6:2a00:1450:4864:20::543]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 79F398A702 for ; Fri, 19 Jul 2019 07:28:03 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: by mail-ed1-x543.google.com with SMTP id x19so27685792eda.12 for ; Fri, 19 Jul 2019 00:28:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references:reply-to :mime-version:content-transfer-encoding; bh=F8Yk7OpX7lb7ry2gTpxXEMh8cHytWssoEEowaqssTfk=; b=CJg25rIa6kJ7npvFuuADMqeKOF87uM+O2eSSFJTyqmwrZGC+Tqv1knEr+W39giniSw wtQ0oWQfleqjVz5ppLyFavKq0c2w45dtsRcZ8NXHEOOTCoXETcJHH+pDeOqg1BwHpE6d MdiCWbR52XzHV9ZIyM4302qb2utbn/kfYW48vC7G6r7a20ewxTGjgcq5c55I3/kpM99Q CZcWKmsw2+JrJrs4CF4YRfvXPWEGwlXs3QRmCdvTsXQRx4TX2iqu9ppr6Ka0+lRMTADy PCoikE+KzuuBKRsoK+ojsyxecT2UgAe5LjQdRi6g12Jk4e2Y/pINgEYTdH5nTLMmeNF9 AVow== 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:cc:subject:message-id:in-reply-to :references:reply-to:mime-version:content-transfer-encoding; bh=F8Yk7OpX7lb7ry2gTpxXEMh8cHytWssoEEowaqssTfk=; b=uS4FXxO5ZdTLE/G6GDc9+wRw86vrPaZr5w78rC/7E9jpdtYaGwH18G9eNVK5B1E3Xl nphJJAtcRIa5IPJx9euxAsw2qFnv4EyogwDgubHh2p6CHTNAH3gM+E24dbghiyJqtaSd 35dBKYnlrsuM4GLAWJOy8hh9kZ0qy97cz4WTFFqNQrm2TTgEzYBFF5M2rTn2n1SEYSV1 l9yen1btL7jFDW6b+3iol3buem52qBB4YLbX/Az+Nw0MR/433Swu3nBzDDK1TSMI2fwt bdTd7j50DR6JLLJtMTKHrWCbqXzKTqjHaxT3KZTccfRP8BV/vNwCoLoyLBg+lsbIWCOO HvMQ== X-Gm-Message-State: APjAAAV/bI93aMXmVFC3wUylXS6BbeXN8hOuM9BgGzcDg9n3FQ/rSBbW nAE0Y23YrXDTn/EnsbrJHAE= X-Google-Smtp-Source: APXvYqy99gL6dRs4zdOzdT/e5SvMF0TAnQUqRnyAju1FWKAa18lN+7Pgxv+2xzFE8CEE6yahWkk+JQ== X-Received: by 2002:a05:6402:1557:: with SMTP id p23mr6105810edx.207.1563521282562; Fri, 19 Jul 2019 00:28:02 -0700 (PDT) Received: from ernst.home (p5B3BE16E.dip0.t-ipconnect.de. [91.59.225.110]) by smtp.gmail.com with ESMTPSA id z2sm5988847ejp.73.2019.07.19.00.28.01 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 19 Jul 2019 00:28:01 -0700 (PDT) Date: Fri, 19 Jul 2019 09:28:01 +0200 From: Gary Jennejohn To: Norbert Koch Cc: Subject: Re: build custom kernel under FreeBSD 12 Message-ID: <20190719092801.06bc415e@ernst.home> In-Reply-To: References: <14ad0148-ebe6-5d13-54fa-f6711c4b43ab@demig.de> Reply-To: gljennjohn@gmail.com X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 79F398A702 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=CJg25rIa; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of gljennjohn@gmail.com designates 2a00:1450:4864:20::543 as permitted sender) smtp.mailfrom=gljennjohn@gmail.com X-Spamd-Result: default: False [-4.99 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; HAS_REPLYTO(0.00)[gljennjohn@gmail.com]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; REPLYTO_ADDR_EQ_FROM(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.89)[-0.893,0]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; RCVD_TLS_LAST(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; FREEMAIL_REPLYTO(0.00)[gmail.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[3.4.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0]; IP_SCORE(-1.09)[ip: (-0.03), ipnet: 2a00:1450::/32(-2.92), asn: 15169(-2.43), country: US(-0.05)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 07:28:04 -0000 On Fri, 19 Jul 2019 08:40:05 +0200 Norbert Koch wrote: > Here is a typescript: > > 12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ export > MAKEOBJDIRPREFIX=`realpath tmp` > 12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ echo $MAKEOBJDIRPREFIX > /usr/home/nk/src/kernel/src/tmp > > 12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ make buildkernel > make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 341: > SYSTEM_COMPILER: Determined that CC=cc matches the source tree. Not > bootstrapping a cross-compiler. > make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 348: > SYSTEM_LINKER: libclang will be built for bootstrapping a cross-linker. > > -------------------------------------------------------------- > >>> Kernel build for GENERIC started on Fri Jul 19 08:34:27 CEST 2019 > -------------------------------------------------------------- > ===> GENERIC > mkdir -p /usr/src/sys > > -------------------------------------------------------------- > >>> stage 1: configuring the kernel > -------------------------------------------------------------- > cd /usr/home/nk/src/kernel/src/sys/i386/conf; > PATH=/usr/src/tmp/legacy/usr/sbin:/usr/src/tmp/legacy/usr/bin:/usr/src/tmp/legacy/bin:/usr/src/tmp/usr/sbin:/usr/src/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin > config__ -d /usr/src/sys/GENERIC__ -I > '/usr/home/nk/src/kernel/src/sys/i386/conf' > '/usr/home/nk/src/kernel/src/sys/i386/conf/GENERIC' > config: /usr/src/sys/GENERIC: Permission denied > *** Error code 2 > > Stop. > make[1]: stopped in /usr/home/nk/src/kernel/src > *** Error code 1 > > Stop. > make: stopped in /usr/home/nk/src/kernel/src > It's peculiar that you have a mix of /usr/src and /usr/home/nk/src. Looking at /usr/src/Makefile.inc1 it would appear that you may also have to set KRNLOBJDIR to /usr/home/nk/src/kernel/src. Does the tmp directory really exist? Seems like a weird choice. I did what Ryan suggested and was able to make build{kernel,world} from /usr/src with no problem. But I haven't modified the kernel sources. > > Am 2019-07-18 um 19:22 schrieb Ryan Stone: > > How are you setting MAKEOBJDIRPREFIX? It needs to be set in your > > environment, i.e. > > > > $ export MAKEOBJDIRPREFIX=$HOME/obj > > $ make buildkernel > > > > Trying 'make MAKEOBJDIRPREFIX=$HOME/obj buildkernel' will fail in > > strange ways due to how make passes arguments to sub-makes. > > > > On Thu, Jul 18, 2019 at 9:53 AM Norbert Koch wrote: > >> Hello. > >> > >> I am obviously too stupid to figure out how to build a custom kernel > >> as non-root user in a non-standard directory. > >> Under FreeBSD9/10/11 I could put src/ under my own directory > >> and start a kernel-compilation by just setting $MAKEOBJDIRPREFIX > >> accordingly. Doing this under FreeBSD12 gives me 'permission denied' > >> with 'config -d /usr/src/sys/GENERIC ...'. Seems like ${KRNLOBJDIR} is > >> not set correctly while the other parameters to config are. > >> I see that Makefiles differ between 12 and older releases. > >> ${OBJTOP} vs. ${OBJTREE}? > >> > >> So, what am I doing wrong? > >> > >> Thank you for any help. -- Gary Jennejohn From owner-freebsd-hackers@freebsd.org Fri Jul 19 09:19:24 2019 Return-Path: Delivered-To: freebsd-hackers@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 12459BD627 for ; Fri, 19 Jul 2019 09:19:24 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from exch.demig.de (exch.demig.de [130.180.89.86]) (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 5D50E8D5C4 for ; Fri, 19 Jul 2019 09:19:23 +0000 (UTC) (envelope-from nkoch@demig.de) Received: from [192.168.148.248] (port=64393 helo=SRV-FS-2.Demig.intra) by exch.demig.de with esmtps (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.82_1-5b7a7c0-XX) (envelope-from ) id 1hoP2p-00024w-2E for freebsd-hackers@freebsd.org; Fri, 19 Jul 2019 11:19:15 +0200 Received: from [192.168.148.215] (192.168.148.215) by SRV-FS-2 (192.168.148.248) with Microsoft SMTP Server (TLS) id 14.3.439.0; Fri, 19 Jul 2019 11:19:11 +0200 X-CTCH-RefID: str=0001.0A0B020C.5D318B13.0071, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 Subject: Re: build custom kernel under FreeBSD 12 To: References: <14ad0148-ebe6-5d13-54fa-f6711c4b43ab@demig.de> <20190719092801.06bc415e@ernst.home> From: Norbert Koch Message-ID: Date: Fri, 19 Jul 2019 11:19:11 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <20190719092801.06bc415e@ernst.home> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: quoted-printable X-C2ProcessedOrg: e1e98c77-ec17-4cb1-9b24-fe57656077ed X-Rspamd-Queue-Id: 5D50E8D5C4 X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of nkoch@demig.de designates 130.180.89.86 as permitted sender) smtp.mailfrom=nkoch@demig.de X-Spamd-Result: default: False [1.79 / 15.00]; R_SPF_ALLOW(-0.20)[+mx]; TO_DN_NONE(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[cached: mx1.demig.de]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:6830, ipnet:130.180.64.0/18, country:AT]; MID_RHS_MATCH_FROM(0.00)[]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(0.24)[0.240,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[demig.de]; NEURAL_SPAM_MEDIUM(0.50)[0.499,0]; RCPT_COUNT_ONE(0.00)[1]; IP_SCORE(0.75)[asn: 6830(3.82), country: AT(-0.10)]; NEURAL_SPAM_LONG(0.62)[0.618,0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 09:19:24 -0000 I did some more testing. When I copy the src tree and set $MAKEOBJDIRPREFIX accordingly, I can run "make kernel-toolchain && make buildkernel" without problems. The permission denied error comes only when I symlink /usr/src/* and only copy sys/ to my local directory. So, my idea is that=C2=A0 FreeBSD12 differ= s from 11 and 10 by using something like realpath in either some Makefile or make itself. ***************************************** * demig Prozessautomatisierung GmbH * * * * Anschrift: Haardtstrasse 40 * * D-57076 Siegen * * Registergericht: Siegen HRB 2819 * * Geschaeftsfuehrer: Joachim Herbst, * * Winfried Held * * Telefon: +49 271 772020 * * Telefax: +49 271 74704 * * E-Mail: info@demig.de * * http://www.demig.de * ***************************************** Am 2019-07-19 um 09:28 schrieb Gary Jennejohn: > On Fri, 19 Jul 2019 08:40:05 +0200 > Norbert Koch wrote: > >> Here is a typescript: >> >> =1B12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ export >> MAKEOBJDIRPREFIX=3D`realpath tmp` >> 12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ echo $MAKEOBJDIRPRE= FIX >> /usr/home/nk/src/kernel/src/tmp >> >> =1B12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ make buildkernel >> make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 341: >> SYSTEM_COMPILER: Determined that CC=3Dcc matches the source tree. Not >> bootstrapping a cross-compiler. >> make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 348: >> SYSTEM_LINKER: libclang will be built for bootstrapping a cross-linker. >> >> -------------------------------------------------------------- >> >>> Kernel build for GENERIC started on Fri Jul 19 08:34:27 CEST 2019 >> -------------------------------------------------------------- >> =3D=3D=3D> GENERIC >> mkdir -p /usr/src/sys >> >> -------------------------------------------------------------- >> >>> stage 1: configuring the kernel >> -------------------------------------------------------------- >> cd /usr/home/nk/src/kernel/src/sys/i386/conf; >> PATH=3D/usr/src/tmp/legacy/usr/sbin:/usr/src/tmp/legacy/usr/bin:/usr/src= /tmp/legacy/bin:/usr/src/tmp/usr/sbin:/usr/src/tmp/usr/bin:/sbin:/bin:/usr/= sbin:/usr/bin >> config__ -d /usr/src/sys/GENERIC__ -I >> '/usr/home/nk/src/kernel/src/sys/i386/conf' >> '/usr/home/nk/src/kernel/src/sys/i386/conf/GENERIC' >> config: /usr/src/sys/GENERIC: Permission denied >> *** Error code 2 >> >> Stop. >> make[1]: stopped in /usr/home/nk/src/kernel/src >> *** Error code 1 >> >> Stop. >> make: stopped in /usr/home/nk/src/kernel/src >> > It's peculiar that you have a mix of /usr/src and /usr/home/nk/src. > Looking at /usr/src/Makefile.inc1 it would appear that you may also > have to set KRNLOBJDIR to /usr/home/nk/src/kernel/src. > > Does the tmp directory really exist? Seems like a weird choice. > > I did what Ryan suggested and was able to make build{kernel,world} > from /usr/src with no problem. But I haven't modified the kernel > sources. > >> Am 2019-07-18 um 19:22 schrieb Ryan Stone: >>> How are you setting MAKEOBJDIRPREFIX? It needs to be set in your >>> environment, i.e. >>> >>> $ export MAKEOBJDIRPREFIX=3D$HOME/obj >>> $ make buildkernel >>> >>> Trying 'make MAKEOBJDIRPREFIX=3D$HOME/obj buildkernel' will fail in >>> strange ways due to how make passes arguments to sub-makes. >>> >>> On Thu, Jul 18, 2019 at 9:53 AM Norbert Koch wrote: >>>> Hello. >>>> >>>> I am obviously too stupid to figure out how to build a custom kernel >>>> as non-root user in a non-standard directory. >>>> Under FreeBSD9/10/11 I could put src/ under my own directory >>>> and start a kernel-compilation by just setting $MAKEOBJDIRPREFIX >>>> accordingly. Doing this under FreeBSD12 gives me 'permission denied' >>>> with 'config -d /usr/src/sys/GENERIC ...'. Seems like ${KRNLOBJDIR} is >>>> not set correctly while the other parameters to config are. >>>> I see that Makefiles differ between 12 and older releases. >>>> ${OBJTOP} vs. ${OBJTREE}? >>>> >>>> So, what am I doing wrong? >>>> >>>> Thank you for any help. --=20 Dipl.-Ing. Norbert Koch Entwicklung Prozessregler From owner-freebsd-hackers@freebsd.org Fri Jul 19 10:55:48 2019 Return-Path: Delivered-To: freebsd-hackers@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 3A705BED94 for ; Fri, 19 Jul 2019 10:55:48 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id F3FFA8FD79 for ; Fri, 19 Jul 2019 10:55:47 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id F159FBED93; Fri, 19 Jul 2019 10:55:47 +0000 (UTC) Delivered-To: hackers@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 EFE9DBED92 for ; Fri, 19 Jul 2019 10:55:47 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 070CA8FD78; Fri, 19 Jul 2019 10:55:46 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x542.google.com with SMTP id d4so34127118edr.13; Fri, 19 Jul 2019 03:55:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=+v/q/Kq9kVlLANsq4HNTgwMx99dRc0kPeTP6hxdzkwI=; b=UG93SWJjSEU2kj18MHsqOUH+MnFmE21IaXKAic1NvzTV1QTBOsGVDCIW5jPBfXRCa8 sWoJrpttFWrmZTawLHDhYHk2NjlCSj0Ek7mfIEs9D0uh8xCt7CYXdZMSAKDC+hZjzB2m A0qDko609fxxeE08yYbqmNCUfJhHIvtJlEEL3ZHYi7/eijpMNcCF2f4Mw4UnGbWKRi+9 njQrtToEmD+BjUjbrazkpvFQyUvvt82nzNSaEC2aAfF0Rt1droyPDoQGuGzDMDd1h1Hw H6L1eEUyRh27Hw12LJaf3CqKXsU1SuexIwSZmNiFtuuWzmAvafr90V6+JpTNR7PZS6Cs ltBw== 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:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=+v/q/Kq9kVlLANsq4HNTgwMx99dRc0kPeTP6hxdzkwI=; b=bMK4BWEPLwIFVjnhFHL5/PqVuoVDthwCy2YmisogVFm5ou0IHurgYMHTjkhof5A4lV pi3vH37UFL5GyYHcbVmTsrdISx+usMrexk1sGqcqPuSlcbLU7NgaTkeNt7Dd/f/CV8ju AtgAW6fbGSwLSIcBsVkGlIojx1lr/Ay56nqdSrD4+5ox3RJjeQDy8diZDRnBgrmok4/G 6T/fRlltiJZT4f9Sf5FXss1o7ZufVaJWWMcSosH+NXidQroqdo2Zw/W+RKExwkJiYsDv avauWzWO1lRtWnaJBgeeaiYElUKoSTFLoJiB+1LseK2qEXhxzJHLs2d6mul38CSCHpZW N/nw== X-Gm-Message-State: APjAAAXmLrVP/TYBr/MdfxwfYd0P2ZWijFI/CwkhN/9mHISqxdxBEhvG S0rpynhRTcB4TLDvlHRQIGuPGSLB X-Google-Smtp-Source: APXvYqxdknOZziW3/PQaFRek2y6BlSWce2mzqoIW93agbvDzbcLALnr+4bZcaeKCN8XDVUpRMDavfg== X-Received: by 2002:a17:906:4d88:: with SMTP id s8mr39121509eju.225.1563533745844; Fri, 19 Jul 2019 03:55:45 -0700 (PDT) Received: from localhost ([213.149.55.147]) by smtp.gmail.com with ESMTPSA id c49sm8815960eda.74.2019.07.19.03.55.45 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 19 Jul 2019 03:55:45 -0700 (PDT) Date: Fri, 19 Jul 2019 12:54:55 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: Ravi Pokala Cc: larry.maloney@hackerdojo.com, hackers@freebsd.org Subject: Re: For a first time completed S.M.A.R.T captive test Message-ID: <20190719125455.0000473d@gmail.com> In-Reply-To: <481465DB-D5EE-4019-A2DB-DBA4D46FE312@freebsd.org> References: <481465DB-D5EE-4019-A2DB-DBA4D46FE312@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 070CA8FD78 X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=UG93SWJj; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rank1seeker@gmail.com designates 2a00:1450:4864:20::542 as permitted sender) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-5.09 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DKIM_TRACE(0.00)[gmail.com:+]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; NEURAL_HAM_SHORT(-0.96)[-0.962,0]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; IP_SCORE(-1.12)[ip: (-0.17), ipnet: 2a00:1450::/32(-2.92), asn: 15169(-2.43), country: US(-0.05)]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2.4.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 10:55:48 -0000 On Wed, 17 Jul 2019 19:37:25 -0700 Ravi Pokala wrote: > Hi Domagoj >=20 > The "captive" test is blocking -- meaning the drive won't indicate > command completion for multiple hours in the case of modern large > HDDs -- so the FreeBSD driver will almost certainly timeout before > completion. That in turn will trigger recovery mechanisms, which will > include a soft-reset, which is where the "Interrupted (host reset)" > comes from. >=20 > You almost always want to do the "off-line" test; that tells the > drive firmware to start the test and run it in the background. It > will indicate command completion in a second or two, but the test > will still take the same amount of time. But in the case of the > "off-line" test, the drive is responsive to the host even while the > test runs. When the drive receives a command from the host, it will > pause the test, service the host request, and then resume the test. Thanks. I knew that part. It was a captive test that was a riddle. > I work at a storage company, I've been running ATA self-test for 15+ > years, and I've never understood why the "captive" test even exists. > *Maybe* there were dedicated drive test systems that had huge > timeouts, back in the PATA days? Or even horrible DOS stuff that > didn't even have a timeout, and just waited for the interrupt > forever? I can understand devs of smartmontools, like, if code for captive test already exists, why to remove it? But then again, it just sends a test request to drive's firmware, so ... Why are all corporations, which manufacture storage devices, still write drive's firmware with captive test ability? > In any case, I would simply not bother with the "captive" test modes. Now that all is clear and I succeeded in completing a captive test, purely out of curiosity, I won't bother anymore. =20 > -Ravi (rpokala@) Domagoj Smol=C4=8Di=C4=87 From owner-freebsd-hackers@freebsd.org Fri Jul 19 11:55:30 2019 Return-Path: Delivered-To: freebsd-hackers@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 44A01BFB3D for ; Fri, 19 Jul 2019 11:55:30 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 09B3C6A9AD for ; Fri, 19 Jul 2019 11:55:30 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mailman.nyi.freebsd.org (Postfix) id 071E4BFB3C; Fri, 19 Jul 2019 11:55:30 +0000 (UTC) Delivered-To: hackers@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 05B5CBFB3B for ; Fri, 19 Jul 2019 11:55:30 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x543.google.com (mail-ed1-x543.google.com [IPv6:2a00:1450:4864:20::543]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 C2A396A9AC; Fri, 19 Jul 2019 11:55:28 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x543.google.com with SMTP id k8so34224611edr.11; Fri, 19 Jul 2019 04:55:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=bcEkfmdr/s37zzViADmMAHY2XytIlAQ2WW5Mjxzl40c=; b=KlvCNIXewztpIaGaHjSNegK6plzxXvqoCRMsaz3AWSRWS9UthJS02I7x0XpFEXuTbS LNN698BR6imU1KxU8dRQXXRsXyvNgwfEHp69SECKGGjh3RQtyBCkltxTGBrL++O8qVs6 UbHNr0o6C4QCqJJKB7TK7MeZ5j9La2BJp5UvcvrQJQZUqWadf32yWlDWMoToP5yeMqNi 4cCusGF+1n0JA2WQGn2CArBAQN9osVjub+9yRh+TveI+mAldtvGswf2eWg9mUy/o7ZgZ 5hMhX4f/fy6X7Hg3QmL9WEfaEX7CqQcLv8MOAVRsg9i4xOtWpyK7qBIA7uLhSEVGDUPg LejQ== 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:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=bcEkfmdr/s37zzViADmMAHY2XytIlAQ2WW5Mjxzl40c=; b=fT19zSK3FuhyNF/KMtBQxOJ6izxzNU1+mlPIIZepSO0U2ohkwU7h4LqcLi46gq3ntE mp3GG1EIOCFlhyuAeQjUXiVdspoMaKwbuBC62/hPyiqWvCv2gDeIrBtgVVY3+5vnFRC9 mJIQSCoe+zNmn0hhw1WTG5FwxrvRtMBPO9fnf7YKEQWUSy8+B/EAcfcpbicjn6Q3HSsX lLLLp28r5KGZBH94ir3bH3iCII4bjqXXqsQdOcrXzy32j9aVOmv4SIgLCQHYhazSMpG2 muC3Mzdjzn3pVf8HWGCrLkG00hhtKHFWDqo+XgoXqbDm5pKD5yIwExyDM9bNNVU8DLcK QtJw== X-Gm-Message-State: APjAAAULPqjyXsGVCH/i0AuElFPR+dEiOU86cPGl937QSlWR/Fc2FOGc 7jyQ8w15BcpO2otybowxE0y5/P/Y7r0= X-Google-Smtp-Source: APXvYqzdyNzUI+G1BGNn50tnmwpxspIZNo/b02zqPPXEOoNvoYaOQaprnKS+wQFH5xtPxZkl5QKU6A== X-Received: by 2002:a17:906:4a10:: with SMTP id w16mr40571516eju.299.1563537327746; Fri, 19 Jul 2019 04:55:27 -0700 (PDT) Received: from localhost ([213.149.55.147]) by smtp.gmail.com with ESMTPSA id u24sm6169950ejr.20.2019.07.19.04.55.27 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 19 Jul 2019 04:55:27 -0700 (PDT) Date: Fri, 19 Jul 2019 13:54:37 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: Warner Losh Cc: hackers@freebsd.org, delphij@FreeBSD.org Subject: Re: Device's "stolen" sector Message-ID: <20190719135437.00002536@gmail.com> In-Reply-To: References: <20190716182350.000054f8@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: C2A396A9AC X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=KlvCNIXe; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rank1seeker@gmail.com designates 2a00:1450:4864:20::543 as permitted sender) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-5.06 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[gmail.com:+]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; NEURAL_HAM_SHORT(-0.96)[-0.962,0]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; IP_SCORE(-1.09)[ip: (-0.03), ipnet: 2a00:1450::/32(-2.92), asn: 15169(-2.43), country: US(-0.05)]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[3.4.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 11:55:30 -0000 On Tue, 16 Jul 2019 10:45:07 -0600 Warner Losh wrote: > On Tue, Jul 16, 2019 at 10:25 AM Domagoj Smol=C4=8Di=C4=87 > wrote: >=20 > > 11.2-RELEASE-p9 > > > > Tested with >1 disks: > > -- > > SATA disk connected directly with SATA cable to MBO, shows correct > > amount of sectors. > > diskinfo -v ada1 > > > > When I connect it to the same MBO over USB to SATA adapter, 1 > > sector is missing (the last one) > > diskinfo -v da0 > > > > Having last sector inaccessible is a huge problem as many "things" > > use it for a metadata. > > This has many times caused MBR disks occasionally to not be visible > > at all while being 'da0' (gpart: No such geom: da0.) > > And also GPT disks to be in a [CORRUPT] state upon reattach > > directly to SATA interface. > > > > Before submitting a bug, there is only 1 variable left that I can't > > test, because I have only 1 USB to SATA adapter. > > It might be a hardware issue, so can someone else test this too? > > =20 >=20 > On 11.x, I'd install the sg3_util port. You'll need the sg device in > your kernel. Note: This isn't GENERIC kernel and has only what hardware needs. Even with: 'device sg' I'm getting error for all sg_* CMDs: CAM status: CCB request was invalid Adding: 'device ses #Enclosure Services (SES and SAF-TE)' hasn't helped too. PS: Yes i did '# kldload linux' Port hasn't specified mandatory devices! > Use sg_readcap on /dev/da0 to see if the numbers match > the devinfo from ada1. If they match, then we have a bug in the da > driver. If they differ, you have hardware issues in the USB to SATA > adapter. >=20 > Warner sg_* is being used to query device's size by sending SCSI commands directly= to device, through da driver's node, thus ignoring 'da' driver's response of device's = size to i.e; diskinfo? Domagoj Smol=C4=8Di=C4=87 From owner-freebsd-hackers@freebsd.org Fri Jul 19 12:23:22 2019 Return-Path: Delivered-To: freebsd-hackers@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 1F484A19DE for ; Fri, 19 Jul 2019 12:23:22 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 EDB246B79E for ; Fri, 19 Jul 2019 12:23:20 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x542.google.com with SMTP id k21so34351034edq.3 for ; Fri, 19 Jul 2019 05:23:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=t0Ns6AYmIIEShfvw9Nb1XY1YET3dryE6Vf2yuZNngeU=; b=HQkzUt40SFYqMe3na5JnM9osWbJyu1QQrS5h/970iZCyV4K0zj1FEWKAUNQTbGBUWS v1gO0dvFftgaUHImUFaFFocykkI3jBkCAX/3dQv+UJODbq54CR6jZ7g54lZuE3UfP2C2 FK/GEA89Liq+1rEWic+ITo+9i3pckryuL02Gh0ZTF1gwxB4TZPvcP/6IHvLO35KkN11W fl5zNDmHEUJEehRWP2zcjpqUd1/agkBSvGGuVWyy1TpjsYlCwO1QvfiDNXxZ/iY1Jfv9 bIFB8AEkqsnNI08wXMh7Q/E7E5QHbgw3vguf7KVXjWLmDXl5krhb+yzdfOXo9TsydkS4 ZIVA== 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=t0Ns6AYmIIEShfvw9Nb1XY1YET3dryE6Vf2yuZNngeU=; b=aC1vk8bEXPpnV/MCmGyCNvhz8J0AFrztD06bzLmZ78A+Kpj8g1RC6GswfXOwSQmWgV dnISB1V95EwsfKUPdXdTJaLcCASXBni8DNOgTA0Gq9SZytuaITZ30z3nnHuTqNfNAa8a 1D0BV2+iRMiHqhVBQUph76uyk74saPpJeM4p9TJskX+hIT0WdQPNQb/k/FKc8/kx5oPt mkjK33EjAZ1iYaWQq9ZVtaQPlBj2S+Q6k2TDZ2HpNkSAODUVFe/cByZzDvx+Qq0hCQGE WObe6aAI4MBYO5LhbYG5zxbYWUgQsT+/JKGg5WFNM0p+wkum8x1ZsMnj8Pclt3aY1bn0 pihg== X-Gm-Message-State: APjAAAXuRjZIX5ccgC60mIf9qMyMAekDGpATOJW6rHTHh/dPBV+x7WuL jHazbUkd5RyPpKXMohjM6UZEByxcuH4= X-Google-Smtp-Source: APXvYqwmxFblQHIHRjDjM5Hw/cA1w9pTUoGcpos2Pocm6Q12saUL1h44XJCE4nknbfCUIZPTx+DHtw== X-Received: by 2002:aa7:cf90:: with SMTP id z16mr44907596edx.228.1563538999742; Fri, 19 Jul 2019 05:23:19 -0700 (PDT) Received: from localhost ([213.149.55.147]) by smtp.gmail.com with ESMTPSA id b53sm8697003edd.45.2019.07.19.05.23.18 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 19 Jul 2019 05:23:19 -0700 (PDT) Date: Fri, 19 Jul 2019 14:22:27 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: freebsd-hackers@freebsd.org, Wojciech Puchar Subject: Re: please help translate smartctl output to human language Message-ID: <20190719142227.00005348@gmail.com> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: EDB246B79E X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=HQkzUt40; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rank1seeker@gmail.com designates 2a00:1450:4864:20::542 as permitted sender) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-5.11 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[gmail.com:+]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.99)[-0.986,0]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2.4.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0]; IP_SCORE(-1.12)[ip: (-0.18), ipnet: 2a00:1450::/32(-2.93), asn: 15169(-2.43), country: US(-0.05)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 12:23:22 -0000 On Thu, 18 Jul 2019 21:29:55 +0200 (CEST) Wojciech Puchar wrote: > i am interested how much write-wear does my samsung SSD experienced=20 > relative to maximum allowed. >=20 > on my 500GB samsung SSD smartctl says >=20 > ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE > UPDATED WHEN_FAILED RAW_VALUE > 5 Reallocated_Sector_Ct 0x0033 100 100 010 Pre-fail > Always=20 > - 0 > 9 Power_On_Hours 0x0032 093 093 000 Old_age > Always=20 > - 31126 > 12 Power_Cycle_Count 0x0032 099 099 000 Old_age > Always=20 > - 59 > 177 Wear_Leveling_Count 0x0013 095 095 000 Pre-fail > Always=20 > - 88 > 179 Used_Rsvd_Blk_Cnt_Tot 0x0013 100 100 010 Pre-fail > Always=20 > - 0 > 181 Program_Fail_Cnt_Total 0x0032 100 100 010 Old_age > Always=20 > - 0 > 182 Erase_Fail_Count_Total 0x0032 100 100 010 Old_age > Always=20 > - 0 > 183 Runtime_Bad_Block 0x0013 100 100 010 Pre-fail > Always=20 > - 0 > 187 Uncorrectable_Error_Cnt 0x0032 100 100 000 Old_age > Always=20 > - 0 > 190 Airflow_Temperature_Cel 0x0032 073 051 000 Old_age > Always=20 > - 27 > 195 ECC_Error_Rate 0x001a 200 200 000 Old_age > Always=20 > - 0 > 199 CRC_Error_Count 0x003e 100 100 000 Old_age > Always=20 > - 0 > 235 POR_Recovery_Count 0x0012 099 099 000 Old_age > Always=20 > - 28 > 241 Total_LBAs_Written 0x0032 099 099 000 Old_age > Always=20 > - 115175140988 >=20 >=20 >=20 >=20 > All seems fine but i'm not sure if i correctly understand VALUE, > WORST, THRESH data for Total_LBAs_Written >=20 > 50TB was written, so it's 100 times capacity. taking some write=20 > amplification in account (i use geli so no in drive compression have=20 > effect) it would be probably like 150-200. >=20 > Value is 99. It was 100 when i bought it. >=20 > Does it mean that in is 1% worn and can take 100 times more writes > until it fails? or i am too optimistic? > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to > "freebsd-hackers-unsubscribe@freebsd.org" Integers representing VALUE, WORST and THRESH columns are "normalized value= s". Over time, VALUE of Total_LBAs_Written will be declining. Once it reaches THRESH value it is considered 'Old_age', meaning it's prone to all kinds of malfunctions expected from old hardware. That doesn't mean you want be able to use it afterwards. Domagoj Smol=C4=8Di=C4=87 From owner-freebsd-hackers@freebsd.org Fri Jul 19 13:29:06 2019 Return-Path: Delivered-To: freebsd-hackers@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 6440EA2752 for ; Fri, 19 Jul 2019 13:29:06 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: from puchar.net (puchar.net [194.1.144.90]) (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 6F58F6CEA8 for ; Fri, 19 Jul 2019 13:29:05 +0000 (UTC) (envelope-from wojtek@puchar.net) Received: Received: from 127.0.0.1 (localhost [127.0.0.1]) by puchar.net (8.15.2/8.15.2) with ESMTPS id x6JDT4Lx086481 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Fri, 19 Jul 2019 15:29:05 +0200 (CEST) (envelope-from puchar-wojtek@puchar.net) Received: from localhost (puchar-wojtek@localhost) by puchar.net (8.15.2/8.15.2/Submit) with ESMTP id x6JDT4ED086478; Fri, 19 Jul 2019 15:29:04 +0200 (CEST) (envelope-from puchar-wojtek@puchar.net) Date: Fri, 19 Jul 2019 15:29:04 +0200 (CEST) From: Wojciech Puchar To: =?ISO-8859-2?Q?Domagoj_Smol=E8i=E6?= cc: freebsd-hackers@freebsd.org, Wojciech Puchar Subject: Re: please help translate smartctl output to human language In-Reply-To: <20190719142227.00005348@gmail.com> Message-ID: References: <20190719142227.00005348@gmail.com> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Rspamd-Queue-Id: 6F58F6CEA8 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of wojtek@puchar.net designates 194.1.144.90 as permitted sender) smtp.mailfrom=wojtek@puchar.net X-Spamd-Result: default: False [-6.78 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; R_SPF_ALLOW(-0.20)[+mx]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[puchar.net]; TO_DN_SOME(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: puchar.net]; NEURAL_HAM_SHORT(-0.99)[-0.991,0]; RCVD_IN_DNSWL_NONE(0.00)[90.144.1.194.list.dnswl.org : 127.0.10.0]; IP_SCORE(-3.48)[ip: (-9.18), ipnet: 194.1.144.0/24(-4.59), asn: 43476(-3.67), country: PL(0.06)]; FREEMAIL_TO(0.00)[gmail.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:43476, ipnet:194.1.144.0/24, country:PL]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 13:29:06 -0000 >> freebsd-hackers@freebsd.org mailing list >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers >> To unsubscribe, send any mail to >> "freebsd-hackers-unsubscribe@freebsd.org" > > > Integers representing VALUE, WORST and THRESH columns are "normalized values". > Over time, VALUE of Total_LBAs_Written will be declining. > Once it reaches THRESH value it is considered 'Old_age', meaning it's prone > to all kinds of malfunctions expected from old hardware. > That doesn't mean you want be able to use it afterwards. > > > > but are this proportional? I mean i had 100 when drive was new, now it's 99 so it's 1% used up (maybe near 2%)? Seems quite a little after 2 years of usage From owner-freebsd-hackers@freebsd.org Fri Jul 19 16:46:13 2019 Return-Path: Delivered-To: freebsd-hackers@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 60CABA6C51 for ; Fri, 19 Jul 2019 16:46:13 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: from mail-ed1-x52a.google.com (mail-ed1-x52a.google.com [IPv6:2a00:1450:4864:20::52a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) 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 7333475547 for ; Fri, 19 Jul 2019 16:46:12 +0000 (UTC) (envelope-from rank1seeker@gmail.com) Received: by mail-ed1-x52a.google.com with SMTP id r12so243804edo.5 for ; Fri, 19 Jul 2019 09:46:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=qG46FyVrG5OsBOy0NKRWmfX47WRveBv61bGCOWxihbQ=; b=Z1H6LQG6mjMyFyjXNBa6irtmFZ0ptWAOHtGkNNcYMA1iQuiUxA82yHt4uh4A8wv2hP Fpur/ZU4R2dAU2m70JLXbUGCwm65BI6GowjDm31jUpMvw7ynLO5Jo8yBawKqsezWvo8p hUhS85QGu15MVcy/GFzWNP6weW8EzNZS1rusuHCK+PAe3mHquNavvDdx2OTy2qNMf6Iz /s15dxxG+dmDoSUxMA4INjhssf4pRusowF/3lJSd1QwbmHquaOO0nWBKFSPxtr/drU2t N6ie2ak4kdez7qy0MGlqtRMR+FxW9hPGHD04rEK/h6BTBUxt0vIIaerIiKm1yBn34qRb 5gYw== 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:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=qG46FyVrG5OsBOy0NKRWmfX47WRveBv61bGCOWxihbQ=; b=Yyc6dC+GUc8rZg2yx9NZ6hpeOA7RBcGKaJ4FPCPzZe8AU2+ik5cshGyHJUEUDvVr3h RyRjDBfhCYzrM4UdeF6Iv0u+YjlEF8nVIo2Ax8QsbS3/c+YjUGHN2pf6vSkwDgKppQIM p/nPgahsI32szAH/67HHc7hL0MdjCy7y2Fegppa/oxdvRtzQe0/fmKtWV3trA6T8B8gG I+pemRkpYIG7NJW0NqawRgTA++wdBp+mAUu3Zn3QYDxAZSVRAEOtW0db1xnbtu7smnld hZrqXwUNIioaAPekybUSg9DYKf9iraYiHMnSMF0PnlUCsvReoaFALalLGbVZF21ON3xY vQzg== X-Gm-Message-State: APjAAAX+YrBpx730pc6MuHxNvGMiMG+/qbxTdWna1EJ4qu3nvPQlBB/R ZZqc/F4tYoGO5UrY8Ip5jPEK1p4yeUg= X-Google-Smtp-Source: APXvYqxj7rO/CNPfn+uvPlQLREeuJqh9bqk/dWawNrNHifACpqhJC95U4YnkXNpwd/ucY7HTmefZcw== X-Received: by 2002:a17:907:2177:: with SMTP id rl23mr42304772ejb.14.1563554771504; Fri, 19 Jul 2019 09:46:11 -0700 (PDT) Received: from localhost ([213.149.55.147]) by smtp.gmail.com with ESMTPSA id d12sm8654110edp.16.2019.07.19.09.46.10 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 19 Jul 2019 09:46:11 -0700 (PDT) Date: Fri, 19 Jul 2019 18:45:20 +0200 From: Domagoj =?UTF-8?Q?Smol=C4=8Di=C4=87?= To: Wojciech Puchar Cc: freebsd-hackers@freebsd.org Subject: Re: please help translate smartctl output to human language Message-ID: <20190719184520.0000221d@gmail.com> In-Reply-To: References: <20190719142227.00005348@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 7333475547 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20161025 header.b=Z1H6LQG6; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of rank1seeker@gmail.com designates 2a00:1450:4864:20::52a as permitted sender) smtp.mailfrom=rank1seeker@gmail.com X-Spamd-Result: default: False [-6.97 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36]; FREEMAIL_FROM(0.00)[gmail.com]; RCVD_COUNT_THREE(0.00)[3]; DKIM_TRACE(0.00)[gmail.com:+]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.99)[-0.985,0]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com.dwl.dnswl.org : 127.0.5.0]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20161025]; FROM_HAS_DN(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-hackers@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[a.2.5.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.5.4.1.0.0.a.2.list.dnswl.org : 127.0.5.0]; IP_SCORE(-2.97)[ip: (-9.44), ipnet: 2a00:1450::/32(-2.93), asn: 15169(-2.43), country: US(-0.05)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 16:46:13 -0000 On Fri, 19 Jul 2019 15:29:04 +0200 (CEST) Wojciech Puchar wrote: > >> freebsd-hackers@freebsd.org mailing list > >> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > >> To unsubscribe, send any mail to > >> "freebsd-hackers-unsubscribe@freebsd.org" =20 > > > > > > Integers representing VALUE, WORST and THRESH columns are > > "normalized values". Over time, VALUE of Total_LBAs_Written will be > > declining. Once it reaches THRESH value it is considered 'Old_age', > > meaning it's prone to all kinds of malfunctions expected from old > > hardware. That doesn't mean you want be able to use it afterwards. > > > > > > > > =20 > but are this proportional? I mean i had 100 when drive was new, now > it's 99 so it's 1% used up (maybe near 2%)? >=20 > Seems quite a little after 2 years of usage As I said, those are "normalized" values in order to have a MORE sensible i= nterpretation. Different vendors =3D> different interpretation. Just because it decremented for 1, doesn't mean it is trully 1% used up. What would that mean anyway, wear level? Also don't be shocked if decrement would be in >1 step. Finally, your device might drop dead 5 min after you read this email. Got an idea? ;) Domagoj Smol=C4=8Di=C4=87=20 From owner-freebsd-hackers@freebsd.org Fri Jul 19 19:38:02 2019 Return-Path: Delivered-To: freebsd-hackers@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 2C57AAA183 for ; Fri, 19 Jul 2019 19:38:02 +0000 (UTC) (envelope-from rpokala@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) server-signature RSA-PSS (4096 bits) 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 C6DCF836F9; Fri, 19 Jul 2019 19:38:01 +0000 (UTC) (envelope-from rpokala@freebsd.org) Received: from [172.17.133.69] (unknown [12.202.168.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: rpokala) by smtp.freebsd.org (Postfix) with ESMTPSA id 40F3B10986; Fri, 19 Jul 2019 19:38:01 +0000 (UTC) (envelope-from rpokala@freebsd.org) User-Agent: Microsoft-MacOutlook/10.1b.0.190715 Date: Fri, 19 Jul 2019 12:37:57 -0700 Subject: Re: please help translate smartctl output to human language From: Ravi Pokala To: , "freebsd-hackers@freebsd.org" Message-ID: <3082DC9C-9D05-499F-A4FE-712338A32D14@freebsd.org> Thread-Topic: please help translate smartctl output to human language Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: 7bit X-Rspamd-Queue-Id: C6DCF836F9 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.97 / 15.00]; local_wl_from(0.00)[freebsd.org]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; NEURAL_HAM_SHORT(-0.97)[-0.970,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; NEURAL_HAM_LONG(-1.00)[-1.000,0] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Jul 2019 19:38:02 -0000 Hi Wojciech, > i am interested how much write-wear does my samsung SSD experienced relative to maximum allowed. > > on my 500GB samsung SSD smartctl says > > ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE > 5 Reallocated_Sector_Ct 0x0033 100 100 010 Pre-fail Always - 0 > 9 Power_On_Hours 0x0032 093 093 000 Old_age Always - 31126 > 12 Power_Cycle_Count 0x0032 099 099 000 Old_age Always - 59 > 177 Wear_Leveling_Count 0x0013 095 095 000 Pre-fail Always - 88 > 179 Used_Rsvd_Blk_Cnt_Tot 0x0013 100 100 010 Pre-fail Always - 0 > 181 Program_Fail_Cnt_Total 0x0032 100 100 010 Old_age Always - 0 > 182 Erase_Fail_Count_Total 0x0032 100 100 010 Old_age Always - 0 > 183 Runtime_Bad_Block 0x0013 100 100 010 Pre-fail Always - 0 > 187 Uncorrectable_Error_Cnt 0x0032 100 100 000 Old_age Always - 0 > 190 Airflow_Temperature_Cel 0x0032 073 051 000 Old_age Always - 27 > 195 ECC_Error_Rate 0x001a 200 200 000 Old_age Always - 0 > 199 CRC_Error_Count 0x003e 100 100 000 Old_age Always - 0 > 235 POR_Recovery_Count 0x0012 099 099 000 Old_age Always - 28 > 241 Total_LBAs_Written 0x0032 099 099 000 Old_age Always - 115175140988 > > All seems fine but i'm not sure if i correctly understand VALUE, WORST, THRESH data for Total_LBAs_Written For (S)ATA SMART in general, the way it works is that "VALUE" is a normalized representation, with higher values being better than lower values. Depending on the vendor, the starting value might be 253 (aka 0xff, minus a few reserved values), 200, or 100 (aka a percentage). Or, in the case of temperatures, the value of "VALUE" is usually (100 - current temperature); in the example above, that's (100 - 27) => 73. "WORST" is the lowest value of "VALUE" that the device has recorded. Some attributes are related to performance or short-term metrics, so the value of "VALUE" might increase and decrease over time; in that case, "WORST" is somewhat useful. Other attributes are related to usage and wear, so the value of "VALUE" will only ever decrease; in those cases, "WORST" is not very useful because it will always be the same as "VALUE". "THRESH" is the failure threshold for the attribute; *if* the attribute is marked "Pre-fail", and *if* the value of "VALUE" is lower than the value of "THRESH", *then* the overall SMART status will be reported as failed. In the data above, everything looks quite good; even the lowest values for "WORST" are above 90. (Except the temperature, which as described above is a little different; in this case, it looks like the highest temperature the device has seen is 49C, which isn't great, but isn't terrible.) > 50TB was written, so it's 100 times capacity. taking some write amplification in account (i use geli so no in drive compression have effect) it would be probably like 150-200. Nowadays, SSDs are usually rated in terms of "Device Writes per Day" (DWPD); for a device rated at 3DWPD with a 3-year warranty, the vendor is saying that it can handle writes equivalent to (3 * 3 * 365) = 3285 complete overwrites of the device. In the case of this 500GB device, that would be roughly 1.5PB of writes. Assuming this device uses 512B logical sectors, 115175140988 LBAs written would be ~54TB, which is ~3.3% of the total writes. > Value is 99. It was 100 when i bought it. > > Does it mean that in is 1% worn and can take 100 times more writes until it fails? or i am too optimistic? There are a few reasons why the calculated wear (~3.3%) and the reported wear (100% - 99%) might differ. For starters, it's not clear if that value is the number of LBAs written by the host, or the number LBAs written to the NAND; it's possible for a request to write a single block to trigger remapping and garbage collection, resulting in write amplification. Conversely, some drives might detect when a block is being zeroed out, and might simply put a flag on the LBA and mark the underlying NAND as obsolete and ready for erasure, resulting in write suppression. In any case, the bottom line I see here is that this device doesn't seem anywhere near wearout. -Ravi (rpokala@) From owner-freebsd-hackers@freebsd.org Sat Jul 20 07:11:48 2019 Return-Path: Delivered-To: freebsd-hackers@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 A294EB6A4B for ; Sat, 20 Jul 2019 07:11:48 +0000 (UTC) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (br1.CN84in.dnsmgr.net [69.59.192.140]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8C9F57047A for ; Sat, 20 Jul 2019 07:11:47 +0000 (UTC) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (localhost [127.0.0.1]) by gndrsh.dnsmgr.net (8.13.3/8.13.3) with ESMTP id x6K7Bc87098402; Sat, 20 Jul 2019 00:11:38 -0700 (PDT) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: (from freebsd-rwg@localhost) by gndrsh.dnsmgr.net (8.13.3/8.13.3/Submit) id x6K7Baca098401; Sat, 20 Jul 2019 00:11:36 -0700 (PDT) (envelope-from freebsd-rwg) From: "Rodney W. Grimes" Message-Id: <201907200711.x6K7Baca098401@gndrsh.dnsmgr.net> Subject: Re: build custom kernel under FreeBSD 12 In-Reply-To: To: Norbert Koch Date: Sat, 20 Jul 2019 00:11:36 -0700 (PDT) CC: freebsd-hackers@freebsd.org X-Mailer: ELM [version 2.4ME+ PL121h (25)] MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=US-ASCII X-Rspamd-Queue-Id: 8C9F57047A X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [2.18 / 15.00]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_SPAM_SHORT(0.59)[0.594,0]; NEURAL_HAM_LONG(-0.01)[-0.015,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[dnsmgr.net]; AUTH_NA(1.00)[]; NEURAL_SPAM_MEDIUM(0.67)[0.668,0]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: gndrsh.dnsmgr.net]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:13868, ipnet:69.59.192.0/19, country:US]; MID_RHS_MATCH_FROM(0.00)[]; IP_SCORE(0.04)[ip: (0.15), ipnet: 69.59.192.0/19(0.07), asn: 13868(0.05), country: US(-0.05)] X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Jul 2019 07:11:48 -0000 > I did some more testing. >=20 > When I copy the src tree and set $MAKEOBJDIRPREFIX accordingly, I can > run "make kernel-toolchain && make buildkernel" without problems. >=20 > The permission denied error comes only when I symlink /usr/src/* and only > copy sys/ to my local directory. So, my idea is that? FreeBSD12 differs > from 11 and 10 by using something like realpath in either some Makefile > or make itself. It is most likely the munging of relative paths that use to be ../../foo into ${SRCTP}/foo that is the change causing issues with what you are doing. SRCTOP is probably changing values depnding on what location a submake was started from. > ***************************************** > * demig Prozessautomatisierung GmbH * > * * > * Anschrift: Haardtstrasse 40 * > * D-57076 Siegen * > * Registergericht: Siegen HRB 2819 * > * Geschaeftsfuehrer: Joachim Herbst, * > * Winfried Held * > * Telefon: +49 271 772020 * > * Telefax: +49 271 74704 * > * E-Mail: info@demig.de * > * http://www.demig.de * > ***************************************** > Am 2019-07-19 um 09:28 schrieb Gary Jennejohn: > > On Fri, 19 Jul 2019 08:40:05 +0200 > > Norbert Koch wrote: > > > >> Here is a typescript: > >> > >> =1B12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ export > >> MAKEOBJDIRPREFIX=3D`realpath tmp` > >> 12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ echo $MAKEOBJDIRP= REFIX > >> /usr/home/nk/src/kernel/src/tmp > >> > >> =1B12.0-RELEASE-p7 (3) nk@entw-pr4 [~/src/kernel/src] $ make buildkern= el > >> make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 341: > >> SYSTEM_COMPILER: Determined that CC=3Dcc matches the source tree. Not > >> bootstrapping a cross-compiler. > >> make[1]: "/usr/home/nk/src/kernel/src/Makefile.inc1" line 348: > >> SYSTEM_LINKER: libclang will be built for bootstrapping a cross-linker. > >> > >> -------------------------------------------------------------- > >> >>> Kernel build for GENERIC started on Fri Jul 19 08:34:27 CEST 2019 > >> -------------------------------------------------------------- > >> =3D=3D=3D> GENERIC > >> mkdir -p /usr/src/sys > >> > >> -------------------------------------------------------------- > >> >>> stage 1: configuring the kernel > >> -------------------------------------------------------------- > >> cd /usr/home/nk/src/kernel/src/sys/i386/conf; > >> PATH=3D/usr/src/tmp/legacy/usr/sbin:/usr/src/tmp/legacy/usr/bin:/usr/s= rc/tmp/legacy/bin:/usr/src/tmp/usr/sbin:/usr/src/tmp/usr/bin:/sbin:/bin:/us= r/sbin:/usr/bin > >> config__ -d /usr/src/sys/GENERIC__ -I > >> '/usr/home/nk/src/kernel/src/sys/i386/conf' > >> '/usr/home/nk/src/kernel/src/sys/i386/conf/GENERIC' > >> config: /usr/src/sys/GENERIC: Permission denied > >> *** Error code 2 > >> > >> Stop. > >> make[1]: stopped in /usr/home/nk/src/kernel/src > >> *** Error code 1 > >> > >> Stop. > >> make: stopped in /usr/home/nk/src/kernel/src > >> > > It's peculiar that you have a mix of /usr/src and /usr/home/nk/src. > > Looking at /usr/src/Makefile.inc1 it would appear that you may also > > have to set KRNLOBJDIR to /usr/home/nk/src/kernel/src. > > > > Does the tmp directory really exist? Seems like a weird choice. > > > > I did what Ryan suggested and was able to make build{kernel,world} > > from /usr/src with no problem. But I haven't modified the kernel > > sources. > > > >> Am 2019-07-18 um 19:22 schrieb Ryan Stone: > >>> How are you setting MAKEOBJDIRPREFIX? It needs to be set in your > >>> environment, i.e. > >>> > >>> $ export MAKEOBJDIRPREFIX=3D$HOME/obj > >>> $ make buildkernel > >>> > >>> Trying 'make MAKEOBJDIRPREFIX=3D$HOME/obj buildkernel' will fail in > >>> strange ways due to how make passes arguments to sub-makes. > >>> > >>> On Thu, Jul 18, 2019 at 9:53 AM Norbert Koch wrote: > >>>> Hello. > >>>> > >>>> I am obviously too stupid to figure out how to build a custom kernel > >>>> as non-root user in a non-standard directory. > >>>> Under FreeBSD9/10/11 I could put src/ under my own directory > >>>> and start a kernel-compilation by just setting $MAKEOBJDIRPREFIX > >>>> accordingly. Doing this under FreeBSD12 gives me 'permission denied' > >>>> with 'config -d /usr/src/sys/GENERIC ...'. Seems like ${KRNLOBJDIR} = is > >>>> not set correctly while the other parameters to config are. > >>>> I see that Makefiles differ between 12 and older releases. > >>>> ${OBJTOP} vs. ${OBJTREE}? > >>>> > >>>> So, what am I doing wrong? > >>>> > >>>> Thank you for any help. >=20 > --=20 > Dipl.-Ing. Norbert Koch > Entwicklung Prozessregler >=20 >=20 > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" >=20 >=20 --=20 Rod Grimes rgrimes@freebsd.= org