Re: smartctl - Can't run select span range

2018-07-06 Thread Ubence Quevedo
Hi Everyone, I figured out why I wasn't getting any results when my script was being kicked off by cron. It was because the path variable that the script was being launched from cron with didn't have smartctl in it. I added the following to my crontab setup: PATH=/opt/local/bin:/opt/local/sbin:/

Re: smartctl - Can't run select span range

2018-07-05 Thread Ubence Quevedo
Hi to anyone still tuned in on this smartctl thread... I created a script [which I'm sure could be a bit better]: #!/bin/bash # Starting echo Starting at `date` # Running a long smartctl test against /dev/disk0 smartctl -t force -t long /dev/disk0 > /dev/null # Running a long smartctl test against

Re: smartctl - Can't run select span range

2018-06-29 Thread Ubence Quevedo
Definitely going to give the sleep thing a try. Since I'm trying to automate this to kick off long smartctl tests at specific times, opening a separate window just for caffeinate won't be very efficient. I've got some ideas on how to script this out. I'd still love it if Apple would just allow s

Re: smartctl - Can't run select span range

2018-06-29 Thread Rainer Müller
On 2018-06-29 10:03, Ryan Schmidt wrote: > > On Jun 28, 2018, at 19:43, Ubence Quevedo wrote: > >> I gave caffeinate a try, and set my system sleep time to a more reasonable >> timeout [30 minutes], but since smartctl isn't an interactive process [a >> tsr?], the system never stays awake long e

Re: smartctl - Can't run select span range

2018-06-29 Thread Ryan Schmidt
On Jun 28, 2018, at 19:43, Ubence Quevedo wrote: > On Tue, Jun 26, 2018 at 9:31 PM Ryan Schmidt wrote: > >> On Jun 26, 2018, at 07:32, Ubence Quevedo wrote: >> >> > Ubences-MacBook-Pro:ata uquevedo$ smartctl -t long /dev/disk2 >> > smartctl 6.6 2017-11-05 r4594 [Darwin 17.6.0 x86_64] (local bu

Re: smartctl - Can't run select span range

2018-06-28 Thread Ubence Quevedo
I gave caffeinate a try, and set my system sleep time to a more reasonable timeout [30 minutes], but since smartctl isn't an interactive process [a tsr?], the system never stays awake long enough to finish a whole test. I even added the -m option to prevent the disk from idle sleeping but that did

Re: smartctl - Can't run select span range

2018-06-26 Thread Ryan Schmidt
On Jun 26, 2018, at 07:32, Ubence Quevedo wrote: > Ubences-MacBook-Pro:ata uquevedo$ smartctl -t long /dev/disk2 > smartctl 6.6 2017-11-05 r4594 [Darwin 17.6.0 x86_64] (local build) > Copyright (C) 2002-17, Bruce Allen, Christian Franke, www.smartmontools.org > > === START OF OFFLINE IMMEDIATE

Re: smartctl - Can't run select span range

2018-06-26 Thread Ubence Quevedo (thatrat)
Curses, I was really hoping to leverage that feature since a three and a half hour long test is not ideal [below test started at 5:22AM]: Ubences-MacBook-Pro:ata uquevedo$ smartctl -t long /dev/disk2 smartctl 6.6 2017-11-05 r4594 [Darwin 17.6.0 x86_64] (local build) Copyright (C) 2002-17, Bruce Al

Re: smartctl - Can't run select span range

2018-06-25 Thread Richard L. Hamilton
While I'm not absolutely certain, looking at one of the OS headers /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks/IOKit.framework/Versions/A/Headers/storage/ata/ATASMARTLib.h I don't think macOS supports any immediate offline tests other than short and long

Re: smartctl - Can't run select span range

2018-06-25 Thread Ubence Quevedo
Thanks for pointing this out. I’m disappointed this feature seems to be disabled in macOS. Looks like I’ll have to ask the smartmontools developers why this was left out of macOS. -Ubence On Mon, Jun 25, 2018 at 7:16 AM Richard L. Hamilton wrote: > Looks to me like the code purposely and inte

Re: smartctl - Can't run select span range

2018-06-25 Thread Richard L. Hamilton
Looks to me like the code purposely and intentionally disallows that on a Mac. No idea why - maybe the OS won't do it or doesn't like it. In os_darwin.cpp: 483 case ATA_SMART_IMMEDIATE_OFFLINE: 484 select = in.in_regs.lba_low; 485 if (select != SHORT_SELF_TEST && select !=

Re: smartctl - Can't run select span range

2018-06-25 Thread Ubence Quevedo (thatrat)
Hi All, I tried compiling the latest snapshot of smartmontools, and the problem is still occurring: Ubences-MacBook-Pro:smartmontools-6.7 uquevedo$ ./smartctl -t select,0-10 /dev/disk0 smartctl 6.7 2018-06-21 r4735 [Darwin 17.6.0 x86_64] (local build) Copyright (C) 2002-18, Bruce Allen, Christia

Re: smartctl - Can't run select span range

2018-06-24 Thread Ubence Quevedo
Thanks for pointing this out, but the selective scan range for smartctl has never worked in previous versions available through macports from the last few years, I’m just now finally posting something about this. I had worked around this by setting the sleep timeout on my Mac to a much longer time

Re: smartctl - Can't run select span range

2018-06-24 Thread Joshua Root
Ubence Quevedo wrote: > However, when I boot the same system off of Ubuntu 18.04 Live USB with the > same version of smartmontools [6.6], this command works properly: Just a note that Ubuntu does not actually have the same version as MacPorts. As your output shows: MacPorts: > smartctl 6.6 2017-1

smartctl - Can't run select span range

2018-06-24 Thread Ubence Quevedo
Hi Everyone, The macports package of smartmontools doesn't seem to support selective span testing ranges. When the command is executed, the command is sent, but the program fails with an "Unsopported SMART self-test mode": Ubences-MacBook-Pro:~ uquevedo$ smartctl -t select,0-10 /dev/disk0 smartct