Quote:
Is there a way in linux to create a completely useless file at a specific size?

Some Linuxes will have a utility called mkfile that does exactly that.

If yours does not, use dd.
Code:
dd if=/dev/zero of=useless-file bs=x count=y

This reads from /dev/zero (which produces an endless string of zeroes) and writes them to useless-file. The x argument to bs should be a number indicating the "block size" in bytes and the y argument to count is the number of blocks you want to copy. So if you want a 10MB file, I'd probably do
Code:
dd if=/dev/zero of=useless-file bs=1048576 count=10