From owner-freebsd-questions@FreeBSD.ORG Thu Sep 17 03:28:21 2009 Return-Path: Delivered-To: freebsd-questions@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7883E106568B for ; Thu, 17 Sep 2009 03:28:21 +0000 (UTC) (envelope-from bf1783@googlemail.com) Received: from mail-fx0-f210.google.com (mail-fx0-f210.google.com [209.85.220.210]) by mx1.freebsd.org (Postfix) with ESMTP id 121428FC12 for ; Thu, 17 Sep 2009 03:28:20 +0000 (UTC) Received: by fxm6 with SMTP id 6so3759017fxm.43 for ; Wed, 16 Sep 2009 20:28:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:cc:content-type; bh=hkHCLY8EDyv8ZUPsXNNCpXyT0cT5yFzx2hJApS9AuAY=; b=PUZbhhHsIDFCgjH0gzLj5znbX9iSO7/PWz4Jyw/VL6YvXZLRTDO2BwLFAs7ViEXugO +r4VSdqp2zKOMRNkI96xA5Mlkb6Kml4QJx2FffcnPoZGiXNFaufPE8lY4ActoB6FAV/d 81YHCgYWnEBgNsXKTNuHAkFuB9UDddd4AjYHY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:cc:content-type; b=Myf5mYW6n0SdkHMPvCDZvYcl6c6F9sLSVBKTmNV+wBV6QDFfygZqADWjuUqvmz01cM i90IEIQLJkLAas1SbA42rovtspeuA7cPZSqSPgOofwY0A5bLWpWbvkuIe2sr1YnCp+PU Zx08kzN1wwJY3ECuW0QZigeSPzjKypH45el14= MIME-Version: 1.0 Received: by 10.239.143.215 with SMTP id l23mr869694hba.163.1253158098129; Wed, 16 Sep 2009 20:28:18 -0700 (PDT) Date: Thu, 17 Sep 2009 03:28:18 +0000 Message-ID: From: "b. f." To: freebsd-questions@FreeBSD.org Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd@superhero.nl Subject: Re: Change one file in an ISO image X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Sep 2009 03:28:21 -0000 Patrick Gelsema wrote: >I need to change one file in an existing ISO image. It is a DVD image btw. >Unfortunately I dont have many options of changing the fie before creating >the image. > >Mounting is not the issue, copying data neither but the ISO is also >bootable. There must be a simpler solution as in copying all the content >with cpio and making it bootable. OS on the DVD is WinPE btw. > >Does anyone have some pointers for performing this action? Unfortunately, libarchive(3), which is used by tar(1) and cpio(1) on recent versions of FreeBSD, seems to have only read and extract support for ISO 9660 archives, and not write support (see libarchive-formats(5) or http://code.google.com/p/libarchive/wiki/LibarchiveFormats ). So while you could use tar(1) or cpio(1) to extract the contents of the dvd without mounting it in order to make your change, you would have to use some other tool to write the new .iso image, like mkisofs(8) from the sysutils/cdrtools-devel port. (And if the original image has extensions that are not supported by librarchive(3), you could use something like readcd(1) from that same port instead of tar(1) or cpio(1) to read and extract it.) b.