diff --git a/files/Aboot/boot0.j2 b/files/Aboot/boot0.j2 index db170ab2b0..681d0e1e35 100644 --- a/files/Aboot/boot0.j2 +++ b/files/Aboot/boot0.j2 @@ -469,8 +469,7 @@ write_platform_specific_cmdline() { local platform="$(cmdline_get platform)" local sid="$(cmdline_get sid | sed 's/Ssd$//')" - # set varlog size to 100MB - local varlog_size=100 + local varlog_size=0 # sonic_mode is set to fixed by default. sonic_mode="fixed" @@ -545,6 +544,7 @@ write_platform_specific_cmdline() { fi if in_array "$sid" "PikeIslandZ" "PikeIslandZ-F" "PikeIslandZ-2F" "PikeIslandZ-R" "PikeIslandZ-2R"; then aboot_machine=arista_720dt_48s + varlog_size=2048 fi if [ "$sid" = "BlackhawkT4O" ]; then aboot_machine=arista_7050px4_32s @@ -635,18 +635,20 @@ write_platform_specific_cmdline() { read_system_eeprom fi - if [ $flash_size -ge 28000 ]; then - varlog_size=4096 - elif [ $flash_size -gt 4000 ]; then - varlog_size=400 - else - varlog_size=256 - cmdline_add logs_inram=on - if [ $flash_size -le 2000 ]; then - # enable docker_inram for switches with less than 2G of flash - varlog_size=128 - cmdline_add docker_inram=on - fi + if [ $varlog_size -eq 0 ]; then + if [ $flash_size -ge 28000 ]; then + varlog_size=4096 + elif [ $flash_size -gt 4000 ]; then + varlog_size=400 + else + varlog_size=256 + cmdline_add logs_inram=on + if [ $flash_size -le 2000 ]; then + # enable docker_inram for switches with less than 2G of flash + varlog_size=128 + cmdline_add docker_inram=on + fi + fi fi cmdline_add "varlog_size=$varlog_size"