0

I'm using 32GB device(linux based), which is using FAT32 filesystem, i want to test one thing that what would be the device behavior when i fill the device space with some random files.

normally side loading the contents will take more than a day to fill the device.

it would be better to create junk files via shell script to fill the empty space. can anyone help me in this?

I don't want use the below commands. In my case i want create actual files.

fallocate -l 50G big_file
truncate -s 50G big_file
dd of=bigfile bs=1 seek=50G count=0
  • Since FAT32 doesn't support sparse files there would be little wrong with fallocate. Maybe in a loop rather than as a single lump, though. – roaima Jun 4 '18 at 7:25
  • 1
    Isn't FAT32 supposed not to be able to have file over 4GB? – cylgalad Jun 4 '18 at 7:52
0

try dd command from /dev/urandom something like this:

dd if=/dev/urandom of=/<path_to_file> bs=2048 conv=noerror,sync count=999999
  • Hi thanks lot, do you have any manual/document to know more about this? – Santhosh Jun 4 '18 at 6:50
  • I tired in my device, that command is not working and shows usage of dd. – Santhosh Jun 4 '18 at 7:01
  • 1
    @Santhosh, I think it might work for this test to fill the partition with a file containing zeros, so you can use sudo dd if=/dev/zero of=path/blank bs=4096 . It might be faster. – sudodus Jun 4 '18 at 8:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.