From owner-freebsd-hackers@FreeBSD.ORG Thu Jun 14 01:45:40 2012 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (unknown [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6CE09106566C for ; Thu, 14 Jun 2012 01:45:40 +0000 (UTC) (envelope-from delphij@delphij.net) Received: from anubis.delphij.net (anubis.delphij.net [64.62.153.212]) by mx1.freebsd.org (Postfix) with ESMTP id 4FCFF8FC08 for ; Thu, 14 Jun 2012 01:45:40 +0000 (UTC) Received: from delta.delphij.net (drawbridge.ixsystems.com [206.40.55.65]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by anubis.delphij.net (Postfix) with ESMTPSA id E7659FC7F; Wed, 13 Jun 2012 18:45:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=delphij.net; s=anubis; t=1339638340; bh=GgbCSdI/YXj6wuYEu7+Uz21cpRz6oG4DpFADxFfYQDc=; h=Date:From:Reply-To:To:CC:Subject:References:In-Reply-To; b=Bz7EALJUi7L2Of+lO45+e/deDo9GYevDHDXIPXpv4TQM4RAaRGtUloopuap9/ZLLz 1SanKe6vzk2bl183pOuX6bD9syAYDiliY14fKtWYSIb9aV7w2pF+3KJMHq9HYyxuGl cOSBkCRVVwF5ZF/JiI8eV6Tw4oLDL3e+0AX6PmuI= Message-ID: <4FD94240.6060806@delphij.net> Date: Wed, 13 Jun 2012 18:45:36 -0700 From: Xin Li Organization: The FreeBSD Project MIME-Version: 1.0 To: Wojciech Puchar References: In-Reply-To: X-Enigmail-Version: 1.4.2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org, d@delphij.net Subject: Re: BIO_DELETE equivalent for file on FFS filesystem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: d@delphij.net List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Jun 2012 01:45:40 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 05/26/12 08:06, Wojciech Puchar wrote: > is it possible. suppose i have 1GB file with my data and 100 1 > megabyte parts of it is no longer needed. i could reorganize that > file to take 900MB or... can i call some system function to "punch" > holes? I think you can only truncate the file at this time, pretty much like brk() works for memory. Cheers, - -- Xin LI https://www.delphij.net/ FreeBSD - The Power to Serve! Live free or die -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQEcBAEBCAAGBQJP2UJAAAoJEG80Jeu8UPuzvaMH/Rb0IwPZV1xyapMoSv71FQPz 0yhAMLamNBEIRf2mvBZHp9ASLBRDYZsDtU+EAFelS56hBkuYywSb//m+cTeQpqT3 Wz5713DRtrpi6X7KrGCFmtpzhCiYyS11YLBGWIe6PjBFNdF+dveNGh5TPy4bKmVy j4cx+a3mHEdXOinayUzfPI1wpxF1eI/6cIiP0G5wy0VAApbk5qgE4PVlqZa8zKFF 4sePD6vsYTQ+3PVMwkfeJiX8E1ZMKAo/boD8Hw3jU24kY5n4bC+Qcqvm/JCFArGr QfA0K+TZ7R86lfs7yyjhmnf3fSBZVTOG4anYOAeOqgghORL43JhGjKZcDRw2CjM= =Y8H3 -----END PGP SIGNATURE-----