2.4. Mixed with uncompressed files
You can mix compressed and non compressed files with Cogofs. For example,
if you want to compress your files in a directory /mnt/myfiles, you can create
a Cogofs mount by
$ mkdir /mnt/cogofs/
$ mount -t cogofs -o fs=/mnt/myfiles none /mnt/cogofs
$ |
where
/mnt/cogofs is the mount point.
Check with this,
$ ls -l /mnt/myfiles/
-rw-r--r-- 1 user user 184324 Aug 8 10:00 myfile1.dat
-rw-r--r-- 1 user user 132852 Aug 8 10:01 myfile2.gz
$ ls -l /mnt/cogofs/
-rw-r--r-- 1 user user 184324 Aug 8 10:00 myfile1.dat
-rw-r--r-- 1 user user 132852 Aug 8 10:01 myfile2.gz
$
|
which the two file system have no difference. You then try to create a compressed file
in the Cogofs mounted file system by copying an existing file from /tmp/myfile3.txt
$ cp /tmp/myfile3.txt /mnt/cogofs/
$ ls -l /mnt/cogofs/
-rw-r--r-- 1 user user 184324 Aug 8 10:00 myfile1.dat
-rw-r--r-- 1 user user 132852 Aug 8 10:01 myfile2.gz
-rw-r--r-- 1 user user 22345 Aug 8 10:02 myfile3.txt
$ ls -l /mnt/myfiles/
-rw-r--r-- 1 user user 184324 Aug 8 10:00 myfile1.dat
-rw-r--r-- 1 user user 132852 Aug 8 10:01 myfile2.gz
-rw-r--r-- 1 user user 12035 Aug 8 10:02 myfile3.txt.cogo
$
|
This is how it works, directories are not compressed (not converted to .cogo).