I am trying to flash a new board using UMS. I’m getting errors “no space left on device”
Looking at the mounted drive I see that indeed only a small portion of the space is available:
~$ df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 6092012 8 6092004 1% /dev
tmpfs 1220948 1292 1219656 1% /run
/dev/sda2 467782200 95205436 348791756 22% /
none 4 0 4 0% /sys/fs/cgroup
none 5120 4 5116 1% /run/lock
none 6104724 26348 6078376 1% /run/shm
none 102400 52 102348 1% /run/user
/dev/sda1 523248 3240 520008 1% /boot/efi
/dev/sdb1 16334 5454 10880 34% /media/coral/boot
/dev/sdb2 2536888 2520504 0 100% /media/coral/rootfs
I am referring to the last line. Space should be 16GB.
This is my uboot env:
U-Boot 2016.11-2.8.1+g30a1208 (Dec 29 2017 - 02:15:42 +0000)
TEGRA124
DRAM: 2 GiB
MMC: Tegra SD/MMC: 0, Tegra SD/MMC: 1, Tegra SD/MMC: 2
In: serial
Out: serial
Err: serial
Model: Toradex Apalis TK1 2GB V1.1A, Serial# 02937679
Net: No ethernet found.
Hit any key to stop autoboot: 0
Apalis TK1 # printenv
arch=arm
baudrate=115200
board=apalis-tk1
board_name=apalis-tk1
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
boot_file=uImage
boot_net_pci_enum=pci enum
boot_net_usb_start=usb start
boot_prefixes=/ /boot/
boot_script_dhcp=boot.scr.uimg
boot_scripts=boot.scr.uimg boot.scr
boot_targets=mmc1 mmc0 usb0 pxe dhcp
bootcmd=run emmcboot; setenv fdtfile ${soc}-${fdt_module}-${fdt_board}.dtb && run distro_bootcmd
bootcmd_dhcp=run boot_net_usb_start; run boot_net_pci_enum; if dhcp ${scriptaddr} ${boot_script_dhcp}; then source ${scriptaddr}; fi;
bootcmd_mmc0=setenv devnum 0; run mmc_boot
bootcmd_mmc1=setenv devnum 1; run mmc_boot
bootcmd_pxe=run boot_net_usb_start; run boot_net_pci_enum; dhcp; if pxe get; then pxe boot; fi
bootcmd_usb0=setenv devnum 0; run usb_boot
bootdelay=1
console=ttyS0
cpu=armv7
defargs=lp0_vec=2064@0xf46ff000 core_edp_mv=1150 core_edp_ma=4000 usb_port_owner_info=2 lane_owner_info=6 emc_max_dvfs=0 user_debug=30
dfu_alt_info=apalis-tk1.img raw 0x0 0x500 mmcpart 1; boot part 0 1 mmcpart 0; rootfs part 0 2 mmcpart 0; uImage fat 0 1 mmcpart 0; tegra124-apalis-eval.dtb fat 0 1 mmcpart 0
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
emmcargs=ip=off root=/dev/mmcblk0p2 rw rootfstype=ext4 rootwait
emmcboot=run setup; setenv bootargs ${defargs} ${emmcargs} ${setupargs} ${vidargs}; echo Booting from internal eMMC chip...; run emmcdtbload; load mmc 0:1 ${kernel_addr_r} ${boot_file} && run fdt_fixup && bootm ${kernel_addr_r} - ${dtbparam}
emmcdtbload=setenv dtbparam; load mmc 0:1 ${fdt_addr_r} ${soc}-${fdt_module}-${fdt_board}.dtb && setenv dtbparam ${fdt_addr_r}
ethaddr=00:14:2d:2c:d3:4f
fdt_addr_r=0x82000000
fdt_board=eval
fdt_fixup=;
fdt_high=ffffffff
fdt_module=apalis
fdtcontroladdr=fda32a40
initrd_high=ffffffff
ipaddr=192.168.10.2
kernel_addr_r=0x81000000
loadaddr=0x81000000
mmc_boot=if mmc dev ${devnum}; then setenv devtype mmc; run scan_dev_for_boot_part; fi
netmask=255.255.255.0
nfsargs=ip=:::::eth0:on root=/dev/nfs rw
nfsboot=pci enum; run setup; setenv bootargs ${defargs} ${nfsargs} ${setupargs} ${vidargs}; echo Booting via DHCP/TFTP/NFS...; run nfsdtbload; dhcp ${kernel_addr_r} && run fdt_fixup && bootm ${kernel_addr_r} - ${dtbparam}
nfsdtbload=setenv dtbparam; tftp ${fdt_addr_r} ${soc}-${fdt_module}-${fdt_board}.dtb && setenv dtbparam ${fdt_addr_r}
pxefile_addr_r=0x90100000
ramdisk_addr_r=0x82100000
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scriptaddr=0x90000000
sdargs=ip=off root=/dev/mmcblk1p2 ro rootfstype=ext4 rootwait
sdboot=run setup; setenv bootargs ${defargs} ${sdargs} ${setupargs} ${vidargs}; echo Booting from SD card in 8bit slot...; run sddtbload; load mmc 1:1 ${kernel_addr_r} ${boot_file} && run fdt_fixup && bootm ${kernel_addr_r} - ${dtbparam}
sddtbload=setenv dtbparam; load mmc 1:1 ${fdt_addr_r} ${soc}-${fdt_module}-${fdt_board}.dtb && setenv dtbparam ${fdt_addr_r}
serial#=02937679
serverip=192.168.10.1
setethupdate=if env exists ethaddr; then; else setenv ethaddr 00:14:2d:00:00:00; fi; pci enum && tftpboot ${loadaddr} flash_eth.img && source ${loadaddr}
setsdupdate=setenv interface mmc; setenv drive 1; mmc rescan; load ${interface} ${drive}:1 ${loadaddr} flash_blk.img || setenv drive 2; mmc rescan; load ${interface} ${drive}:1 ${loadaddr} flash_blk.img && source ${loadaddr}
setup=setenv setupargs igb_mac=${ethaddr} consoleblank=0 no_console_suspend=1 console=tty1 console=${console},${baudrate}n8 debug_uartport=lsport,0 ${memargs}
setupdate=run setsdupdate || run setusbupdate || run setethupdate
setusbupdate=usb start && setenv interface usb; setenv drive 0; load ${interface} ${drive}:1 ${loadaddr} flash_blk.img && source ${loadaddr}
soc=tegra124
stderr=serial
stdin=serial
stdout=serial
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi
usbargs=ip=off root=/dev/sda2 ro rootfstype=ext4 rootwait
usbboot=run setup; setenv bootargs ${defargs} ${setupargs} ${usbargs} ${vidargs}; echo Booting from USB stick...; usb start && run usbdtbload; load usb 0:1 ${kernel_addr_r} ${boot_file} && run fdt_fixup && bootm ${kernel_addr_r} - ${dtbparam}
usbdtbload=setenv dtbparam; load usb 0:1 ${fdt_addr_r} ${soc}-${fdt_module}-${fdt_board}.dtb && setenv dtbparam ${fdt_addr_r}
vendor=toradex
ver=U-Boot 2016.11-2.8.1+g30a1208 (Dec 29 2017 - 02:15:42 +0000)
vidargs=video=tegrafb0:640x480-16@60 fbcon=map:1
Environment size: 5523/8188 bytes
Apalis TK1 # ~$
How do I fix this?
Do I just format the partition when mounted through UMS? e.g.
mkfs -t ext4 /dev/sdb2