From owner-freebsd-arch Mon Jul 16 4:13:15 2001 Delivered-To: freebsd-arch@freebsd.org Received: from kalaid.f2f.com.ua (kalaid.f2f.com.ua [62.149.0.33]) by hub.freebsd.org (Postfix) with ESMTP id 0CCA037B401; Mon, 16 Jul 2001 04:13:07 -0700 (PDT) (envelope-from sobomax@FreeBSD.org) Received: from Mail-In.Net (borey.f2f.com.ua [62.149.0.24]) by kalaid.f2f.com.ua (8.11.4/8.11.4) with ESMTP id f6GBFHj72554; Mon, 16 Jul 2001 14:15:18 +0300 (EEST) (envelope-from sobomax@FreeBSD.org) Received: from vega.vega.com (root@[212.35.189.160]) by Mail-In.Net (8.11.3/8.H.Z) with ESMTP id f6GBE4u20273; Mon, 16 Jul 2001 14:14:04 +0300 (EEST) Received: from FreeBSD.org (big_brother.vega.com [192.168.1.1]) by vega.vega.com (8.11.4/8.11.3) with ESMTP id f6GBBxD47572; Mon, 16 Jul 2001 14:11:59 +0300 (EEST) (envelope-from sobomax@FreeBSD.org) Message-ID: <3B52CC08.1B08210F@FreeBSD.org> Date: Mon, 16 Jul 2001 14:12:17 +0300 From: Maxim Sobolev Organization: Vega International Capital X-Mailer: Mozilla 4.77 [en] (Windows NT 5.0; U) X-Accept-Language: en,uk,ru MIME-Version: 1.0 To: small@FreeBSD.org Cc: arch@FreeBSD.org Subject: Extending md(4) to allow it use pre-compressed disk image Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi folks, I extended md(4) driver to allow it use pre-compressed disk image. In contrast with the current implementation, when loader(8) on loading decompresses compressed image and holds it uncompressed in the memory, with new feature loader(8) places compressed image into a memory, while md(4) decompresses sectors when they are read. This could be useful to decrease minimal memory requrements on FreeBSD install or in another cases when memory is scarce. Performance is quite good - even P133 reads data from such device at 2-2.5MB/s. Since standard gzip format is not really suitable for the task I created an utility that splits original image into clusters (cluster size could vary), compresses each cluster using zlib and writes compressed clusters along with information about offset of each cluster into resulting image. After that compressed image could be put into the floppy or other media, loaded using loader(8) and accessed through md(4) as usually. The only difference is that it is impossible to write into resulting disk. I would like to know if there is enough interest in integrating this feature into base system, please let me know what do you think about it. -Maxim P.S. Please keep me on the CC list. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message