Gutsy upgrade question: Manually downloading some packages using wget
Hugo Heden
hugoheden at gmail.com
Mon Oct 29 23:11:38 UTC 2007
On 10/29/07, David Vincent <dvincent at sleepdeprived.ca> wrote:
> Hugo Heden wrote:
> > On 10/29/07, Derek Broughton <news at pointerstop.ca> wrote:
> >> Hugo Heden wrote:
> >>
> >>> On 10/29/07, Wulfy <wulfmann at tiscali.co.uk> wrote:
> >>>> Hugo Heden wrote:
> >>>>> So obviously there is an internal database that apt-get/update-manager
> >>>>> uses, and I would want to *manually* add the manually downloaded
> >>>>> deb-files to that database..
> >>>>>
> >>>>> Any ideas?
> >>>>>
> >>>>> Hugo Heden
> >>>> The only thing I can think of which might work (though others may have
> >>>> more knowledge than I do) is when you've moved the debs to the archive,
> >>>> run:
> >>>>
> >>>> sudo dpkg -i *.deb
> >>>>
> >>>> which will install all the debs. I'm not sure that would work... if
> >>>> there were dependency problems (old debs?) in there, it might bomb out
> >>>> and leave you in a more difficult state than you're in now. :@(
> >>>>
> >>> Thanks again Wulfmann,
> >>>
> >>> Yeah, I tried that, but since those deb-files are "from Gutsy" and my
> >>> current install is Feisty, dpkg refuses to install the packages due to
> >>> conflicting and missing dependencies.
> >> Then you can't install them, period.
> >>
> >> Your best bet is to download the _source_ debs from gutsy, and recompile
> >> them on your system - but there's no guarantee they'll compile, either.
> >
> > Thanks Derek,
> >
> > I appreciate all the pointers.
> >
> > We'll see what I'll end up doing. I *will* be able to solve this
> > somehow (there's always Fresh Install), so it is not a matter of life
> > or death or anything -- now it's more that I'm getting curious.. I am
> > not sure I understand why I can't do this (but I'm rather close to
> > just taking your word for it..)
> >
> > I mean, if update-manager does (in principle)
> >
> > 1) Modify sources.list
> > 2) Download packages
> > 3) Install those packages (resolving dependencies etc)
> >
> > then should I not be able to intervene in step 2 and "help"
> > update-manager to get around a crappy-network-connection-problem by
> > manually downloading some packages?
> >
> > How about creating a local repository containing the manually
> > downloaded deb-files, and then try to convince apt-get (or, better
> > yet, update-manager) that this repository "belongs to gutsy"..
> >
> > Something like this:
> >
> > Start by creating an index file, Packages.gz:
> >
> > $ cd $HOME/dir/containing/debs
> > $ dpkg-scanpackages . /dev/null > Packages
> > $ gzip Packages
> >
> > And then editing /etc/apt/sources.list -- replace all occurrences of
> > "feisty" with "gutsy", and adding my local repository to the top of
> > the file:
> >
> > deb file:/home/heden/dir/containing/debs gutsy universe
> >
> > and lastly
> >
> > $ sudo apt-get update
> > $ sudo apt-get dist-upgrade
> >
> > Would something like that be an option? I realize that I probably have
> > to fix some errors above (for example, not all packages are from
> > universe so perhaps I need to create a more complicated local
> > repository, "resembling" a real repository) -- but in principle?
> >
> >
> > Best regards
> >
> > Hugo Heden
> >
>
> Just thinking...
>
> - edit /etc/apt/sources.list and change all feisty entries to gutsy,
> also disable any third-party repos which may pose problems
>
> - then run...
>
> $sudo apt-get update && sudo apt-get dist-upgrade -d
>
> ...to download and not install any packages
>
> - edit /etc/apt/sources.list and change everything back to feisty from
> gutsy, leave third-party repos disabled
>
> - then run...
>
> $update-manager -d
>
> ...to start the upgrade with the update-manager and the now cached
> locally packaged. i doubt that will get everything though, there are
> bound to be some dependencies or new packages needed.
>
> -d
>
Thanks David,
That seems very reasonable.
One question though: My problem is that a few of the packages just
won't download when I use apt-get (or update-manager). For some
reason. But I can use wget. For some other reason (weird corporate
firewall/virus scanner maybe..)
So, after I have done
> $sudo apt-get update && sudo apt-get dist-upgrade -d
then I would like to add my *manually* downloaded packages to whatever
database the above command uses for keeping track of downloaded
packages.
I wonder if that "database" would be just "the deb-files located in
/var/cache/apt/archives/partial/" that Derek mentioned? Or if I have
to do something along the lines of
$ apt-cache --add-debs-to-whatever-has-been-downloaded-already ./debs/*.deb
Will try the /var/cache/apt/archives/partial/ stuff tomorrow (midnight
here now).
Best regards
Hugo Heden
More information about the ubuntu-users
mailing list