APT 1.0 released

Chat about Linux in general

APT 1.0 released

Postby Monsta on Sun Apr 06, 2014 12:45 pm

On the April 1st, without any joking, Debian developers released APT version 1.0.

One of the new features is the new apt binary:

The big news for this version is that we included a new “apt” binary that combines the most commonly used commands from apt-get and apt-cache. The commands are the same as their apt-get/apt-cache counterparts but with slightly different configuration options.

Currently the apt binary supports the following commands:

  • list: which is similar to dpkg list and can be used with flags like
    --installed or --upgradable.
  • search: works just like apt-cache search but sorted alphabetically.
  • show: works like apt-cache show but hide some details that people are less likely to care about (like the hashes). The full record is still available via apt-cache show of course.
  • update: just like the regular apt-get update with color output enabled.
  • install,remove: adds progress output during the dpkg run.
  • upgrade: the same as apt-get dist-upgrade –with-new-pkgs.
  • full-upgrade: a more meaningful name for dist-upgrade.
  • edit-sources: edit sources.list using $EDITOR.


Some of you might be aware that Linux Mint already includes the convenient script also named apt that has the same goal: to provide simple access to various apt-related commands.
The difference is:

  • Mint's script resides in /usr/local/bin while Debian's apt binary is in /usr/bin. Since /usr/local/bin usually comes first in the $PATH, when you simply run "apt" in the terminal, Mint's script will be executed.
  • Mint's script has more options.
  • Mint's script uses not only apt-* tools (apt-cache, apt-get) but also aptitude.

News sources:
News article at Phoronix
The official release announcement at the mailing list
The announcement at Michael Vogt's blog
Monsta
Level 8
Level 8
 
Posts: 2417
Joined: Fri Aug 19, 2011 3:46 am

Linux Mint is funded by ads and donations.
 

Re: APT 1.0 released

Postby xenopeek on Sun Apr 06, 2014 3:47 pm

I'd see it pop up on my news feed, but hadn't read it yet. Looks handy, but as usual Linux Mint developers have already done something to patch the weirdness of needing apt-get/apt-cache/dpkg/aptitude for package management :)
User avatar
xenopeek
Level 21
Level 21
 
Posts: 14735
Joined: Wed Jul 06, 2011 3:58 am
Location: The Netherlands

Re: APT 1.0 released

Postby killer de bug on Wed Apr 09, 2014 3:41 am

Monsta wrote:[*] upgrade: the same as apt-get dist-upgrade –with-new-pkgs.


I may be misreading this... but does it mean apt update is performing a dist-upgrade?


Monsta wrote:[*] full-upgrade: a more meaningful name for dist-upgrade.


Changing the name of a well-known command is not that clever. :lol:
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby killer de bug on Wed Apr 09, 2014 3:49 am

Ok I got an answer in Michael Vogt's blog:

The first is the new parameter “–with-new-pkgs” for the upgrade
command:

# apt-get upgrade --with-new-pkgs

that will install new dependencies on the upgrade but never remove
packages. A typical use-case is a stable system that gets a kernel
with a new kernel ABI package.


So it's no more an apt-get upgrade but it's not a dist-upgrade since it's unable to remove packages :lol:
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby palo on Fri Jul 25, 2014 7:06 am

I had been using apt upgrade as a safe way to update everything except the kernel (as kernel updates sometimes upset VBox). Now I am finding the function has changed (Qiana) and the kernel gets updated as it would with dist-upgrade pre- APT 1.0.

killer de bug wrote:Changing the name of a well-known command is not that clever.


Argh!

So I guess the best way to upgrade as before excluding kernel would be to pin the pkgs normally held back previously:

The following packages have been kept back:
linux-generic linux-headers-generic linux-image-generic

Or is there a better way?
~/mintmaya/xfce/enlightenment
Help Vampires: A Spotter's Guide
User avatar
palo
Level 4
Level 4
 
Posts: 449
Joined: Mon Jun 25, 2012 7:28 am
Location: Walking on sunshine

Re: APT 1.0 released

Postby Monsta on Fri Jul 25, 2014 8:26 am

palo wrote:I had been using apt upgrade

Post the output of:
Code: Select all
which apt
Monsta
Level 8
Level 8
 
Posts: 2417
Joined: Fri Aug 19, 2011 3:46 am

Re: APT 1.0 released

Postby palo on Fri Jul 25, 2014 11:10 am

Monsta wrote:
palo wrote:I had been using apt upgrade

Post the output of:
Code: Select all
which apt


Interesting
Maya - /usr/bin/apt
Qiana - /usr/local/bin/apt
~/mintmaya/xfce/enlightenment
Help Vampires: A Spotter's Guide
User avatar
palo
Level 4
Level 4
 
Posts: 449
Joined: Mon Jun 25, 2012 7:28 am
Location: Walking on sunshine

Re: APT 1.0 released

Postby killer de bug on Fri Jul 25, 2014 11:27 am

Monsta wrote:
  • Mint's script resides in /usr/local/bin while Debian's apt binary is in /usr/bin. Since /usr/local/bin usually comes first in the $PATH, when you simply run "apt" in the terminal, Mint's script will be executed.


