From owner-freebsd-questions@FreeBSD.ORG Sun Sep 7 11:10:00 2008 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 0DBB71065674 for ; Sun, 7 Sep 2008 11:10:00 +0000 (UTC) (envelope-from jstrother9109@gmail.com) Received: from qb-out-0506.google.com (qb-out-0506.google.com [72.14.204.239]) by mx1.freebsd.org (Postfix) with ESMTP id A922F8FC1E for ; Sun, 7 Sep 2008 11:09:59 +0000 (UTC) (envelope-from jstrother9109@gmail.com) Received: by qb-out-0506.google.com with SMTP id e34so1745560qbe.35 for ; Sun, 07 Sep 2008 04:09:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type:references; bh=DU4nccj5h6kqwebrXEX9+dwcevUvkykuCpGCke9PFuU=; b=Iffn1UqtwiIHPDmv6NdR9zcVJNXhOCjLb+QDb0AWwc1TXkiWqJThAgSdZCbnwbrGw5 bgAXku/ssmvdWP5NQk0y8gxI292LQLjSzL/o2XkfEByilnqq1ClhyMrBUphcTI0mlh4R LQoymqik0A+qrM78ahdUcvEQ/vrRRLV75sTU0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:references; b=n+3KLDci+hWpvJU7Sk27cjx36qiGa2RL1l5VbbS7jba1re9wREF9DwNQpkZEFzOheN UKChIgsMaXwuc9d8zS1Vm7g7ZXM4nr+WU8CMay5FwrJytBokq/9ttz63br8fhph+myHT OTnEeIBxpLbElCYqnWHIc5tkGd+zK76/n7wRI= Received: by 10.103.176.2 with SMTP id d2mr9303204mup.134.1220785798016; Sun, 07 Sep 2008 04:09:58 -0700 (PDT) Received: by 10.103.165.4 with HTTP; Sun, 7 Sep 2008 04:09:57 -0700 (PDT) Message-ID: <4b2381fb0809070409h32107db3ge19ee8c36603b79d@mail.gmail.com> Date: Sun, 7 Sep 2008 04:09:57 -0700 From: "James Strother" To: freebsd-questions@freebsd.org In-Reply-To: <200809071022.37765.jmc-freebsd2@milibyte.co.uk> MIME-Version: 1.0 References: <4b2381fb0809060359u53f85d06u4696d527063c5e4d@mail.gmail.com> <48C26870.7050100@gmail.com> <4b2381fb0809062307x4b7ef550lfba5d74e9057dccf@mail.gmail.com> <200809071022.37765.jmc-freebsd2@milibyte.co.uk> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Re: switching discs during install 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: Sun, 07 Sep 2008 11:10:00 -0000 > They might not be as haphazard as you suggest. ISTR once reading that > the CDs were arranged with the most popular packages on the first CD so > that you would only need to download disk 2 (and 3) if you wanted some > of the less common packages. With your suggested layout it's quite > likely that a package which most of the others depend on would be right > down at the bottom of the list with the result that you'd invariably > need to download all 3 CD images. I have to admit that I have no idea how they are organized, there could be very good reasons for doing it the current way. However, I was actually only suggesting that the packages be sorted by "popularity", where "popularity" is the number of packages which depend on the package in question (this would need to include both direct and indirect dependencies). The most-depended-upon packages would go on the first disc and the least-depended-upon packages would go on the last. If you move from first to last, then all dependencies are automatically satisfied. While this should put most of the common packages on the first disc, you could have a frequently installed package that was not highly depended upon that was placed on the last disc. If your aim was to minimize the number of discs that had to be downloaded this ordering would be less that ideal. However, there are a large number of orderings which still satisfy the dependencies; the one I gave is just a good starting point. If you wanted, such packages could be "promoted" in the ordering by placing them immediately after all of their dependencies had been satisfied. In fact, you could do this recursively for every package that the particular package depended upon so that it occurred as early in the ordering as possible. And if you had a list of such "important" packages this could clearly be performed for each (if you started with the least important and moved to the most, you could ensure that the most important were placed earlier in the ordering). I think the best way to avoid the need for frequent CD switching would > be for sysinstall to sort the list of selected packages into CD order > before installing them. I imagine this would require some changes to > pkg_add to prevent it from installing dependencies and I expect the > possible benefits would not be considered to be sufficient to justify > the effort. I agree that fiddling with pkg_add to place the packages neatly on the disc would probably not be worth the effort, but I'm not sure that it is necessary. In order for the method I suggested to work, sysinstall would have to be modified to attempt installation in the selected ordering. If you had a list of the packages in this ordering, you would only have to flip the "please install this one" bit for the selected packages, and then traverse the list in order installing/ignoring each package. Since all dependencies would be satisfied by virtue of the ordering, pkg_add would find that every dependency had already been satisfied and should not cause any problems.