Device unable to restart

Hi,
I have a openwrt based device. I am facing this strange problem. The problem happens when the device has uptime of about 6 days or so. I have a script which restarts the device if it is unable to ping predefined IP address. What I observe is that under some unknown condition, the device stops rebooting. What could be reason for the script and reboot command to get hanged?
Following is the output of the ps command. ping_reboot.sh is the script which pings an IP and reboot if it is unable to ping. The script is run as cron task. You may observe that the script calls reboot but device doesn't reboot. The reboot command and ping_reboot script are kind of frozen. The cron then runs the script again as device is unable to reboot. Rest of the device is working fine and the device itself is not in hung condition.

31336 root      1244 S    /bin/sh /usr/sbin/ping_reboot.sh cfg01c21d
31530 root      1216 D    reboot
31882 root      1244 S    /bin/sh /usr/sbin/ping_reboot.sh cfg01c21d
32076 root      1216 D    reboot
32236 root      1216 D    /sbin/reboot
32253 root      1244 S    /bin/sh /usr/sbin/ping_reboot.sh cfg01c21d
32304 root      1244 S    /bin/sh /usr/sbin/ping_reboot.sh cfg01c21d
32419 root      1216 D    reboot
32498 root      1216 D    reboot

Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button:
grafik
Remember to redact passwords, MAC addresses and any public IP addresses you may have:

ubus call system board
cat /etc/config/network
cat /etc/config/wireless
cat /etc/config/dhcp
cat /etc/config/firewall