:wink:
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby palo on Fri Jul 25, 2014 7:56 pm

killer de bug wrote:
Monsta wrote:
  • Mint's script resides in /usr/local/bin while Debian's apt binary is in /usr/bin. Since /usr/local/bin usually comes first in the $PATH, when you simply run "apt" in the terminal, Mint's script will be executed.


:wink:


Drifting a little off point (for my question anyway) but that statement would appear to be incorrect if (for Maya) "which apt" is saying /usr/bin/apt is being used but there is in fact apt in /usr/local/bin

whereis apt (both Maya and Qiana)
apt: /usr/bin/apt /etc/apt /usr/lib/apt /usr/bin/X11/apt /usr/local/bin/apt /usr/share/apt /usr/share/man/man8/apt.8.gz /usr/share/man/man1/apt.1.gz


I am not really understanding how that relates to the new function of APT 1.0 apt-upgrade and the kernel updates.
~/mintmaya/xfce/enlightenment
Help Vampires: A Spotter's Guide
User avatar
palo
Level 4
Level 4
 
Posts: 449
Joined: Mon Jun 25, 2012 7:28 am
Location: Walking on sunshine

Re: APT 1.0 released

Postby killer de bug on Sat Jul 26, 2014 4:10 am

What is important for you to understand is that (for whatever reason) you are not using the same tool anymore. In Maya you were using the official apt tool but now in Qiana you are using the version coming from Linux Mint (which seems logic for me). And the two tools are not working exactly in the same way.

