meta data for this page
  •  

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
raspberry [2016/04/25 07:56] niziakhome_automation:raspberry:card_wear [2018/09/10 14:36] (current) niziak
Line 2: Line 2:
 [[https://www.debian-administration.org/article/661/A_transient_/var/log|Transient log]] \\ [[https://www.debian-administration.org/article/661/A_transient_/var/log|Transient log]] \\
 [[https://wiki.gentoo.org/wiki/SDCard|Finding SD card erase size]] \\ [[https://wiki.gentoo.org/wiki/SDCard|Finding SD card erase size]] \\
 +
 +===== Check who is writing =====
 +Start logging disc access and kernel log:
 +<code bash>
 +sysctl vm.block_dump=1
 +dmesg -e -T -w 
 +</code>
 +
 +Stop logging:
 +<code bash>
 +sysctl vm.block_dump=0
 +</code>
 +
  
 ===== Set noop elevator ===== ===== Set noop elevator =====
Line 12: Line 25:
 ===== Use tmpfs ===== ===== Use tmpfs =====
 <file | /etc/fstab> <file | /etc/fstab>
-tmpfs           /tmp            tmpfs   defaults,nosuid,nodev,mode=1777,size=10%        0       0 +tmpfs   /tmp                     tmpfs   defaults,nosuid,nodev,mode=1777,size=10%        0       0 
-tmpfs           /var/tmp        tmpfs   defaults,nosuid,nodev,mode=1777,size=10%        0       0+tmpfs   /var/tmp                 tmpfs   defaults,nosuid,nodev,mode=1777,size=10%        0       0 
 +tmpfs   /var/cache/apt/archives  tmpfs   defaults,nosuid,nodev,mode=1777,size=80%        0       0
 </file> </file>
  
Line 30: Line 44:
  
  
-===== Remove disc logging =====+===== Disable logging to disc ===== 
 + 
 +<code bash> 
 +systemctl stop mosquitto 
 +systemctl disable mosquitto 
 +</code>
  
 <code>apt-get remove anacron</code> <code>apt-get remove anacron</code>
Line 41: Line 60:
 apt-get install busybox-syslogd apt-get install busybox-syslogd
 </code> </code>
 +
 +<file /etc/default/busybox-syslogd>
 +SYSLOG_OPTS="-C256 -L -R remote.host.org"
 +KLOG_OPTS=""
 +</file>
  
 Use journald and configure it to use RAM: Use journald and configure it to use RAM: