dd if=/dev/zero of=myfile bs=1G count=0 seek=5
This will create a 5GB file called
myfile. Notice the
seek=... commands. Just seek the size you need.
ls -l should show the correct size. I hear that sometimes Linux can’t fully recognize the size until the file is used. If that is the case try