Skip to content

Upgrading R packages on Etch

9 messages · Michael Dewey, Dirk Eddelbuettel, Johannes Ranke +2 more

#
Greetings,
I've been trying to upgrade R packages on my Debian Etch
(whose other upgrades I have been cheerfully going along
with as they occur).

When I did, just now:

  sudo apt-get dist-upgrade

I got:

  Reading package lists... Done
  Building dependency tree... Done
  Calculating upgrade... Done
  The following packages have been kept back:
    r-base-core r-cran-boot r-cran-cluster r-cran-codetools
    r-cran-kernsmooth r-cran-lattice r-cran-matrix r-cran-mgcv
    r-cran-nlme r-cran-rpart r-cran-survival r-cran-vr
    r-recommended
  0 upgraded, 0 newly installed, 0 to remove and 13 not upgraded.

And the same failure to install these R packages occurs when I
try it from the update-manager or from synaptic.

In short, it's not going to upgrade any of those!

I can't find any indication of a reason why it won't upgrade
these, beyond the following message from update-manager:

  Some updates require the removal of further software.
  Use the function "Mark All Upgrades" of the package manager
  "Synaptic" or run "sudo apt-get dist-upgrade" in a terminal
  to update your system completely.

  The following upgrades will be skipped:
  [Same list as above]

The "Mark All Upgrades" suggestion for synaptic didn't seem
to do anything.

So I'm stuck. Any advice/information/suggestions?

PS: I am *very reluctant* to attempt replacing my Debian Etch
with Debian Lenny (the latest). This system works as it is!
Also, I am not an in-depth expert on how Debian's package
management works.

With thanks,
Ted.

--------------------------------------------------------------------
E-Mail: (Ted Harding) <Ted.Harding at manchester.ac.uk>
Fax-to-email: +44 (0)870 094 0861
Date: 10-Nov-09                                       Time: 08:39:56
------------------------------ XFMail ------------------------------
#
At 08:39 10/11/2009, Ted Harding wrote:

            
I am not sure this is going to be helpful but I only ever upgrade R 
itself on my etch system on my netbook and have not had any problems 
so far. I upgraded to R 2.10.0 earlier today and have a working 
system. I do not do the complete upgrade because it asks for more 
disc space than I have on the netbook.
Michael Dewey
http://www.aghmed.fsnet.co.uk
#
On Tue, Nov 10, 2009 at 2:39 AM, Ted Harding
<Ted.Harding at manchester.ac.uk> wrote:
[snip]
I suppose the easiest first step is to run apt-get with the --verbose option.

Here is what I would do (old school approach).

Download the deb files in question.
they may already be downloaded, in /var/cache/apt somewhere

then try to manually install them with "dpkg -i *.deb"

The errors you get will be much more informative.

My old man opinion has always been that apt-get tries to make this too
simple.  It is virtually certain that those R debs were built with
different shared libraries than you have, and for your system there
are no appropriate updates for those shared libraries. So the r
packages are held back, but they don't say why.

If you don't want to upgrade your system's shared libraries, it may be
 you can build your own R with the libraries you have.  The way to try
 is to do "apt-get source  r" (or whatever the R package is called) to
get the source code and debian packaging, and see if you can build
packages for your system by running "dpkg-buildpackage -rfakeroot" in
the directory where it has downloaded the code.  apt-get source will
grab the original tarball, the diff file, open the code, patch it, so
it is literally waiting there for you to try to build it.

And the errors you get there will be very informative.
#
Ted,
On 10 November 2009 at 08:39, (Ted Harding) wrote:
| Greetings,
| I've been trying to upgrade R packages on my Debian Etch
| (whose other upgrades I have been cheerfully going along
| with as they occur).
| 
| When I did, just now:
| 
|   sudo apt-get dist-upgrade
| 
| I got:
| 
|   Reading package lists... Done
|   Building dependency tree... Done
|   Calculating upgrade... Done
|   The following packages have been kept back:
|     r-base-core r-cran-boot r-cran-cluster r-cran-codetools
|     r-cran-kernsmooth r-cran-lattice r-cran-matrix r-cran-mgcv
|     r-cran-nlme r-cran-rpart r-cran-survival r-cran-vr
|     r-recommended
|   0 upgraded, 0 newly installed, 0 to remove and 13 not upgraded.
| 
| And the same failure to install these R packages occurs when I
| try it from the update-manager or from synaptic.
| 
| In short, it's not going to upgrade any of those!
| 
| I can't find any indication of a reason why it won't upgrade
| these, beyond the following message from update-manager:
| 
|   Some updates require the removal of further software.
|   Use the function "Mark All Upgrades" of the package manager
|   "Synaptic" or run "sudo apt-get dist-upgrade" in a terminal
|   to update your system completely.
| 
|   The following upgrades will be skipped:
|   [Same list as above]
| 
| The "Mark All Upgrades" suggestion for synaptic didn't seem
| to do anything.
| 
| So I'm stuck. Any advice/information/suggestions?

Use a different command if the one you currently use hides information from
you, so try 'sudo apt-get install r-base-core'. That _will_ show the cause,
and you _still_ have a chance to back out by saying 'No' to the 'do you
really want to do this' question.

