{"id":30510,"date":"2024-09-07T07:00:00","date_gmt":"2024-09-07T05:00:00","guid":{"rendered":"https:\/\/raspberrytips.com\/?p=30510"},"modified":"2026-07-15T00:51:26","modified_gmt":"2026-07-14T22:51:26","slug":"install-log2ram-raspberry-pi","status":"publish","type":"post","link":"https:\/\/raspberrytips.com\/install-log2ram-raspberry-pi\/","title":{"rendered":"Save Your SD Card: Install Log2Ram on Raspberry Pi"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Linux distributions make it easy to keep system logs, and a paper trail helps me understand where things went wrong and how to fix them. As great as logging is, it can lead to an unexpected problem on a Raspberry Pi: constant disk writes degrade SD cards and cause them to fail. In this guide, I&#8217;ll show you how to fix this problem once and for all.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Log2Ram can be run on a Raspberry Pi to extend the lifespan of an SD card. Log2Ram works by reducing the number of disk writes used by system logging.<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Read on to learn why you need Log2Ram and how to install it on your Pi. Let&#8217;s go!<\/p>\n\n\n<style>.kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-table-of-content-wrap{padding-top:var(--global-kb-spacing-sm, 1.5rem);padding-right:var(--global-kb-spacing-sm, 1.5rem);padding-bottom:var(--global-kb-spacing-sm, 1.5rem);padding-left:var(--global-kb-spacing-sm, 1.5rem);background-color:var(--global-palette7, #EDF2F7);box-shadow:0px 0px 14px 0px rgba(0, 0, 0, 0.2);}.kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-table-of-contents-title-wrap{padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px;}.kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-table-of-contents-title{font-weight:regular;font-style:normal;}.kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-table-of-content-wrap .kb-table-of-content-list{font-size:var(--global-kb-font-size-sm, 0.9rem);font-weight:regular;font-style:normal;margin-top:var(--global-kb-spacing-sm, 1.5rem);margin-right:0px;margin-bottom:0px;margin-left:0px;}.kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-toggle-icon-style-basiccircle .kb-table-of-contents-icon-trigger:after, .kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-toggle-icon-style-basiccircle .kb-table-of-contents-icon-trigger:before, .kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-toggle-icon-style-arrowcircle .kb-table-of-contents-icon-trigger:after, .kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-toggle-icon-style-arrowcircle .kb-table-of-contents-icon-trigger:before, .kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-toggle-icon-style-xclosecircle .kb-table-of-contents-icon-trigger:after, .kb-table-of-content-nav.kb-table-of-content-id19563_c031ec-35 .kb-toggle-icon-style-xclosecircle .kb-table-of-contents-icon-trigger:before{background-color:var(--global-palette7, #EDF2F7);}<\/style>\n\n<p class='ml_begpost' id='ml_begpost_commands'>If you&#8217;re new to Raspberry Pi or Linux, I\u2019ve got something that can help you right away! <br \/><a rel='noopener' href='https:\/\/raspberrytips.com\/downloads\/?source=begpost&#038;lm=4' target='_blank'>Download my free Linux commands cheat sheet<\/a> \u2013 it\u2019s a quick reference guide with all the essential commands you\u2019ll need to get things done on your Raspberry Pi. <a rel='noopener' href='https:\/\/raspberrytips.com\/downloads\/?source=begpost&#038;lm=4' target='_blank'><b>Click here to get it for free!<\/b><\/a><\/p>\n\n\n<h2 class=\"wp-block-heading\">Introduction to Log2Ram: Why You Might Need It<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/raspberrytips.com\/what-is-raspberry-pi-os\/\">Raspberry Pi OS<\/a> will keep logs as a normal part of operation. When a new event needs to be recorded, a disk write will occur. This constant process leads to wear and tear on your SD card. That&#8217;s where Log2Ram comes in.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Log2Ram is a program that stores log updates in memory, and then once a day, writes these changes to the disk all at once.<\/strong> <\/p>\n\n\n\n<h3 class=\"wp-block-heading\">What Is the Benefit of Using Log2Ram?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">You may already know that storage devices have limited read\/write cycles. Once you exceed this limit, the drive can wear down until it stops functioning entirely. The write limit was rarely a concern for home users when we used hard disks.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">However, write limits matter for modern solid-state devices, e.g., <a href=\"https:\/\/raspberrytips.com\/external-hard-drive-raspberry-pi\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/external-hard-drive-raspberry-pi\/\">SSDs<\/a> and <a href=\"https:\/\/raspberrytips.com\/do-i-need-an-sd-card-for-raspberry-pi\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/best-sd-card-raspberry-pi\/\">SD cards<\/a>. This limit can vary dramatically for SD cards\u2014as low as 3,000 or as high as 100,000, depending on the quality and storage size. And manufacturers don&#8217;t always make this specification clear.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"683\" src=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2021\/05\/do-i-need-sd-card-1024x683.jpg\" alt=\"hand holding sd card up with question mark\" class=\"wp-image-7712\" style=\"width:auto;height:250px\" srcset=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2021\/05\/do-i-need-sd-card-1024x683.jpg 1024w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2021\/05\/do-i-need-sd-card-300x200.jpg 300w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2021\/05\/do-i-need-sd-card-768x512.jpg 768w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2021\/05\/do-i-need-sd-card.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">I&#8217;ve read user complaints about their Raspberry Pi chewing through SD cards or <a href=\"https:\/\/raspberrytips.com\/mistakes-raspberry-pi-beginners-make\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/mistakes-raspberry-pi-beginners-make\/\">corrupting them with heavy writing<\/a>. <strong>Therefore, the benefit of using Log2Ram is that it extends the life of your SD card.<\/strong><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Who Is Log2Ram Best For?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">If you have a newer Raspberry Pi model (like the <a href=\"https:\/\/raspberrytips.com\/amz\/pi5\">Pi 5<\/a> or <a href=\"https:\/\/raspberrytips.com\/amz\/pi4\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/amz\/pi4\">Pi 4<\/a>), use only  basic programs, and have an <a href=\"https:\/\/raspberrytips.com\/best-sd-card-raspberry-pi\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/best-sd-card-raspberry-pi\/\">excellent SD card<\/a> (or the <a href=\"https:\/\/raspberrytips.com\/raspberry-pi-official-sd-card\/\">new official one<\/a>), you&#8217;ll probably never encounter this problem.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">However, <strong>I recommend running Log2Ram if<\/strong>: <\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>You&#8217;re using a not-so-great SD card brand, which often has a lower write endurance.<\/li>\n\n\n\n<li>You have an older SD card, as older designs had lower write limits.<\/li>\n\n\n\n<li>Your SD card storage is 32GB or less, especially if you keep your drive close to full capacity.<\/li>\n\n\n\n<li>You host <a href=\"https:\/\/raspberrytips.com\/web-server-setup-on-raspberry-pi\/\" data-type=\"post\" data-id=\"1017\">LAMP<\/a>, <a href=\"https:\/\/raspberrytips.com\/mail-server-raspberry-pi\/\" data-type=\"post\" data-id=\"660\">email<\/a>, <a href=\"https:\/\/raspberrytips.com\/cryptomining-with-raspberry-pi\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/cryptomining-with-raspberry-pi\/\">cryptomining<\/a>, <a href=\"https:\/\/raspberrytips.com\/minecraft-server-raspberry-pi\/\" data-type=\"post\" data-id=\"620\">Minecraft<\/a>, or other servers on your Pi, as these programs log heavily.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">But if you&#8217;re unsure, why not protect your SD card if you can? After all, Log2Ram is easy to install and maintain. I&#8217;ve been running it for years without issue on a Raspberry Pi 4 with only 2 GB of memory.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">How Does Log2Ram Work? <\/h3>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Log2Ram will create a <a href=\"https:\/\/raspberrytips.com\/mount-linux-command\/\" data-type=\"post\" data-id=\"22167\">mount<\/a> point at <em><a href=\"https:\/\/raspberrytips.com\/raspberry-pi-file-system\/\">\/var\/log<\/a><\/em> that exists on your RAM. Every time a log file is updated, instead of writing to disk, the changes will be stored in memory. Once a day, Log2Ram will transfer these changes from memory to the SD card. <\/strong><\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"718\" height=\"229\" src=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_df_ramdisk.jpg\" alt=\"df command showing log2ram ramdisk mounted\" class=\"wp-image-30605\" srcset=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_df_ramdisk.jpg 718w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_df_ramdisk-300x96.jpg 300w\" sizes=\"auto, (max-width: 718px) 100vw, 718px\" \/><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">There&#8217;s one downside you should know about. Because log changes are stored in memory, if your Pi loses power, then any log updates since the last write will be lost. <\/p>\n\n\n\n<p class=\"has-background wp-block-paragraph\" style=\"background-color:#fadce4\"><strong>Note<\/strong>: If you want to learn how to use graphical tools to make backups easy, I have a video on this topic just for community members. <a href=\"https:\/\/raspberrytips.com\/school\/community\/?coupon=IP25CTY&amp;utm_source=raspberrytips&amp;utm_medium=website&amp;utm_campaign=inpost\">Join here to watch<\/a>, and get access to 30+ other lessons for Raspberry Pi along with many other benefits!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">To give you peace of mind, Log2Ram stores a daily backup of log files in the folder <em>\/var\/hdd.log<\/em> and also saves a backup when the Raspberry Pi is <a href=\"https:\/\/raspberrytips.com\/properly-shut-down-raspberry-pi\/\">shut down properly<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I haven&#8217;t had to worry about this issue because my Pi is rock-solid, which is also why so many <a href=\"https:\/\/raspberrytips.com\/raspberry-pi-surprising-uses\">ground-breaking projects have used the Pi in surprising ways<\/a>. If you love to <a href=\"https:\/\/raspberrytips.com\/make-your-raspberry-pi-run-faster\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/make-your-raspberry-pi-run-faster\/\">tweak your Pi to its maximum potential<\/a>, I highly recommend Log2Ram.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Log2Ram Installation Process<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Now that you know how it works, let&#8217;s install Log2Ram. Open a terminal and put your typing gloves on\u2014or copy\/paste the commands below, I won&#8217;t judge.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Prerequisites for Log2Ram<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">First, make sure you have the most recent system packages:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Update your system<\/strong>: <br><code>sudo apt update<br>sudo apt upgrade<\/code><\/li>\n\n\n\n<li><strong>Install <a href=\"https:\/\/raspberrytips.com\/rsync-linux-command\/\" data-type=\"post\" data-id=\"23119\">rsync<\/a><\/strong>, which you probably already have: <br><code>sudo apt install rsync<\/code><\/li>\n<\/ul>\n\n\n\r\n\t\t<!-- wp:paragraph -->\r\n\t<p  id=\"inpost_lm_linux_commands\"><b>Tip: <\/b> Command lines can be a pain to memorize. I put the essential Linux commands on a printable cheat sheet so you don't have to keep googling them.\u00a0You can <a rel=\"noreferrer noopener\" href=\"https:\/\/raspberrytips.com\/downloads\/?source=rb_linux&lm=4\" target=\"_blank\">grab the PDF here<\/a> if you want to save some time.<\/p>\r\n\t<!-- \/wp:paragraph -->\r\n\t\t\n\n\n<h3 class=\"wp-block-heading\">Download Log2Ram<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Next, download and extract the Log2Ram package from its official GitHub repository: <\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Download<\/strong> using <a href=\"https:\/\/raspberrytips.com\/download-files-linux-terminal\/\" data-type=\"post\" data-id=\"27068\">wget<\/a>: <br><code>wget https:\/\/github.com\/azlux\/log2ram\/archive\/master.tar.gz -O log2ram.tar.gz<\/code><\/li>\n\n\n\n<li><strong>Extract<\/strong> the archive using <a href=\"https:\/\/raspberrytips.com\/tar-linux-command\/\" data-type=\"post\" data-id=\"23347\">tar<\/a>: <br><code>tar xzf log2ram.tar.gz<\/code><\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1008\" height=\"542\" src=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_download_extract.jpg\" alt=\"terminal showing download and extraction of log2ram\" class=\"wp-image-30602\" style=\"width:auto;height:300px\" srcset=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_download_extract.jpg 1008w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_download_extract-300x161.jpg 300w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_download_extract-768x413.jpg 768w\" sizes=\"auto, (max-width: 1008px) 100vw, 1008px\" \/><\/figure>\n<\/div>\n\n\n<h3 class=\"wp-block-heading\">Install Log2Ram<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Finally, install Log2Ram with the script provided:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Run the installation script<\/strong>, which will copy files and <a href=\"https:\/\/raspberrytips.com\/autostart-a-program-on-boot\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/autostart-a-program-on-boot\/\">enable autostart<\/a>: <br><code>cd log2ram-master<br>sudo .\/install.sh<\/code><\/li>\n\n\n\n<li><strong>Reboot<\/strong> to activate:<br><code>sudo reboot<\/code><\/li>\n\n\n\n<li><strong>Check<\/strong> if Log2Ram is running properly: <br><code>systemctl status log2ram<\/code><br><br><img loading=\"lazy\" decoding=\"async\" width=\"750\" height=\"84\" class=\"wp-image-30608\" style=\"width: 750px;\" src=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_status_active.jpg\" alt=\"terminal showing status of log2ram active\" srcset=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_status_active.jpg 870w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_status_active-300x33.jpg 300w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_status_active-768x86.jpg 768w\" sizes=\"auto, (max-width: 750px) 100vw, 750px\" \/>If you see &#8220;active,&#8221; it&#8217;s working. <\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">That&#8217;s it\u2014you&#8217;re done! For most people, Log2Ram will work right out of the box. It&#8217;s a set-it-and-forget-it way of saving your SD card.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you&#8217;re curious about Log2Ram&#8217;s other features\u2014especially if you&#8217;re running <a href=\"https:\/\/raspberrytips.com\/raspberry-pi-network-projects\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/raspberry-pi-network-projects\/\">multiple servers<\/a> on your Pi\u2014then keep reading to learn how to modify its configuration.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Log2Ram Configuration<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Now that you&#8217;ve installed Log2Ram, let&#8217;s view its basic settings. <strong>Log2Ram&#8217;s configuration can be found in the \/etc\/log2ram.conf file.<\/strong> Open it using a text editor like <a href=\"https:\/\/raspberrytips.com\/nano-commands-shortcuts\/\" data-type=\"post\" data-id=\"2524\">Nano<\/a> and take a look around.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Increasing Cache Size<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">In the config file, the &#8220;SIZE&#8221; parameter is the most important. The cache size tells Log2Ram how much physical memory to reserve for logs.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In the past, most issues with Log2Ram were caused by the default being too low. Thankfully, the newest version has increased the default cache size to 128 MB. If you&#8217;re only running a basic setup with <a href=\"https:\/\/raspberrytips.com\/ssh-guide-raspberry-pi\/\" data-type=\"link\" data-id=\"https:\/\/raspberrytips.com\/ssh-guide-raspberry-pi\/\">SSH<\/a>, this limit should be good enough.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">However, if like me you&#8217;re running multiple servers that log extensively, such as <a href=\"https:\/\/raspberrytips.com\/install-pi-hole-ad-blocker\/\" data-type=\"post\" data-id=\"1949\">Pi-Hole<\/a> or <a href=\"https:\/\/raspberrytips.com\/unifi-controller-raspberry-pi\/\" data-type=\"post\" data-id=\"17394\">UniFi Network Server<\/a>, you&#8217;ll encounter issues if the cache runs out. For example, Log2Ram might give you an &#8220;out of memory&#8221; error, or the service won&#8217;t launch on startup for some reason.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>The easiest solution to these problems is to increase your cache size.<\/strong> Here&#8217;s how: <\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Open Log2Ram&#8217;s config file<\/strong>: <br><code>sudo nano \/etc\/log2ram.conf<\/code><\/li>\n\n\n\n<li>Change <strong>SIZE<\/strong> to 256M (or whatever amount you think you need): <br><img loading=\"lazy\" decoding=\"async\" width=\"750\" height=\"97\" class=\"wp-image-30615\" style=\"width: 750px;\" src=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_cachesize.jpg\" alt=\"log2ram config showing increased cache size setting\" srcset=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_cachesize.jpg 1193w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_cachesize-300x39.jpg 300w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_cachesize-1024x132.jpg 1024w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_cachesize-768x99.jpg 768w\" sizes=\"auto, (max-width: 750px) 100vw, 750px\" \/><\/li>\n\n\n\n<li>Change <strong>LOG_DISK_SIZE<\/strong> to double your SIZE setting:<br><img loading=\"lazy\" decoding=\"async\" width=\"600\" height=\"58\" class=\"wp-image-30616\" style=\"width: 600px;\" src=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_logdisksize.jpg\" alt=\"log2ram config showing log_disk_size setting\" srcset=\"https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_logdisksize.jpg 827w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_logdisksize-300x29.jpg 300w, https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/log2ram_config_logdisksize-768x74.jpg 768w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/li>\n\n\n\n<li><strong>Reboot<\/strong> for changes to take effect: <br><code>sudo reboot<\/code><\/li>\n\n\n\n<li><strong>Check<\/strong> if everything is still working: <br><code>df -hT<br>systemctl status log2ram<\/code><\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">Other Configuration Options<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Log2Ram has other features you can change, such as enabling notifications, adding custom log directories, and changing the time interval between disk writes. Most users won&#8217;t need to tinker with these settings, so I won&#8217;t cover them here. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">But if you&#8217;re wondering how they work, you can <a href=\"https:\/\/github.com\/azlux\/log2ram?tab=readme-ov-file#customization\">read more about these features on the official GitHub<\/a>. This page also has a useful <a href=\"https:\/\/github.com\/azlux\/log2ram?tab=readme-ov-file#troubleshooting\">troubleshooting section<\/a> if you run into issues other than the ones mentioned above.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Related<\/strong>: <a href=\"https:\/\/raspberrytips.com\/raspberry-pi-server-tweaks\/\">15 Tweaks to Get the Most Out of Your Raspberry Pi Server<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">That was pretty easy, right? Log2Ram is a neat little program for protecting your SD card, and I hope it serves you well as it has for me.<\/p>\n\n\n<section id=\"end-block-pi\">\r\n<div class=\"rt-community-card \">\r\n\t<div class=\"rt-community-card__inner\">\r\n\r\n\t\t<div class=\"rt-community-card__main\">\r\n\t\t\t<h3 class=\"rt-community-card__headline\">\r\n\t\t\t\tNot getting the same result?\t\t\t<\/h3>\r\n\r\n\t\t\t<p class=\"rt-community-card__description\">\r\n\t\t\t\tEven when you follow every step, small differences in OS version, hardware or config can change the outcome. Instead of wasting time guessing, get help from people who have already fixed the same kind of issue.\t\t\t<\/p>\r\n\r\n\t\t\t<div class=\"rt-community-card__actions\">\r\n\t\t\t\t<a class=\"rt-community-card__button\" href=\"https:\/\/raspberrytips.com\/school\/community\/?coupon=EBCTY\">\r\n\t\t\t\t\t<span>Ask your question now<\/span>\r\n\t\t\t\t\t<span class=\"rt-community-card__button-arrow\">\u2192<\/span>\r\n\t\t\t\t<\/a>\r\n\r\n\t\t\t\t\t\t\t\t\t<div class=\"rt-community-card__small\">\r\n\t\t\t\t\t\t<span class=\"rt-community-card__small-lock\">\ud83d\udd12<\/span>\r\n\t\t\t\t\t\tNo risk. Cancel anytime.\t\t\t\t\t<\/div>\r\n\t\t\t\t\t\t\t<\/div>\r\n\t\t<\/div>\r\n\r\n\t\t\t\t\t<div class=\"rt-community-card__side\">\r\n\t\t\t\t<ul class=\"rt-community-card__benefits\">\r\n\t\t\t\t\t\t\t\t\t\t\t<li>Get help on your exact issue<\/li>\r\n\t\t\t\t\t\t\t\t\t\t\t<li>Access step-by-step videos for tricky setups<\/li>\r\n\t\t\t\t\t\t\t\t\t\t\t<li>Browse the website without ads<\/li>\r\n\t\t\t\t\t\t\t\t\t<\/ul>\r\n\t\t\t<\/div>\r\n\t\t\r\n\t<\/div>\r\n<\/div>\r\n<\/section>\r\n\r\n<style>\r\n.rt-community-card {\r\n\t--rt-bg: #f7f7f9;\r\n\t--rt-border: #e4e4e8;\r\n\t--rt-text: #15171b;\r\n\t--rt-muted: #5b6270;\r\n\t--rt-accent: #C61E4A;\r\n\t--rt-accent-hover: #aa183f;\r\n\t--rt-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);\r\n\r\n\tmargin: 36px 0;\r\n\tcolor: var(--rt-text);\r\n\tfont-family: inherit;\r\n}\r\n\r\n.rt-community-card__inner {\r\n\tdisplay: grid;\r\n\tgrid-template-columns: minmax(0, 1.55fr) minmax(260px, 0.95fr);\r\n\tgap: 34px;\r\n\talign-items: start;\r\n\tbackground: var(--rt-bg);\r\n\tborder: 1px solid var(--rt-border);\r\n\tborder-radius: 22px;\r\n\tpadding: 34px 36px;\r\n\tbox-shadow: var(--rt-shadow);\r\n}\r\n\r\n.rt-community-card__main {\r\n\tmin-width: 0;\r\n}\r\n\r\n.rt-community-card__side {\r\n\tborder-left: 1px solid #e1e1e6;\r\n\tpadding-left: 28px;\r\n}\r\n\r\n.rt-community-card__benefits {\r\n\tmargin: 6px 0 0;\r\n\tpadding: 0;\r\n\tlist-style: none;\r\n\tdisplay: grid;\r\n\tgap: 18px;\r\n}\r\n\r\n.rt-community-card__benefits li {\r\n\tposition: relative;\r\n\tpadding-left: 18px;\r\n\tfont-size: 18px;\r\n\tline-height: 1.55;\r\n\tcolor: var(--rt-text);\r\n}\r\n\r\n.rt-community-card__benefits li::before {\r\n\tcontent: \"\";\r\n\tposition: absolute;\r\n\tleft: 0;\r\n\ttop: 0.72em;\r\n\twidth: 7px;\r\n\theight: 7px;\r\n\tborder-radius: 999px;\r\n\tbackground: var(--rt-accent);\r\n\ttransform: translateY(-50%);\r\n}\r\n\r\n.rt-community-card__actions {\r\n\tdisplay: flex;\r\n\tflex-direction: column;\r\n\talign-items: flex-start;\r\n\tgap: 10px;\r\n\tmargin-top: 30px;\r\n}\r\n\r\n.rt-community-card__button {\r\n\tdisplay: inline-flex;\r\n\talign-items: center;\r\n\tjustify-content: center;\r\n\tgap: 10px;\r\n\tmin-height: 60px;\r\n\tpadding: 0 28px;\r\n\tborder-radius: 14px;\r\n\tbackground: var(--rt-accent);\r\n\tcolor: #fff !important;\r\n\ttext-decoration: none !important;\r\n\tfont-size: 21px;\r\n\tfont-weight: 700;\r\n\tline-height: 1;\r\n\tbox-shadow: 0 12px 22px rgba(198, 30, 74, 0.22);\r\n\ttransition: background .2s ease, transform .2s ease, box-shadow .2s ease;\r\n}\r\n\r\n.rt-community-card__button:hover {\r\n\tbackground: var(--rt-accent-hover);\r\n\tcolor: #fff !important;\r\n\ttransform: translateY(-1px);\r\n\tbox-shadow: 0 14px 26px rgba(198, 30, 74, 0.28);\r\n}\r\n\r\n.rt-community-card__button-arrow {\r\n\tfont-size: 20px;\r\n\tline-height: 1;\r\n}\r\n\r\n.rt-community-card__small {\r\n\tfont-size: 15px;\r\n\tline-height: 1.5;\r\n\tcolor: #6a717d;\r\n\tpadding-left: 2px;\r\n}\r\n\r\n.rt-community-card__small-lock {\r\n\tmargin-right: 6px;\r\n\tfont-size: 14px;\r\n\tvertical-align: baseline;\r\n}\r\n\r\n\/* Tablet *\/\r\n@media (max-width: 900px) {\r\n\t.rt-community-card {\r\n\t\tmargin: 28px 0;\r\n\t}\r\n\r\n\t.rt-community-card__inner {\r\n\t\tgrid-template-columns: 1fr;\r\n\t\tgap: 24px;\r\n\t\tpadding: 28px 24px;\r\n\t}\r\n\r\n\t.rt-community-card__side {\r\n\t\tborder-left: 0;\r\n\t\tborder-top: 1px solid #e1e1e6;\r\n\t\tpadding-left: 0;\r\n\t\tpadding-top: 22px;\r\n\t}\r\n\r\n\t.rt-community-card__benefits {\r\n\t\tgrid-template-columns: 1fr;\r\n\t\tgap: 12px;\r\n\t}\r\n}\r\n\r\n\/* Mobile *\/\r\n@media (max-width: 640px) {\r\n\t.rt-community-card__inner {\r\n\t\tpadding: 22px 18px;\r\n\t\tborder-radius: 18px;\r\n\t\tgap: 20px;\r\n\t}\r\n\t\r\n\t.rt-community-card__side {\r\n\t\tpadding-top: 18px;\r\n\t}\r\n\r\n\t.rt-community-card__benefits li {\r\n\t\tfont-size: 16px;\r\n\t}\r\n\r\n\t.rt-community-card__actions {\r\n\t\tmargin-top: 24px;\r\n\t\talign-items: stretch;\r\n\t}\r\n\r\n\t.rt-community-card__button {\r\n\t\twidth: 100%;\r\n\t\tmin-height: 56px;\r\n\t\tfont-size: 18px;\r\n\t\tpadding: 0 20px;\r\n\t}\r\n\r\n\t.rt-community-card__small {\r\n\t\ttext-align: center;\r\n\t\tpadding-left: 0;\r\n\t}\r\n}\r\n<\/style>\r\n\t\r\n","protected":false},"excerpt":{"rendered":"<p>Linux distributions make it easy to keep system logs, and a paper trail helps me understand where things went wrong and how to fix them. As great as logging is, it can lead to an unexpected problem on a Raspberry Pi: constant disk writes degrade SD cards and cause them to fail. In this guide,&#8230;<\/p>\n","protected":false},"author":363,"featured_media":30712,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_kad_blocks_custom_css":"","_kad_blocks_head_custom_js":"","_kad_blocks_body_custom_js":"","_kad_blocks_footer_custom_js":"","_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_kad_post_classname":"","footnotes":""},"categories":[2],"tags":[],"class_list":["post-30510","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-how-to-tutorials"],"taxonomy_info":{"category":[{"value":2,"label":"How-To Tutorials"}]},"featured_image_src_large":["https:\/\/raspberrytips.com\/wp-content\/uploads\/2024\/07\/banner_log2ram-1024x683.jpg",1024,683,true],"author_info":{"display_name":"Thomas Dyan","author_link":"https:\/\/raspberrytips.com\/author\/thomas\/"},"comment_info":0,"category_info":[{"term_id":2,"name":"How-To Tutorials","slug":"how-to-tutorials","term_group":0,"term_taxonomy_id":2,"taxonomy":"category","description":"","parent":0,"count":228,"filter":"raw","cat_ID":2,"category_count":228,"category_description":"","cat_name":"How-To Tutorials","category_nicename":"how-to-tutorials","category_parent":0}],"tag_info":false,"_links":{"self":[{"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/posts\/30510","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/users\/363"}],"replies":[{"embeddable":true,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/comments?post=30510"}],"version-history":[{"count":138,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/posts\/30510\/revisions"}],"predecessor-version":[{"id":53832,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/posts\/30510\/revisions\/53832"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/media\/30712"}],"wp:attachment":[{"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/media?parent=30510"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/categories?post=30510"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/raspberrytips.com\/wp-json\/wp\/v2\/tags?post=30510"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}