Enabling TRIM for LUKS encrypted USB disk

Published on Author admin

Change prisivioning model to unmap to enable TRIM for USB disk: echo unmap > /sys/block/sda/device/scsi_disk/*/provisioning_mode verify settings: # cat /sys/block/sda/device/scsi_disk/*/provisioning_mode unmap during LUKS volumen mounting add --allow-discards: cryptsetup luksOpen --allow-discards /dev/sda encrypted_disk verify, both device and encrypted volume should shows non-zero values: # lsblk --discard /dev/sda NAME             DISC-ALN DISC-GRAN… Continue reading Enabling TRIM for LUKS encrypted USB disk →

Tune PostgreSQL and PHP settings for Nextcloud inside Docker container on RPi 5

Published on Author admin

Tune PostgreSQL and PHP settings for Nextcloud inside Docker container on RPi 5 PostgreSQL settings change variables inside PG_DATA/postgresql.conf config file shared_buffers = 256MB work_mem = 8MB restart PostgreSQL database: docker restart nextcloud-postgres verify: docker exec -it nextcloud-postgres psql -U nextcloud -d nextcloud -c "SHOW shared_buffers" docker exec -it nextcloud-postgres psql -U nextcloud -d nextcloud… Continue reading Tune PostgreSQL and PHP settings for Nextcloud inside Docker container on RPi 5 →

[Raspberry Pi] NTP time synchronization

Published on Author admin

Configure proper timezone according to your physical location by using following wizard: sudo dpkg-reconfigure tzdata Enable NTP: timedatectl set-ntp true Check time and date settings: timedatectl status Install ntpdate tool: apt install ntpdate Fix problem with ToS (Type of Service) field value in IP packet. By default ToS is set to 0xc0 value by ntpd… Continue reading [Raspberry Pi] NTP time synchronization →