🧠Scrutiny Installation Guide: Step-by-Step for HDD/SSD Monitoring
Target: Synology DSM Environment | Docker version (master-omnibus) | Monitored devices: HDD/SSD (e.g., /dev/sda to /dev/sdb)
🔰 What is Scrutiny? A Beginner's Explanation
Scrutiny is an open-source tool for checking the "health" of hard drives and SSDs. It collects S.M.A.R.T. (Self-Monitoring, Analysis and Reporting Technology) information and displays it in intuitive graph format on a web browser, allowing even beginners to easily understand disk status without specialized knowledge.
Key information you can check with Scrutiny includes:
- Power-on hours of the disk: cumulative time since startup.
- Temperature history: current temperature and past fluctuations.
- History of errors and warnings: early detection of abnormal signs to reduce the risk of data loss.
In this guide, we'll use the master-omnibus version, which includes a bundled database (InfluxDB). This eliminates the need to set up a separate database, making it easy for beginners to get started.
Advanced Tip: The master-omnibus is a self-contained Docker image, so no external database is required. S.M.A.R.T. data collection is cron-based, defaulting to 11 PM daily.
🤔 Installing Scrutiny in a Synology DSM Environment
Synology NAS runs on its own OS called "DSM," which is based on Linux. By installing the Docker package on DSM, you can easily run Scrutiny as a container. However, you'll need to adjust settings to fit Synology's specific directory structure (e.g., /volume1/docker).
🛠What You'll Need for Installation
To run Scrutiny with Docker, you'll need to prepare the following three elements:
- Prepare Storage Folder: Create a directory to store Scrutiny's configuration files and collected data (recommended path:
/volume1/docker/scrutiny). - Identify Monitored Disks: Find the Linux device names (e.g.,
/dev/sda) for the HDD/SSD you want to monitor. - Create docker-compose.yml File: Create the "blueprint" file that defines the Scrutiny container's startup settings.
📠Step ①: Create Storage Folder
Create a folder where Scrutiny's configuration files and InfluxDB data will be persistently stored. On Synology NAS, Docker-related data is typically placed under /volume1/docker.
mkdir -p /volume1/docker/scrutiny/influxdb
Executing this command will create the following directories:
/volume1/docker/scrutiny/: For Scrutiny's overall configuration files./volume1/docker/scrutiny/influxdb/: For time-series data like S.M.A.R.T. information.
Beginner's Tip: The -p option in the command automatically creates parent directories if they don't exist. Always use it to prevent errors.
🔠Step ②: Identify Disks to Monitor
To specify which HDD/SSD Scrutiny should monitor, you need to accurately know their Linux "device names" (e.g., /dev/sda). You can check this using the following commands.
Method A: Check device information with `lsblk` command
lsblk -o NAME,MODEL,SIZE,TYPE,MOUNTPOINT
Example Output:
NAME MODEL SIZE TYPE MOUNTPOINT
sda TOSHIBA HDWD130 4T disk
sdb WDC WD40EZRX 4T disk
In the example above, the disks to be monitored are /dev/sda and /dev/sdb.
Method B: Scan S.M.A.R.T. compatible disks with `smartctl` command
smartctl --scan
Example Output:
/dev/sda -d sat # ATA device
/dev/sdb -d sat # ATA device
Note: For NVMe SSDs, the device name might look like /dev/nvme0n1.
Advanced Tip: SATA connected disks are specified as sat and NVMe connected disks as nvme in collector.yaml. Ensure that device names match between the host OS and the container.
📠Step ③: Create `collector.yaml` File
This file configures which disks Scrutiny should monitor. The example below is for monitoring two SATA disks (/dev/sda, /dev/sdb).
cat <<EOF > /volume1/docker/scrutiny/collector.yaml
version: 1
host:
id: ""
devices:
- device: /dev/sda
type: 'sat'
- device: /dev/sdb
type: 'sat'
EOF
Configuration Points:
type: 'sat': Apply this for SATA connected HDDs/SSDs.type: 'nvme': Specify this for NVMe connected SSDs.- If you want to add more disks to monitor, add entries in the same format under the
devicessection.
âš™ï¸ Step â‘£: Create `docker-compose.yml` File
This is the "blueprint" file that defines the startup settings for the Scrutiny container. Below is a basic example configuration.
cat <<EOF > /volume1/docker/scrutiny/docker-compose.yml
version: '3.8'
services:
scrutiny:
container_name: scrutiny
image: ghcr.io/analogj/scrutiny:master-omnibus
cap_add:
- SYS_RAWIO
- SYS_ADMIN
ports:
- 6090:8080/tcp
- 8086:8086/tcp
volumes:
- /run/udev:/run/udev:ro
- /volume1/docker/scrutiny:/opt/scrutiny/config
- /volume1/docker/scrutiny/influxdb:/opt/scrutiny/influxdb
devices:
- /dev/sda:/dev/sda
- /dev/sdb:/dev/sdb
environment:
- COLLECTOR_CRON_SCHEDULE=0 23 * * *
- TZ=Asia/Bangkok
security_opt:
- no-new-privileges:true
restart: unless-stopped
EOF
Configuration Points:
/run/udev:/run/udev:ro: Required to obtain disk information in read-only mode.TZ=Asia/Bangkok: This is the timezone setting. Change it according to your location (e.g.,Asia/Tokyoif you are in Japan).devices: List all the same monitored disks specified incollector.yaml.COLLECTOR_CRON_SCHEDULE: Specifies the data collection timing in cron format. Defaults to 11 PM daily.
Beginner's Tip: If you forget to set the timezone, the times displayed in Scrutiny's graphs might be off, so be careful!
🚀 Step ⑤: Start Scrutiny
Execute the following commands to start the Scrutiny container in the background.
cd /volume1/docker/scrutiny
docker-compose up -d
🌠Step ⑥: Verify Operation
Open your web browser and go to the following URL:
http://[NAS_IP_Address]:6090
If Scrutiny's dashboard appears and you can see your monitored disk temperatures and S.M.A.R.T. information, the installation was successful!
How to check logs (for troubleshooting):
docker logs scrutiny
Advanced Tip: InfluxDB's admin interface is usually accessible at http://[NAS_IP]:8086, but with the master-omnibus version, all information can be accessed from the Scrutiny UI, so direct InfluxDB manipulation is rarely needed.
â“ Frequently Asked Questions and Configuration Tips
Why mount /run/udev:/run/udev:ro?
Linux's "udev" is a system that manages device information, such as disks. For Scrutiny to correctly recognize disks and read S.M.A.R.T. information, it needs to mount this /run/udev directory into the container in read-only mode (ro). This allows Scrutiny to reference device information without affecting the actual devices.
Why specify TZ=Asia/Bangkok?
Scrutiny timestamps the collected S.M.A.R.T. data. If you don't specify a timezone, the server's default timezone will be used, which can lead to time discrepancies in the web UI's graph display. It's crucial to specify the correct timezone for your region (e.g., Asia/Tokyo for Japan) to ensure accurate data logging and display.
âš ï¸ Common Issues and Solutions
| Symptom | Cause | Solution |
|---|---|---|
| Web interface does not start | Required folders do not exist | Run mkdir -p /volume1/docker/scrutiny/influxdb and verify that the folders are created correctly. |
| Disk data not displayed | Mistake in device specification in collector.yaml or docker-compose.yml |
Re-check that the disk names (e.g., /dev/sda) identified in Step â‘¡ are correctly specified in both collector.yaml and docker-compose.yml, and there are no typos. Re-running lsblk or smartctl --scan can also be helpful. |
| Temperature history or graph times are off by a day | Timezone (TZ) is not set or is incorrect |
Set the correct timezone for your region (e.g., TZ=Asia/Tokyo) in the environment section of docker-compose.yml. A container restart is required after changes (docker-compose down && docker-compose up -d). |
| InfluxDB authentication screen appears | Authentication is not required for master-omnibus version | The master-omnibus version operates without InfluxDB authentication. This display is normal, and you should be able to use the Scrutiny UI without logging in. |
🎯 Conclusion
Scrutiny is an incredibly useful tool that allows even beginners to easily monitor the health of their HDDs and SSDs. If you have a Synology DSM or Docker-enabled Linux environment, you can smoothly install it by following the steps in this guide. Once set up, Scrutiny will automatically check your disk health daily, acting as your "storage health partner."
Adjust the disk names and timezone to match your NAS environment, and secure the peace of mind for your valuable storage!
コメント