This said, apt upgrade has never been able to install a new kernel (and it is still not if you don't add something to the command) -- it can't install the 3.14 kernel if you have the 3.13 -- but apt upgrade can install a never version of your current kernel -- 3.13.10 if you have 3.13.2...--.
I think that you are confused at the moment, because a few kernel security fixes are available. And that's why you think apt upgrade try to install a new kernel... :wink:
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby Monsta on Sat Jul 26, 2014 5:51 am

palo wrote:Maya - /usr/bin/apt

It shouldn't be so. Did you remove mintSystem, by any chance?
Post the output of:
Code: Select all
apt policy mintsystem
Code: Select all
apt contains /usr/bin/apt


killer de bug wrote:In Maya you were using the official apt tool

APT 1.0 hadn't been released for Maya, so /usr/bin/apt shouldn't be there.
Monsta
Level 8
Level 8
 
Posts: 2417
Joined: Fri Aug 19, 2011 3:46 am

Re: APT 1.0 released

Postby killer de bug on Sat Jul 26, 2014 6:02 am

Palo,

could you please post the content of the apt file you have in Maya (/usr/bin/apt)?
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby PatH57 on Sat Jul 26, 2014 6:06 am

seems it is a new tool and we will need a bit of time to get used to it
as long as I understand what it is doing I can decide to use it or not, just naming convention could have been "better"
People disagree with me. I just ignore them.
(Linus Torvalds, regarding the use of C++ for the Linux kernel.)

Please Add [Solved] to the topic-title of your first post when appropriate so others know they might find a solution here.
User avatar
PatH57
Level 11
Level 11
 
Posts: 3631
Joined: Tue Mar 25, 2014 12:11 pm
Location: here and there

Re: APT 1.0 released

Postby killer de bug on Sat Jul 26, 2014 6:07 am

On a normal Linux Mint system, this tool should not be easily usable. We have already a home made 'apt' and it's more powerful ;)

if you want to understand what is apt, read this: viewtopic.php?f=90&t=119366#p658469
Last edited by killer de bug on Sat Jul 26, 2014 6:40 am, edited 1 time in total.
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby PatH57 on Sat Jul 26, 2014 6:33 am

totally agree it just the naming does remind some MS stuff and I'm sure I "would click" on it and then complain after :lol:
People disagree with me. I just ignore them.
(Linus Torvalds, regarding the use of C++ for the Linux kernel.)

Please Add [Solved] to the topic-title of your first post when appropriate so others know they might find a solution here.
User avatar
PatH57
Level 11
Level 11
 
Posts: 3631
Joined: Tue Mar 25, 2014 12:11 pm
Location: here and there

Re: APT 1.0 released

Postby palo on Sat Jul 26, 2014 7:10 am

killer de bug wrote:What is important for you to understand is that (for whatever reason) you are not using the same tool anymore.


Got it. Maya uses APT 0.8.16 and Qiana uses Apt 1.0.1 - The frustration/confusion lies in the fact that the command I used to update everything but the kernel does not do that anymore (best alternative wanted).

killer de bug wrote:This said, apt upgrade has never been able to install a new kernel (and it is still not if you don't add something to the command) -- it can't install the 3.14 kernel if you have the 3.13 -- but apt upgrade can install a never version of your current kernel -- 3.13.10 if you have 3.13.2...--.


If I said anything about "install a new kernel" it was a slip - this is about updating.

In Maya my kernel is 3.2.0.23.25 and the newer version 3.2.0.67.79 is held back if I run apt upgrade.
In Qiana my kernel is 3.13.0-24.46 and the newer version 3.13.0-24.47 will be updated if I run apt upgrade.

killer de bug wrote:I think that you are confused at the moment


Yep. Thankfully there are some around here able and willing to set me straight.

The question remains - best way to get the same results with the new tool.

Monsta wrote:
palo wrote:Maya - /usr/bin/apt

It shouldn't be so. Did you remove mintSystem, by any chance?
Post the output of:
Code: Select all
apt policy mintsystem
Code: Select all
apt contains /usr/bin/apt


killer de bug wrote:In Maya you were using the official apt tool

APT 1.0 hadn't been released for Maya, so /usr/bin/apt shouldn't be there.


I did not remove mintSystem.

apt policy mintsystem
mintsystem:
Installed: 7.8.3
Candidate: 7.8.3
Version table:
*** 7.8.3 0
700 http://mirror.metrocast.net/linuxmint-packages/ maya/main i386 Packages
100 /var/lib/dpkg/status

apt contains /usr/bin/apt
dpkg-query: no path found matching pattern /usr/bin/apt.

killer de bug wrote:Palo,

could you please post the content of the apt file you have in Maya (/usr/bin/apt)?


That is a link - /etc/alternatives/apt
~/mintmaya/xfce/enlightenment
Help Vampires: A Spotter's Guide
User avatar
palo
Level 4
Level 4
 
Posts: 449
Joined: Mon Jun 25, 2012 7:28 am
Location: Walking on sunshine

Re: APT 1.0 released

Postby killer de bug on Sat Jul 26, 2014 7:23 am

palo wrote:That is a link - /etc/alternatives/apt

Then, can you please post the output of this new file?
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby palo on Sat Jul 26, 2014 8:39 am

killer de bug wrote:
palo wrote:That is a link - /etc/alternatives/apt

Then, can you please post the output of this new file?



That links to /usr/lib/jvm/java-7-oracle/bin/apt and this is what that looks like to me:
Attachments
apt-Maya.png
~/mintmaya/xfce/enlightenment
Help Vampires: A Spotter's Guide
User avatar
palo
Level 4
Level 4
 
Posts: 449
Joined: Mon Jun 25, 2012 7:28 am
Location: Walking on sunshine

Re: APT 1.0 released

Postby killer de bug on Sat Jul 26, 2014 11:51 am

palo wrote:That links to /usr/lib/jvm/java-7-oracle/bin/apt and this is what that looks like to me:


This is rather unexpected and interesting... I guess you installed Java 7 and it provides a script to update itself? Monsta we need your knowledge here :D
If I have seen further it is by standing on the shoulders of giants. [Isaac Newton]
User avatar
killer de bug
Level 7
Level 7
 
Posts: 1758
Joined: Tue Jul 08, 2008 1:49 pm
Location: Austria

Re: APT 1.0 released

Postby palo on Sat Jul 26, 2014 6:36 pm

I think the apt upgrade command is working in Qiana as it was in Maya with pinning as described in the Blocking packages with APT/DPKG section here. So I now have this output:
Code: Select all
pat-M17Xfce2 ~ # apt upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  linux-headers-3.13.0-24 linux-headers-3.13.0-24-generic
  linux-image-3.13.0-24-generic linux-image-extra-3.13.0-24-generic
The following packages will be upgraded:
  base-files dbus dbus-x11 gir1.2-gudev-1.0 grub-common grub-pc grub-pc-bin
  grub2-common libdbus-1-3 libegl1-mesa libegl1-mesa-drivers libgbm1
  libgl1-mesa-dri libgl1-mesa-glx libglapi-mesa libgles2-mesa libgudev-1.0-0
  libopenvg1-mesa libpam-systemd libsystemd-daemon0 libsystemd-login0 libudev1
  libwayland-egl1-mesa libxatracker2 linux-firmware linux-libc-dev
  systemd-services udev upstart xserver-xorg-video-ati
  xserver-xorg-video-radeon
31 upgraded, 0 newly installed, 0 to remove and 4 not upgraded.
Need to get 33.2 MB of archives.
After this operation, 5,721 kB of additional disk space will be used.
Do you want to continue? [Y/n]


The linux-image-extra-x-generic is something new to me but then it may have been there after Maya. This also blocks those updates from showing in the Update Manager so I guess level 4&5 updates can be checked and the kernel can be untouched.

Still feeling my way around this.

Edit: killer you are correct about Java

Update: I tried other methods of doing the same and found that holding packages in the Update Manager is a bit odd. After opening Update Manager I can mark packages to hold as an unprivileged user (ie no authentication required). Password is required only to perform the updates - this seems flawed. I would have expected to need a password to do anything in the Update Manager.
~/mintmaya/xfce/enlightenment
Help Vampires: A Spotter's Guide
User avatar
palo
Level 4
Level 4
 
Posts: 449
Joined: Mon Jun 25, 2012 7:28 am
Location: Walking on sunshine

Linux Mint is funded by ads and donations.
 
Next

Return to Chat about Linux

Who is online

Users browsing this forum: No registered users and 7 guests