Saturday, November 2, 2019

do-release-upgrade --quiet / -q No definition of what it does



Does anybody know what do-release-upgrade -q actually does?




Hopefully it does the upgrade without the need to interact with it, if this is the case does it overwrite configs or keep the originals?, or does it do something else?



stephenm@mcr-pc-29392:~$ do-release-upgrade --help
Usage: do-release-upgrade [options]

Options:
-h, --help show this help message and exit
-V, --version Show version and exit
-d, --devel-release Check if upgrading to the latest devel release is

possible
--data-dir=DATA_DIR Directory that contains the data files
-p, --proposed Try upgrading to the latest release using the upgrader
from $distro-proposed
-m MODE, --mode=MODE Run in a special upgrade mode. Currently 'desktop' for
regular upgrades of a desktop system and 'server' for
server systems are supported.
-f FRONTEND, --frontend=FRONTEND
Run the specified frontend
-s, --sandbox Test upgrade with a sandbox aufs overlay

-c, --check-dist-upgrade-only
Check only if a new distribution release is available
and report the result via the exit code
-q, --quiet


The man page does not even mention it.



DO-RELEASE-UPGRADE(8)                                                                                                  DO-RELEASE-UPGRADE(8)


NAME
do-release-upgrade - upgrade operating system to latest release

SYNOPSIS
do-release-upgrade [options]

DESCRIPTION
Upgrade the operating system to the latest release from the command-line. This is the preferred command if the machine has no
graphic environment or if the machine is to be upgraded over a remote connection.


OPTIONS
-h, --help
show help message and exit

-d, --devel-release
Check if upgrading to the latest devel release is possible

-p, --proposed
Try upgrading to the latest release using the upgrader from Ubuntu-proposed


-m MODE, --mode=MODE
Run in a special upgrade mode. Currently "desktop" for regular upgrades of a desktop system and "server" for server systems
are supported.

-f FRONTEND, --frontend=FRONTEND
Run the specified frontend

-s, --sandbox
Test upgrade with a sandbox aufs overlay


SEE ALSO
update-manager(8), apt-get(8)


Okay so I looked into this by testing it, I Installed a virtual Ubuntu 10.04 edited some config files and ran do-release-upgrade -q,



It ran exactly the same I had all the same questions to answer regarding mysql passwords, and modified configs.



This led me to look at the code to figure what it exactly does. The code for do-release-upgrade is here




Looking through it looks like using the -q option simply omits a tiny bit of output.



This is the only stuff it omits as far as I can tell.



if not options.quiet:
print _("Checking for a new ubuntu release")


..




if not options.quiet:
print _("No new release found")


...



if not options.quiet:
print _("Release upgrade not possible right now")
print _("The release upgrade can not be performed currently, "
"please try again later. The server reported: '%s'") % m.new_dist.upgrade_broken

sys.exit(NO_RELEASE_AVAILABLE)


It looks like this does nothing else other than omit the above output, which in the grand scheme of the upgrade output is minute to say the least.


No comments:

Post a Comment

11.10 - Can't boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...