OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • Archive »
  • 19.1 Legacy Series »
  • Smart plugin (Solved)
« previous next »
  • Print
Pages: [1]

Author Topic: Smart plugin (Solved)  (Read 7786 times)

GDixon

  • Jr. Member
  • **
  • Posts: 98
  • Karma: 4
    • View Profile
Smart plugin (Solved)
« on: November 22, 2018, 11:22:28 pm »
Hi,

In the smart plugin on the dashboard I show this.

I'm using a old Acer Aspire (AX1200-B1792A) desktop that had vista on it and it has external card readers and such.
For home use this little box handles everything great for what I use. I do plan on a purpose built box after I learn my way around OPNsense in the future.

Since I never use the external card readers how can I tell smart there is no da0 or da1 so they don't show on the dashboard? Is this possible?

It isn't a big deal I'm just trying to clean up whats shown is all.

Second question: Does smart run on it's own or do tests need to be scheduled through cron?

 SMART Status
Drive    Ident    SMART Status
ada0    WD-WX11A11W9451     OK
da0        Unknown
da1        Unknown
« Last Edit: November 30, 2018, 07:59:27 am by GDixon »
Logged

franco

  • Administrator
  • Hero Member
  • *****
  • Posts: 17707
  • Karma: 1618
    • View Profile
Re: Smart plugin
« Reply #1 on: November 26, 2018, 09:10:37 am »
I suspect the data is coming from smartmontools directly so it's hard to filter. The plugin is there, but not really supported anymore. I think Fabian uses it and pushed a few cleanups this year. Best to ask on GitHub.

https://github.com/opnsense/plugins


Cheers,
Franco
Logged

fabian

  • Hero Member
  • *****
  • Posts: 2769
  • Karma: 200
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: Smart plugin
« Reply #2 on: November 26, 2018, 06:03:05 pm »
@franco

In theory you would only need to filter this array:

https://github.com/opnsense/plugins/blob/master/sysutils/smart/src/www/widgets/widgets/smart_status.widget.php#L45

However I only did some code cleanup in it to fix some UI bugs (like missing CSS classes etc. and I don't like the source btw.).
Logged

GDixon

  • Jr. Member
  • **
  • Posts: 98
  • Karma: 4
    • View Profile
Re: Smart plugin
« Reply #3 on: November 26, 2018, 06:29:29 pm »
so if i modify these lines

Code: [Select]
## Get all adX, daX, and adaX (IDE, SCSI, and AHCI) devices currently installed
exec("ls /dev | grep '^\(ad\|da\|ada\)[0-9]\{1,2\}$'", $devs); ## From SMART status page

to this

Code: [Select]
## Get all adX, adaX (IDE, SCSI, and AHCI) devices currently installed
exec("ls /dev | grep '^\(ad\|ada\)[0-9]\{1,2\}$'", $devs); ## From SMART status page

I should in theory lose the da0 and da1 in the widget?

 Will they be over written on a reinstall or upgrade?
« Last Edit: November 26, 2018, 06:36:17 pm by GDixon »
Logged

fabian

  • Hero Member
  • *****
  • Posts: 2769
  • Karma: 200
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: Smart plugin
« Reply #4 on: November 26, 2018, 07:54:24 pm »
Quote from: GDixon on November 26, 2018, 06:29:29 pm
I should in theory lose the da0 and da1 in the widget?
probably yes

Quote from: GDixon on November 26, 2018, 06:29:29 pm
Will they be over written on a reinstall or upgrade?
definitely yes however I would not expect an update of the smart widget soon.
Logged

  • Print
Pages: [1]
« previous next »
  • OPNsense Forum »
  • Archive »
  • 19.1 Legacy Series »
  • Smart plugin (Solved)
 

OPNsense is an OSS project © Deciso B.V. 2015 - 2024 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2