erasing partiton 5 could be done as follow
- Code: Select all
dd if=/dev/null of=/dev/sdb5
assuming sdb is your wd disk
dd if=/dev/null of=/dev/sdb5
WDMyCloud:~# dd if=/dev/null of=/dev/sda5
0+0 records in
0+0 records out
0 bytes (0 B) copied, 0.000396285 s, 0.0 kB/s
WDMyCloud:~# sudo dd if=/dev/zero of=/dev/sda5
dd: writing to `/dev/sda5': No space left on device
204801+0 records in
204800+0 records out
104857600 bytes (105 MB) copied, 4.4391 s, 23.6 MB/s
mdadm --stop /dev/md0
mdadm --add /dev/md1 /dev/sda2
P.S. Maybe newer version of Barebox check crc :scratch As you can see from logs wd use old version (2011.06.0) when the last one was made yesterday (2022.08.0
(Note you should check if after boot partition 5 is still empty and if part 7is unchanged, meaning have the content of the one I have sent you.(To check that they are not overwritten at boot by barebox).
<snip>
kernel_copy ()
{
kernelFile=${upgradePath}/boot/uImage
if [ -e "${kernelFile}" ]; then
## TBD: Add multi drive support
#dd if=${kernelFile} of=${kernelPart1}
#dd if=${kernelFile} of=${kernelPart2}
##
dd if=${kernelFile} of=/dev/sda${kernelPart1}
dd if=${kernelFile} of=/dev/sda${kernelPart2}
fi
echo "Done kernel partition copy."
}
control_copy ()
{
controlFile=${upgradePath}/boot/boot.env
[ -z "${upgradeDevice}" ] || [ "${upgradeDevice}" == "/dev/md0" ] && cp -v ${upgradePath}/usr/local/share/k1m0.env ${controlFile}
[ "${upgradeDevice}" == "/dev/md1" ] && cp -v ${upgradePath}/usr/local/share/k1m1.env ${controlFile}
if [ -f "${controlFile}" ]; then
## TBD: Add multi drive support
#dd if=${controlFile} of=${controlPart1}
#dd if=${controlFile} of=${controlPart2}
##
dd if=${controlFile} of=/dev/sda${controlPart1}
dd if=${controlFile} of=/dev/sda${controlPart2}
fi
echo "Done control partition copy."
}
_install ()
{
# perform copy and configure only when installing on a real target
[ ! -f /tmp/nas_build ] && kernel_copy
[ ! -f /tmp/nas_build ] && control_copy
configure
}
_upgrade ()
{
kernel_copy
control_copy
configure
}
<snip>
Users browsing this forum: No registered users and 2 guests