suchende Posted January 12, 2020 Posted January 12, 2020 hey, I'm having some trouble with my ssh connection to an armbian based server. It feels like a heavy lag within the filesystem, sometimes it takes up to 20 seconds to open a file with vim or use cd with tab-completion. But it is not always there, it feels more like some heavy write operation occurs spontaneously. I start digging but I have no clue why this happens. But at least I found the most disk I/O processes which are influxdb and mysql. [16:54|root@odroidhc1 ~]# cat /syscat /sys/fs/ext4/mmcblk0p1/session_write_kbytes 118811040 [16:55|root@odroidhc1 ~]# uptime 16:56:03 up 10 days, 3:53, 3 users, load average: 0,87, 0,64, 0,59 [17:15|root@odroidhc1 zram-config]# iostat Linux 4.14.150-odroidxu4 (odroidhc1) 12.01.2020 _armv7l_ (8 CPU) avg-cpu: %user %nice %system %iowait %steal %idle 2,03 0,44 0,93 0,85 0,00 95,75 Device tps kB_read/s kB_wrtn/s kB_read kB_wrtn loop0 24,86 12,44 0,00 10932869 668 mmcblk0 8,55 90,30 135,32 79391237 118968040 zram0 0,88 1,54 1,97 1349836 1735284 zram1 2,35 3,83 5,58 3369880 4903220 sda 1,10 110,95 47,61 97549568 41860980 dm-0 24,86 12,43 0,00 10931824 668 [16:36|root@odroidhc1 ~]# cat /etc/fstab # <device> <dir> <type> <options> <dump> <fsck> UUID=8a464498-f41a-4de4-9a05-52e636c8135e / ext4 defaults,noatime,nodiratime,commit=600,errors=remount-ro 0 1 UUID=92d36a67-0322-42cf-9a4c-81a0563f58c9 /mnt btrfs defaults,nofail 0 1 tmpfs /tmp tmpfs defaults,nosuid 0 0 tmpfs /var/www/tmp tmpfs defaults,nofail,noatime,nosuid,uid=33,gid=33,mode=0755,size=100m 0 0 tmpfs /var/log/audit tmpfs defaults,nofail,noatime,nosuid,mode=0755,size=100m 0 0 [16:37|root@odroidhc1 ~]# swapon NAME TYPE SIZE USED PRIO /dev/zram1 partition 998,5M 246M 5 However, the value (session_write_kbytes) is constantly rising and not within the commit time delay from fstab file. The mariadb is set to fsync and not o_direct, it should respect the commit entry? However (118811040 KBytes == 116026 MBytes == 113 GBytes) within 10 days? It seems a lot for a single user nextcloud instance? The influxdb takes like 6 values every minute from 5 inputs. Did someone optimize the mariadb setup for a sdcard?
Magnets Posted January 14, 2020 Posted January 14, 2020 I had a problem with ext4 and data being committed every 30 seconds and changing commit interval in fstab made no difference to fix it I modified: /proc/sys/vm/dirty_expire_centisecs to 500 (5 seconds). 30 seconds is default You can monitor it with: cat /proc/meminfo | grep "Dirty" -A1
suchende Posted January 14, 2020 Author Posted January 14, 2020 thank you, I give it a try. Currently I switched to the HDD, the amount of written data is enormous, like about 200GB for mysql and 150GB in two hours! Luckily the responsiveness raised a lot.
Recommended Posts