modifying n bytes on a page can be considered a physical log. These include the following types: Mlog_write_string, Mlog_8bytes, Mlog_2bytes, Mlog_1bytes, Mlog_4bytes. Various page-linked table pointer modifications and file header, Segment page content modifications are recorded in these ways log. The specific format is as follows:
1, Mlog_2bytes, Mlog_1bytes, Mlog_4bytes:
2, Mlog_8bytes
3, Mlog_write_string
4, variable length byte algorithm mach_write_compressed:
if (n < 0x80UL) { mach_write_to_1(b, n); return(1); } else if (n < 0x4000UL) { mach_write_to_2(b, n | 0x8000UL); return(2); } else if (n < 0x200000UL) { mach_write_to_3(b, n | 0xC00000UL); return(3); } else if (n < 0x10000000UL) { mach_write_to_4(b, n | 0xE0000000UL); return(4); } else { mach_write_to_1(b, 0xF0UL); mach_write_to_4(b + 1, n); return(5); }
5, Mlog_write_ulint, Mlog_write_ull, mlog_log_string are written to 1, 2, 4; 8 bytes; The log write function of the string.
InnoDB Redo Log Format-physical log