Status: 500 Internal Server Error using external usb storage

I've followed the exroot tutorial to attach a usb pendrive to my openwrt router.
It seems to work well, but after some time (hours), when I try to access whatever configuration page via browser I get this string:

Status: 500 Internal Server Error Failed to execute cbi dispatcher target for entry '/admin/system/system'. The called action terminated with an exception: /usr/lib/lua/luci/template.lua:97: Failed to execute template 'cbi/header'. A runtime error occured: /usr/lib/lua/luci/template.lua:97: Failed to execute template 'header'. A runtime error occured: /usr/lib/lua/luci/template.lua:97: Failed to execute template 'themes/bootstrap/header'. A runtime error occured: [string "/usr/lib/lua/luci/view/themes/bootstrap/hea..."]:133: bad argument #1 to 'pairs' (table expected, got nil) stack traceback: [C]: in function 'pairs' [string "/usr/lib/lua/luci/view/themes/bootstrap/hea..."]:133: in function 'render_changes' [string "/usr/lib/lua/luci/view/themes/bootstrap/hea..."]:147: in main chunk stack traceback: [C]: in function 'error' /usr/lib/lua/luci/template.lua:97: in function 'render' /usr/lib/lua/luci/dispatcher.lua:346: in function 'include' [string "/usr/lib/lua/luci/view/header.htm"]:3: in main chunk stack traceback: [C]: in function 'error' /usr/lib/lua/luci/template.lua:97: in function 'render' /usr/lib/lua/luci/dispatcher.lua:346: in function 'include' [string "/usr/lib/lua/luci/view/cbi/header.htm"]:1: in main chunk stack traceback: [C]: in function 'error' /usr/lib/lua/luci/template.lua:97: in function (tail call): ? /usr/lib/lua/luci/dispatcher.lua:890: in function

This is the output of lsusb and dmesg

/ # lsusb
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 002: ID 054c:0243 Sony Corp. MicroVault Flash Drive
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
/ # dmesg |egrep 'usb'
[    5.687735] usbcore: registered new interface driver usbfs
[    5.698805] usbcore: registered new interface driver hub
[    5.709522] usbcore: registered new device driver usb
[    5.760767] phy phy-usbphy.0: remote usb device wakeup disabled
[    5.772572] phy phy-usbphy.0: UTMI 16bit 30MHz
[    6.682049] usb 1-1: new high-speed USB device number 2 using ehci-platform
[    7.504316] usb 1-1.2: new high-speed USB device number 3 using ehci-platform
[    7.845175] usb 1-1.3: new high-speed USB device number 4 using ehci-platform
[    7.951052] usb 1-1.4: new high-speed USB device number 5 using ehci-platform
[   11.894015] usb-storage 1-1.2:1.0: USB Mass Storage device detected
[   11.910061] scsi host0: usb-storage 1-1.2:1.0
[   11.919496] usb-storage 1-1.4:1.0: USB Mass Storage device detected
[   11.936049] scsi host1: usb-storage 1-1.4:1.0
[   11.945344] usbcore: registered new interface driver usb-storage