{"id":3736,"date":"2025-05-29T17:50:14","date_gmt":"2025-05-29T17:50:14","guid":{"rendered":"https:\/\/w3buddy.com\/?post_type=cposts&#038;p=3736"},"modified":"2025-05-29T17:50:15","modified_gmt":"2025-05-29T17:50:15","slug":"log-writer-process-lgwr","status":"publish","type":"cposts","link":"https:\/\/w3buddy.com\/blog\/notes\/getting-started-with-oracle-dba\/log-writer-process-lgwr\/","title":{"rendered":"Log Writer Process (LGWR)"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Committing Redo Changes \ud83d\ude80<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\ud83e\uddfe What Is LGWR?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The <strong>Log Writer Process (LGWR)<\/strong> is a crucial background process in Oracle Database that ensures all <strong>changes made in memory (redo log buffer)<\/strong> are safely written to <strong>online redo log files<\/strong>\u2014protecting data integrity and enabling recovery.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\ud83d\udee0\ufe0f What Does LGWR Do?<\/h3>\n\n\n\n<figure class=\"wp-block-table has-small-font-size\"><table><thead><tr><th>\ud83d\udd27 <strong>Function<\/strong><\/th><th>\ud83d\udccc <strong>Details<\/strong><\/th><\/tr><\/thead><tbody><tr><td>\ud83e\udeb5 <strong>Sequential Redo Logging<\/strong><\/td><td>Writes <strong>redo log entries<\/strong> from the redo log buffer to the <strong>online redo logs<\/strong>.<\/td><\/tr><tr><td>\ud83e\ude9f <strong>Multiplexed Logging<\/strong><\/td><td>In a <strong>multiplexed redo log setup<\/strong>, LGWR writes to <strong>all members of the group<\/strong> simultaneously.<\/td><\/tr><tr><td>\u2699\ufe0f <strong>Delegates Work<\/strong><\/td><td>Uses <strong>LGnn worker processes (LG00\u2013LG99)<\/strong> for parallel writing operations and posting results to waiting server processes.<\/td><\/tr><tr><td>\ud83d\udce1 <strong>Redo Shipping<\/strong><\/td><td><strong>TTnn processes (TT00\u2013TTzz)<\/strong> send redo logs to <strong>standby databases<\/strong> when <strong>ASYNC redo transport<\/strong> is configured.<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">\ud83e\udde9 Additional Notes<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>LGWR runs<\/strong> as either a <strong>thread or OS process<\/strong>, depending on the environment.<\/li>\n\n\n\n<li>Operates in <strong>Oracle ASM<\/strong> and <strong>Oracle RAC<\/strong>\u2014each RAC instance has its own redo log set.<\/li>\n\n\n\n<li><strong>Ensures recoverability<\/strong> by immediately flushing redo entries during commits, checkpoints, and log switches.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">\ud83d\udd12 Why LGWR Matters<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Guarantees <strong>durability of transactions<\/strong>.<\/li>\n\n\n\n<li>Enables <strong>fast recovery<\/strong> in the event of a failure.<\/li>\n\n\n\n<li>Minimizes performance impact by <strong>offloading to worker processes<\/strong>.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">\ud83d\udcd8 <em>Tip of the Day:<\/em><br>Use the view <code>V$LOGFILE<\/code> and <code>V$LOG<\/code> to monitor LGWR activity and multiplexed redo log status. Keeping redo logs on <strong>separate disks<\/strong> enhances performance and safety!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Committing Redo Changes \ud83d\ude80 \ud83e\uddfe What Is LGWR? The Log Writer Process (LGWR) is a crucial background process in Oracle Database that ensures all changes made in memory (redo log buffer) are safely written to online redo log files\u2014protecting data integrity and enabling recovery. \ud83d\udee0\ufe0f What Does LGWR Do? \ud83d\udd27 Function \ud83d\udccc Details \ud83e\udeb5 Sequential [&hellip;]<\/p>\n","protected":false},"template":"","meta":{"googlesitekit_rrm_CAowu461DA:productID":""},"categories":[960,952],"class_list":["post-3736","cposts","type-cposts","status-publish","hentry","category-getting-started-with-oracle-dba","category-notes"],"_links":{"self":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/cposts\/3736","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/cposts"}],"about":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/types\/cposts"}],"wp:attachment":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/media?parent=3736"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/categories?post=3736"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}