User Tools

Site Tools


domoticz:base-system

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
domoticz:base-system [2023/10/19 14:53] – created oscardomoticz:base-system [Unknown date] (current) – removed - external edit (Unknown date) 127.0.0.1
Line 1: Line 1:
-====== Base Setup ====== 
----- 
-===== OS installation ===== 
-Download PI OS image and follow the image installation steps.  
-===== Enable ssh ===== 
-In order to be able to remote ssh into the server edit the sshd configuration file. And set the following parameters: 
-<code> 
-# nano /etc/ssh/sshd_config 
---------------------------- 
  
-# Authentication: 
- 
-LoginGraceTime 2m 
-AllowUsers root pi 
-PermitRootLogin yes 
-StrictModes yes 
-#MaxAuthTries 6 
-#MaxSessions 10 
- 
---------------------------- 
-# systemctl restart ssh 
- 
-</code> 
- 
-===== SSD optimization ===== 
-See chapter [[linux:system:disk:ssd|SSD Optimization]] 
-===== Locale ===== 
-For setting up locales see section [[linux:debian:locales|Locale]]. On our Home server the configuration should be as follows: 
-<code> 
-# locale -a 
---------------- 
-C 
-C.UTF-8 
-dutch 
-en_US.utf8 
-nl_NL 
-nl_NL@euro 
-nl_NL.iso88591 
-nl_NL.iso885915@euro 
-nl_NL.utf8 
-POSIX 
- 
-# cat /etc/default/locale 
--------------------------- 
- 
-#  File generated by update-locale 
-LANG=en_US.UTF-8 
-LANGUAGE="en_US:en" 
-LC_TIME="nl_NL.UTF-8" 
-LC_NUMERIC="nl_NL.UTF-8" 
-LC_MONETARY="nl_NL.UTF-8" 
-LC_PAPER="nl_NL.UTF-8" 
-</code> 
-===== Missing Firmware ===== 
-Not all needed device drivers might be included in the standard installation packages. After booting the new system check the syslog and look for errors and warnings.  
-    # cat /var/log/syslog 
- 
-==== Error loading i915 Firmware ==== 
-<code> 
-[2.115280] i915 0000:00:02.0: firmware: failed to load i915/kbl_dmc_ver1_04.bin (-2) 
-[2.115284] firmware_class: See https://wiki.debian.org/Firmware for information about missing firmware 
-[2.115286] i915 0000:00:02.0: Direct firmware load for i915/kbl_dmc_ver1_04.bin failed with error -2 
-[2.115288] i915 0000:00:02.0: Failed to load DMC firmware i915/kbl_dmc_ver1_04.bin. Disabling runtime power management. 
-[2.115289] i915 0000:00:02.0: DMC firmware homepage: https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/i915 
-</code> 
- 
-kbl_dmc_ver1_04.bin is part of Package: firmware-misc-nonfree. In order to avoid downloading package with all the firmwares. You can download tar.gz from https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git. Extract the kbl_dmc_ver1_04.bin from the correct version of the installation.  
- 
-   # cp kbl_dmc_ver1_04.bin /lib/firmware/i915 
-   # reboot 
-<code> 
-After rebooting the result should look like: 
-[2.234768] i915 0000:00:02.0: vgaarb: changed VGA decodes: olddecodes=io+mem,decodes=io+mem:owns=io+mem 
-[2.237413] i915 0000:00:02.0: firmware: direct-loading firmware i915/kbl_dmc_ver1_04.bin 
-[2.237688] [drm] Finished loading DMC firmware i915/kbl_dmc_ver1_04.bin (v1.4) 
-</code> 
-==== Error loading tl8168h-2 Firmware ==== 
-<code> 
-[2.316705] r8169 0000:01:00.0: firmware: failed to load rtl_nic/rtl8168h-2.fw (-2) 
-[2.316710] r8169 0000:01:00.0: Direct firmware load for rtl_nic/rtl8168h-2.fw failed with error -2 
-[2.316711] r8169 0000:01:00.0 enp1s0: unable to load firmware patch rtl_nic/rtl8168h-2.fw (-2) 
-[2.316884] Generic PHY r8169-100:00: attached PHY driver [Generic PHY] (mii_bus:phy_addr=r8169-100:00, irq=IGNORE) 
-</code> 
-rtl8168h-2.fw is part of Package: firmware-misc-nonfree. In order to avoid downloading package with all the firmwares. You can download tar.gz from https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git. Extract the kbl_dmc_ver1_04.bin from the correct version of the installation.  
-   # cp rtl8168h-2.fw /lib/firmware/rtl_nic 
-   # reboot 
-After rebooting the result should look like: 
-<code> 
-[2.429213] r8169 0000:01:00.0: firmware: direct-loading firmware rtl_nic/rtl8168h-2.fw 
-[2.429385] Generic PHY r8169-100:00: attached PHY driver [Generic PHY] (mii_bus:phy_addr=r8169-100:00, irq=IGNORE) 
-</code> 
- 
-===== SMART ===== 
-Install smartmon tools and check the status: 
-  # apt-get install smartmontools 
-  # smartctl -a /dev/sda 
-===== Power Saving ===== 
-  * Disable the blinking cursor:[[linux:system:powersave:cursor-blink|Cursor blink off]] 
-  * Configure PowerTop: [[linux:system:powersave:powertop|Powertop]] 
-  * Tune ASPM: [[linux:system:powersave:aspm|ASPM on Linux]] 
- 
-For ASPM enabling the following lines are added to the powersave service. However no noticable difference are measured: 
-<code> 
-# Enable L1 and L0s on PCIe Intel Bridge and Realtek network adapter 
-# Does not seem to differ anything 
-setpci -s 00:1c.0 0x50.B=0x43 
-setpci -s 01:00.0 0x80.B=0x43 
-</code> 
- 
-===== Sensors ===== 
-<code> 
-# apt-get install lm-sensors 
-</code> 
-The following NEW packages will be installed:  libsensors4 lm-sensors 
-<code> 
-# sensors-detect 
- 
---------------------------------------------------------------- 
- Trying family `VIA/Winbond/Nuvoton/Fintek'... Yes 
- Found unknown chip with ID 0xd352 
-</code> 
- 
-The chip is an exclusive for MSI, and Nuvoton can not give me the datasheet because of an NDA with MSI. 
-The chip looks pretty similar to NCT6793D. 
-<code> 
-modprobe nct6775 force_id=0xd120 
-</code> 
-Now "sensors" will show more info. 
- 
-To load everything that is needed, add this to /etc/modules: 
-<code> 
-# nano /etc/modules 
- 
-#----cut here---- 
-# Chip drivers 
-coretemp 
-#----cut here---- 
-</code> 
-Now "sensors" will show more info: 
-<code>  
-# sensors 
-acpitz-virtual-0 
-Adapter: Virtual device 
-temp1:        +27.8°C  (crit = +119.0°C) 
-temp2:        +29.8°C  (crit = +119.0°C) 
- 
-coretemp-isa-0000 
-Adapter: ISA adapter 
-Physical id 0:  +40.0°C  (high = +80.0°C, crit = +100.0°C) 
-Core 0:         +40.0°C  (high = +80.0°C, crit = +100.0°C) 
-Core 1:         +37.0°C  (high = +80.0°C, crit = +100.0°C) 
-</code> 
- 
-===== Set the Welcome Text ===== 
-<code> 
-# nano /etc/motd 
-                        _____ 
-| | | |                    /  ___| 
-| |_| | ___  _ __ ___   ___\ `--.  ___ _ ____   _____ _ __ 
-|  _  |/ _ \| '_ ` _ \ / _ \`--. \/ _ \ '__\ \ / / _ \ '__| 
-| | | | (_) | | | | | |  __/\__/ /  __/ |   \ V /  __/ | 
-\_| |_/\___/|_| |_| |_|\___\____/ \___|_|    \_/ \___|_| 
-</code> 
- 
-===== Install frequently used packages ===== 
-  # apt-get install sudo 
-  # apt-get install iputils-ping 
-  # apt-get install nano 
-  # apt-get install less 
- 
- 
-===== Container prerequisites ===== 
-Be aware of the following prerequistes for some containers: 
- 
-  * [[https://wiki.oscardegroot.nl/doku.php?id=linux:homeserver:mailserver:rspamd#redis|Mailserver - Redis]] 
-  * [[linux:homeserver:fileserver#Host preparations|Prerequisited for Fileserver]] 
-  * [[linux:homeserver:webserver#Host preparations|Prerequisited for Webserver]] 
- 
-==== lxc-menu ==== 
-Create the lxc-menu in /usr/local/bin 
-  * [[linux:homeserver:lxc-menu|LXC-Menu]] 
domoticz/base-system.1697727204.txt.gz · Last modified: by oscar