doc:appunti:hardware:mini_pc_with_das
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
doc:appunti:hardware:mini_pc_with_das [2024/03/15 09:43] – niccolo | doc:appunti:hardware:mini_pc_with_das [2024/05/31 05:46] (current) – [Reboot problem] niccolo | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Mini PC T9Plus with D4-300 TerraMaster DAS ====== | ====== Mini PC T9Plus with D4-300 TerraMaster DAS ====== | ||
+ | |||
+ | In March 2024 I decided to assemble an **home server** to be run **24h, 7/7**, the system is intended to replace an old Dell PowerEdge T110, which served my house for the past 14 years without any issue. The main reason for the switch is power consumption and the fear of old hardware wear. | ||
+ | |||
+ | I discovered that a new generation of **Mini PCs** based on the **Intel Alder Lake N95** processor outperform the old **Intel Xeon @ 3.0 GHz**. The [[https:// | ||
+ | |||
+ | My home server is acting also as a domestic firewall (running Debian GNU/Linux), so I opted for a dual LAN Mini-PC. Obviously the only problem is the storage: the embedded SDD disk is not sufficient for my media library, so I opted for an esternal USB Direct Attached Storage. The choice was a **D4-300 TerraMaster DAS** which will host **two 4 Tb 3.5 inches drives** (leaving two empty slots). | ||
+ | |||
+ | ^ Mini PC T9Plus | ||
+ | ^ CPU | Intel(R) N95, 4 Cores | | ||
+ | ^ RAM | 16 Gb | | ||
+ | ^ HDD | NS512GSSD330 512 Gb Solid State Disk | | ||
+ | ^ Ethernet | ||
+ | ^ WiFi | Realtek RTL8852BE PCIe 802.11ax | ||
+ | ^ Video | Intel Alder Lake-N UHD Graphics | ||
+ | |||
+ | ^ D4-300 TerraMaster DAS ^^ | ||
+ | ^ Disk Slot Number | ||
+ | ^ Compatible Disk Types | 3.5" SATA HDD\\ 2.5" SATA HDD\\ 2.5" SATA SSD | | ||
+ | ^ USB | USB3.1 Type-C gen1 x 1 | | ||
===== Installing Debian GNU/Linux ===== | ===== Installing Debian GNU/Linux ===== | ||
Line 11: | Line 30: | ||
You can program the LEDs with several visual effects, brigthness and speed by sending some specific commands to the USB serial adapter exposed to the operating system. The manufacturer provides a Windows program to configure the LEDs, but several users on the internet reported that the program (named **LedControl.exe**) is detected as a malware by several antivirus software. I never run MS-Windows on this PC because I booted and installed Debian GNU/Linux since the very first boot, so I cannot give any insight on it. | You can program the LEDs with several visual effects, brigthness and speed by sending some specific commands to the USB serial adapter exposed to the operating system. The manufacturer provides a Windows program to configure the LEDs, but several users on the internet reported that the program (named **LedControl.exe**) is detected as a malware by several antivirus software. I never run MS-Windows on this PC because I booted and installed Debian GNU/Linux since the very first boot, so I cannot give any insight on it. | ||
- | Fortunately enough, someone [[https:// | + | Fortunately enough, someone [[https:// |
+ | In Debian GNU/Linux 12 it is possibile to run the script at bootstrap; just add a Systemd unit creating the file **/ | ||
+ | |||
+ | < | ||
+ | # / | ||
+ | [Service] | ||
+ | Type=oneshot | ||
+ | RemainAfterExit=yes | ||
+ | ExecStart=/ | ||
+ | [Install] | ||
+ | WantedBy=multi-user.target | ||
+ | </ | ||
+ | |||
+ | Run and enable the service issuing the command: | ||
+ | |||
+ | < | ||
+ | systemctl daemon-reload | ||
+ | systemctl enable t9plus-leds.service --now | ||
+ | </ | ||
+ | |||
+ | ===== Always on ===== | ||
+ | |||
+ | Press **Del** at bootstrap time to enter the BIOS settings, go to the **Boot** page and set **State After G3** => **S0 State**. | ||
+ | |||
+ | The ACPI power states are: | ||
+ | |||
+ | * S0: Normal Powered-On state (system working) | ||
+ | * S1: Standby | ||
+ | * S3: Suspend to Ram | ||
+ | * S4: Suspend to Disk | ||
+ | * S5: Shutdown state (soft off: some devices are still powered-on) | ||
+ | * G3: Mechanical off state | ||
+ | |||
+ | ===== Reboot problem ===== | ||
+ | |||
+ | Sometimes (randomly, about 50% of the time) the **reboot** command does not work. The shutdown process seems to proceed well and the PC seems to begin the reboot process, but the video signal does not switch-on and the host remains frozen. The power LED remains on. | ||
+ | |||
+ | The wake-on-lan (which is working in power-off condition) does not resolve this problem. | ||
===== The D4-300 USB attacched storage ===== | ===== The D4-300 USB attacched storage ===== | ||
Line 45: | Line 101: | ||
==== Power management ==== | ==== Power management ==== | ||
+ | |||
+ | ==== Monitoring SMART with Nagios/ | ||
+ | |||
+ | Unfortunately the **check_ide_smart** Nagios plugin provided by the Debian 12 package **monitoring-plugins-basic 2.3.3-5+deb12u2**, | ||
+ | |||
+ | We compiled the plugin binary from the sources (using the master branch [[https:// | ||
+ | |||
+ | <code bash> | ||
+ | check_scsi_smart -d /dev/sdb | ||
+ | OK: prdfail 0, advisory 0, critical 0, warning 0, logs 0 | 1_read_error_rate=0;;;; | ||
+ | </ | ||
+ | |||
+ | To integrate the SMART checks for all the devices into a single Nagios check and to have a more terse output, we created the following script **check_scsi_smart_all**: | ||
+ | |||
+ | <code bash> | ||
+ | #!/bin/sh | ||
+ | if [ " | ||
+ | echo " | ||
+ | exit 1 | ||
+ | fi | ||
+ | OUTPUT='' | ||
+ | STATE=0 | ||
+ | for DEV in $@; do | ||
+ | OUT=" | ||
+ | RET=$? | ||
+ | if [ $RET -gt $STATE ]; then | ||
+ | STATE=$RET | ||
+ | fi | ||
+ | if [ " | ||
+ | # Get only the short status, e.g. " | ||
+ | OUT=" | ||
+ | else | ||
+ | # Get the summary, e.g. "OK: prdfail 0, advisory 0, critical 0, warning 0, logs 1 " | ||
+ | OUT=" | ||
+ | fi | ||
+ | test -n " | ||
+ | OUTPUT=" | ||
+ | done | ||
+ | |||
+ | OUTPUT=" | ||
+ | case $STATE in | ||
+ | 0) | ||
+ | OUTPUT=" | ||
+ | ;; | ||
+ | 1) | ||
+ | OUTPUT=" | ||
+ | ;; | ||
+ | 2) | ||
+ | OUTPUT=" | ||
+ | ;; | ||
+ | *) | ||
+ | OUTPUT=" | ||
+ | ;; | ||
+ | esac | ||
+ | echo " | ||
+ | exit $STATE | ||
+ | </ | ||
+ | |||
+ | Finally we defined the NRPE Nagios check with a line into **/ | ||
+ | |||
+ | < | ||
+ | command[check_scsi_smart]=/ | ||
+ | </ | ||
+ | |||
===== Web References ===== | ===== Web References ===== | ||
Line 51: | Line 171: | ||
* **[[https:// | * **[[https:// | ||
* **[[https:// | * **[[https:// | ||
+ | * **[[t9plus_mini_pc_rgb_led_control]]** | ||
* **[[https:// | * **[[https:// | ||
* **[[https:// | * **[[https:// | ||
* **[[https:// | * **[[https:// | ||
doc/appunti/hardware/mini_pc_with_das.1710492191.txt.gz · Last modified: 2024/03/15 09:43 by niccolo