| PS: I am *very reluctant* to attempt replacing my Debian Etch
| with Debian Lenny (the latest). This system works as it is!
| Also, I am not an in-depth expert on how Debian's package
| management works.

You are of course entitled to your very own paranoia.  Some people are afraid
of the dark, others are afraid of spiders etc pp. Do we consider any of those
fears to be reasonable?

More seriously, the point of the CRAN backports is _precisely_ to give you
current R versions without scaring you and the little children standing
behind you as it won't require lenny.

Deal?

Dirk, who upgrades his Debian testing system daily
#
On 10 November 2009 at 12:17, Paul Johnson wrote:
| Here is what I would do (old school approach).
| 
| Download the deb files in question.
| they may already be downloaded, in /var/cache/apt somewhere
| 
| then try to manually install them with "dpkg -i *.deb"
| 
| The errors you get will be much more informative.

Correct.

| My old man opinion has always been that apt-get tries to make this too
| simple.  It is virtually certain that those R debs were built with
| different shared libraries than you have, and for your system there

I object to this characterisation.  The backports on CRAN are built using the
best available tools, and this includes chroot / pbuilder environments with
the proper libraries.  Johannes (for Debian) and Vincent / Michael (for
Ubuntu) deserve better for their work than statements like that.

| are no appropriate updates for those shared libraries. So the r
| packages are held back, but they don't say why.
| 
| If you don't want to upgrade your system's shared libraries, it may be
|  you can build your own R with the libraries you have.  The way to try
|  is to do "apt-get source  r" (or whatever the R package is caelled) to

That is generally true and fair advice. I often go this route when _backports
are not available_ but in this case they are.  Hence no need for from-source
rebuilds.  

| get the source code and debian packaging, and see if you can build
| packages for your system by running "dpkg-buildpackage -rfakeroot" in
| the directory where it has downloaded the code.  apt-get source will
| grab the original tarball, the diff file, open the code, patch it, so
| it is literally waiting there for you to try to build it.

apt-get can actually build the package for you too, see the 
'man apt-get' about the --compile option.

Dirk
#
Hi,

I would just like to second Dirks comments. Especially I would like to see 
what happens if you

...
Kind regards,

Johannes
#
On Tue, Nov 10, 2009 at 2:39 AM, Ted Harding
<Ted.Harding at manchester.ac.uk> wrote:
Hey, Ted:

Did you get to the bottom of this?

I got an email responding to my post in this thread that said it
seemed I was criticizing the people who make the packages.  I didn't
mean that at all and I'm sorry.

I mean that if there is a mismatch between the libraries you happen to
have on your particular system and the "standard" system that the
packager is using (and aiming at, doing things correctly), then it can
cause the exact problem  you are seeing.

I also agree with the post which says that you will get more
information about the possible library mismatch if you do

apt-get upgrade r-base-core

Also, as he says, there's a good chance that if you enable the
backports repository, there will be a version of the new R for the
libraries that might exist in the older Linux.

To me, the big uncertainty is whether your system is still in a
"standard" state, so that the repository packages will work.  If not,
you may need to rebuild the packages custom for your system.
#
On 10-Nov-09 20:37:48, Johannes Ranke wrote:
Well, I tried that, first on r-base-core. Got no warnings, so
I went ahead and accepted to proceed. There was a warning that
it "could not be authenticated", but I'm used to that and so
answered "Y". It then downloaded and duly replaced my r-base-core.

Since that apparently went well, I then did exactly the same
(with exactly the same results) for each of the other packages
that aptitude/update-manager etc. had turned up their noses at
previously:

    r-base-core r-cran-boot r-cran-cluster r-cran-codetools
    r-cran-kernsmooth r-cran-lattice r-cran-matrix r-cran-mgcv
    r-cran-nlme r-cran-rpart r-cran-survival r-cran-vr
    r-recommended

I haven't tested it all out yet, so my fingers are still crossed.
But, presuming it will work, I have to say that I'm grateful
for the help and guidance on this question. And it confirms
what should probably be a better way to go in future.

But it leaves dangling the question: Why wouldn't it work in
the first place? Using the 'sudo' route did not reveal any
cause of why it would not work before!

With thanks to all,
Ted.

--------------------------------------------------------------------
E-Mail: (Ted Harding) <Ted.Harding at manchester.ac.uk>
Fax-to-email: +44 (0)870 094 0861
Date: 10-Nov-09                                       Time: 22:43:27
------------------------------ XFMail ------------------------------
#
Hallo again,

I am glad you got the packages installed, although I would also like to know 
what was the problem in the first place. By the way, I think using "sudo" 
really is not necessary on a Debian system, as I am assuming you operated 
using the root account anyway. This just came into it because Dirk is more 
used to helping Ubuntu users and uses Ubuntu himself, too.

After install r-base-core, simply typing

	apt-get install r-recommended

as root should definitely have pulled in all all the dependencies of r-
recommended (r-cran-cluster, r-cran-codetools, ...).

If anyone observes similar phenomena as Ted, please report.

Kind regards,

Johannes



Am Mittwoch, 11. November 2009 13:32:03 schrieb Ted Harding: