/srv/irclogs.ubuntu.com/2021/11/07/#ubuntu-server.txt

=== Kilroy is now known as Vilroy
=== Vilroy is now known as Kilroy
=== xispita_ is now known as xispita
KilroyI need a file that is exactly 6.9 GB how would one go about creating that?17:52
andolKilroy: Are you defining a GB as 10^9 or 2^30 bytes?18:21
andolIn the first case you ought to be able to do something like this: dd if=/dev/urandom of=testfile bs=1000000 count=690018:24
andolIn the latter case I think you are ought of luck, since then 6.9 GB don't translate into an even number of bytes.18:25
TJ-Kilroy: For base 2 "echo "fallocate -l $(numfmt --from=iec 6.9G)" for base 10 "echo "fallocate -l $(numfmt --from=si 6.9G)"18:35
Kilroythanks TJ- 18:44
KilroyI get fallocate: invalid length value specified18:46
TJ-Kilroy: try the numfmt commands on their own to test18:47
TJ-Kilroy: I didn't run the fallocate commands to create anything, just verified the generated command worked18:48
TJ-Kilroy: you do need to add on a filename to create of course!18:49
TJ-Kilroy: e.g. for base 2: fallocate -l $(numfmt --from=iec 6.9G) myfile.bin18:50
Kilroyok18:55
rbasaksmoser: swtpm started. libtpms was already imported.19:37
rbasakswtpm is done19:49

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!