Add support for USB drive adapters to hw-diags #109

Closed
opened 2019-04-25 19:03:58 -06:00 by 2Shirt · 2 comments
2Shirt commented 2019-04-25 19:03:58 -06:00 (Migrated from gitea.2shirt.work)

Rough idea:

DiskObj.smart_type = None
DiskObj.smart_types = ['sat', 'sat,12', 'usbcypress', 'usbjmicron', etc...]

DiskObj.get_smart_details(smart_type='auto'):

cmd = [
  'sudo',
  'smartctl',
  '--device={}',format(self.smart_type),
  '--all',
  '--json',
  self.path,
  ]

Somewhere? (Assuming self == DiskObj instance)

# Update SMART device type
if self.smart_type is None:
  for t in self.smart_types:
    self.get_smart_details(t)
    if self.nvme_attributes or self.smart_attributes:
      self.smart_type = t
      break
Rough idea: ``` DiskObj.smart_type = None DiskObj.smart_types = ['sat', 'sat,12', 'usbcypress', 'usbjmicron', etc...] ``` DiskObj.get_smart_details(smart_type='auto'): ``` cmd = [ 'sudo', 'smartctl', '--device={}',format(self.smart_type), '--all', '--json', self.path, ] ``` Somewhere? (Assuming self == DiskObj instance) ``` # Update SMART device type if self.smart_type is None: for t in self.smart_types: self.get_smart_details(t) if self.nvme_attributes or self.smart_attributes: self.smart_type = t break ```
2Shirt commented 2020-01-12 18:31:03 -07:00 (Migrated from gitea.2shirt.work)

There's also -d sat,auto

There's also `-d sat,auto`
2Shirt commented 2020-01-13 17:15:34 -07:00 (Migrated from gitea.2shirt.work)

Limiting this to -d sat,auto since I've only used the other modes a few times ever.

Limiting this to `-d sat,auto` since I've only used the other modes a few times ever.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: 2Shirt/WizardKit#109
No description provided.