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