Tux3 now has a command interpreter to aid in debugging, with commands
like:tux3 make foodev
that makes a filesystem on device foodev, which can also be a file. It
normally is a file for me and I make it sparse like this:dd if=/dev/zero of=foodev bs=1 count=1 seek=100K
I can see how many blocks tux3 actually used in it by:
du foodev
less the few blocks that the sparse file has for metatdata and the
little blob of data at the end that dd puts there. (I don't know how
to make dd truncate without writing, I am not sure it is possible.)Then:
echo "hello world!" | tux3 write foodev foo
creates and writes to file foo in foodev. A subsequent write will
fail with EEXIST, which is maybe not quite what we want.Finally:
tux3 read foodev foo
outputs "hello world!".
The following command sequence is particularly interesting:
tux3 make --blocksize 256 foodev
echo hello | tux3 write --seek 72057594037927930 foodev foo
tux3 read --seek 72057594037927930 foodev fooIt writes "hello" into the last few bytes of a 64 Petabyte file, the
largest that Tux3 can create with 256 byte blocks :-)Using "du foodev" before and after creating and writing to its
filesystem shows that Tux3 only used 8K for the entire filesystem
including the multi-petabyte sparse file, root directory, inode table
and allocation bitmaps.To build tux3:
g99 -g -Wall -lpopt buffer.c diskio.c tux3.c -otux3
Regards,
Daniel
_______________________________________________
Tux3 mailing list
Tux3@tux3.org
http://tux3.org/cgi-bin/mailman/listinfo/tux3
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
| Tarkan Erimer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Amit K. Arora | [RFC] Heads up on sys_fallocate() |
| Chuck Ebbert | Why do so many machines need "noapic"? |
git: | |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| David Miller | [GIT]: Networking |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Natalie Protasevich | [BUG] New Kernel Bugs |
