Why installing openjdk-7-jdk on Ubuntu Trusty installs systemd as well?

sktsee sktseer at gmail.com
Tue Jan 3 19:55:18 UTC 2017


On Tue, 03 Jan 2017 12:09:37 +0200, Yuri Kanivetsky wrote:

> In lxc containers you usually get pretty basic set of packages. For
> example, in Ubuntu Trusty man and curl packages are not "preinstalled".
> In other distributions there was no less and ping right away, AFAIR.
> 
> And AFAIU, lxc containers use kernel of the host machine. It's not that
> I see how it can affect installing openjdk in the guest. But it makes
> sense to check it with Virtualbox, after all. What I'm planning to do
> one of these days.

It's probably being pulled in as :Recommends dependency. If you specify 
"--no-install-recommends" with apt-get, it'll might leave systemd off. Of 
course, it will leave other recommended packages that you may want to be 
installed off as well. You'll just need to compare the output from the 
two simulated apt commands.

See what the following does:

$ sudo apt-get -s install --no-install-recommends openjdk-7-jdk

Also, if it looks like systemd is going to be installed regardless of the 
no-install-recommends option (some os components like udev rely on systemd 
functions), you could install the package systemd-shim to provide systemd 
functionality for systemd services without using it as the init service.

-- 
sktsee





More information about the ubuntu-users mailing list