I don't know if you have awk in your busybox, but I needed to do something like this and I pad=1024 awk -v cnt=$pad 'BEGIN{for(i=0;i<cnt;i++){printf("%c",255);}}' >> filename --Clem