Odpalanie FortiGate z zapasowej partycji po nieudanej aktualizacji

Przeczytasz to w: 3 minutPrzeczytasz to w: 3 minut

Jakiś czas zrobiłem update FortiOS u klienta do z 6.4.0 do 6.4.2 na FortiGate 100F i efekt był taki, że urządzenie się co chwile restartowało. Byłem zdziwiony, w końcu na moim urządzeniu nie było takiego problemu. W takiej sytuacji należy się podłączyć poprzez port CONSOLE w urządzeniu przez taki kabel:

Takie kable (konwerter RS-232 na USB + kabel RS-232 <-> RJ-45) z można dostać na Allegro. Na Windowsie 10 sterowniki zainstalują się same. Potem należy sprawdzić numer portu COM dla interfejsu szeregowego:

Potem należy wskazać ten port w PuTTY (ja korzystam akurat z KiTTY):

Po połączeniu widzimy konsolę i od razu widać w czym jest problem:

FortiGate-100F (23:49-05.21.2019)
Ver:05000008
Serial number: FG100FTK69696969
CPU: 1400MHz
Total RAM: 4 GB
Initializing boot device...
Initializing MAC... nplite#0
Please wait for OS to boot, or press any key to display configuration menu......

Booting OS...
Initializing firewall...

System is starting...
Starting system maintenance...
Scanning /dev/mmcblk0p2... (100%)
Scanning /dev/mmcblk0p3... (100%)
Unable to handle kernel NULL pointer dereference at virtual address 00000038
pgd = ffffffc0d9df0000
[00000038] *pgd=00000000c57b4003, *pud=00000000c57b4003, *pmd=0000000000000000
Internal error: Oops: 96000006 [#1] SMP

Modules linked in:
 linux_user_bde(P)
 linux_kernel_bde(P)
 filter4

task: ffffffc01c824080 ti: ffffffc0c6ccc000 task.ti: ffffffc0c6ccc000
PC is at vs_update+0x50/0x208
LR is at vs_update+0x3c/0x208
pc : [<ffffffc000474918>] lr : [<ffffffc000474904>] pstate: 60000145
sp : ffffffc0c6ccf9d0
x29: ffffffc0c6ccf9d0 x28: 0000000000000026
x27: ffffffc00048a000 x26: 0000000000000000
x25: ffffffc0cd87c000 x24: 0000000000000000
x23: ffffffc0cd87d170 x22: ffffffc0c6ccfab8
x21: ffffffc0d81e5000 x20: 0000000000000000
x19: ffffffc0c6ccfb0c x18: 0000000000000320
x17: 0000007f817c3610 x16: ffffffc00013e238
x15: ffffffffffffffff x14: ffffffffffffffff
x13: ffffffffffffffff x12: 0000000000000008
x11: 0101010101010101 x10: ff3073716e6efeff
x9 : 7f7f7f7f7f7f7f7f x8 : fefefefefefeff6a
x7 : 0080808080808080 x6 : 0000000000000000
x5 : 8080808080808000 x4 : 00000000e9120000
x3 : ffffffc0c6ccfb0c x2 : 0000000000001170
x1 : 0000000000000000 x0 : 0000000080000000

BLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAH
BLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAH
BLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAH
BLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAHBLAH

Exception stack(0xffffffc0c6ccf7f0 to 0xffffffc0c6ccf910)
f7e0:                                     c6ccfb0c ffffffc0 00000000 00000000
f800: c6ccf9d0 ffffffc0 00474918 ffffffc0 60000145 00000000 0009d4d0 ffffffc0
f820: c6ccf880 ffffffc0 00020020 ffffffbf 00000038 00000000 00000010 00000000
f840: c28f5c29 8f5c28f5 00000001 00000000 006bd6d0 00000001 00000000 00000000
f860: c6ccf960 ffffffc0 000fed78 ffffffc0 000000d0 00000000 00000002 00000000
f880: 006a4280 ffffffc0 00000000 00000000 00000000 00000000 006bd4d0 ffffffc0
f8a0: e1c00800 ffffffc0 271ae705 1b75b31a 80000000 00000000 00000000 00000000
f8c0: 00001170 00000000 c6ccfb0c ffffffc0 e9120000 00000000 80808000 80808080
f8e0: 00000000 00000000 80808080 00808080 fefeff6a fefefefe 7f7f7f7f 7f7f7f7f
f900: 6e6efeff ff307371 01010101 01010101
[<ffffffc000083374>] el1_da+0x24/0x78
[<ffffffc0004731a4>] sw_aggerate_d_netdevice.isra.2+0x5fc/0x638
[<ffffffc000473834>] __sw_net_ioctl+0x3e4/0x5d0
[<ffffffc000473a54>] sw_net_ioctl+0x34/0x58
[<ffffffc0004005d0>] inet_ioctl+0x228/0x268
[<ffffffc000391be8>] sock_ioctl+0x1e8/0x250
[<ffffffc00013df6c>] do_vfs_ioctl+0x2dc/0x5a8
[<ffffffc00013e290>] sys_ioctl+0x58/0xa8
Rebooting in 5 seconds..

Rozwiązanie jest dosyć proste: należy zrestartować urządzenie i po restarcie na samym starcie firmware nacisnąć szybko jakiś przycisk, a następnie wybrać opcję [B]: Boot with backup firmware and set as default. To spowoduje start poprzedniej wersji FortiOS z zapasowej partycji:

[<ffffffc000391be8>] sock_ioctl+0x1e8/0x250
[<ffffffc00013df6c>] do_vfs_ioctl+0x2dc/0x5a8
[<ffffffc00013e290>] sys_ioctl+0x58/0xa8
Rebooting in 5 seconds..

FortiGate-100F (23:49-05.21.2019)
Ver:05000008
Serial number: FG100FTK69696969
CPU: 1400MHz
Total RAM: 4 GB
Initializing boot device...
Initializing MAC... nplite#0
Please wait for OS to boot, or press any key to display configuration menu...

[C]: Configure TFTP parameters.
[R]: Review TFTP parameters.
[T]: Initiate TFTP firmware transfer.
[F]: Format boot device.
[I]: System information.
[B]: Boot with backup firmware and set as default.
[Q]: Quit menu and continue to boot.
[H]: Display this list of options.

Enter C,R,T,F,I,B,Q,or H:

Loading backup firmware from boot device...


Booting OS...
.Initializing firewall...

System is starting...
Starting system maintenance...
Scanning /dev/mmcblk0p1... (100%)
Scanning /dev/mmcblk0p3... (100%)


FortiGate-100F login: admin
Password:
Welcome !

FortiGate-100F #