Changeset View
Standalone View
UPDATING
Show First 20 Lines • Show All 2,274 Lines • ▼ Show 20 Lines | COMMON ITEMS: | ||||
1.) recompile and reinstall the ZFS boot loader and boot block | 1.) recompile and reinstall the ZFS boot loader and boot block | ||||
(this is part of "make buildworld" and "make installworld") | (this is part of "make buildworld" and "make installworld") | ||||
2.) update the ZFS boot block on your boot drive | 2.) update the ZFS boot block on your boot drive | ||||
The following example updates the ZFS boot block on the | The following example updates the ZFS boot block on the | ||||
freebsd-boot partition of a GPT partitioned drive ada0: | freebsd-boot partition of a GPT partitioned drive ada0: | ||||
"gpart bootcode -p /boot/gptzfsboot -i $N ada0" | "gpart bootcode -p /boot/gptzfsboot -i $N ada0" | ||||
The value $N will typically be 1 (if booting from BIOS) or 2 (if | The value $N will typically be 1 (if booting from BIOS) or 2 (if | ||||
grahamperrin: if there is no EFI system partition | |||||
Not Done Inline ActionsNo. ****N E V E R **** use gpart bootcode on a UEFI system. It's always wrong now. imp: No. ****************N E V E R **************** use gpart bootcode on a UEFI system. It's always… | |||||
booting from EFI). | booting from EFI). | ||||
Non-boot pools do not need these updates. | Non-boot pools do not need these updates. | ||||
To build a kernel | To build a kernel | ||||
----------------- | ----------------- | ||||
If you are updating from a prior version of FreeBSD (even one just | If you are updating from a prior version of FreeBSD (even one just | ||||
a few days old), you should follow this procedure. It is the most | a few days old), you should follow this procedure. It is the most | ||||
Show All 15 Lines | COMMON ITEMS: | ||||
----------------------------------------------------------- | ----------------------------------------------------------- | ||||
# Note: sometimes if you are running current you gotta do more than | # Note: sometimes if you are running current you gotta do more than | ||||
# is listed here if you are upgrading from a really old current. | # is listed here if you are upgrading from a really old current. | ||||
<make sure you have good level 0 dumps> | <make sure you have good level 0 dumps> | ||||
make buildworld | make buildworld | ||||
make buildkernel KERNCONF=YOUR_KERNEL_HERE | make buildkernel KERNCONF=YOUR_KERNEL_HERE | ||||
make installkernel KERNCONF=YOUR_KERNEL_HERE | make installkernel KERNCONF=YOUR_KERNEL_HERE | ||||
[1] | [1] | ||||
Done Inline ActionsMove up, to be inline. grahamperrin: Move up, to be inline. | |||||
Done Inline ActionsIt is intended like this so that it is not associated with make installkernel, it is seen as a seperate step between installkernel and reboot to single user mode. driesm: It is intended like this so that it is not associated with make installkernel, it is seen as a… | |||||
<reboot in single user> [3] | <reboot in single user> [3] | ||||
Done Inline ActionsRemove white space. grahamperrin: Remove white space. | |||||
mergemaster -Fp [5] | etcupdate -p [5] | ||||
make installworld | make installworld | ||||
mergemaster -Fi [4] | etcupdate -B [4] | ||||
make delete-old [6] | make delete-old [6] | ||||
<reboot> | <reboot> | ||||
To cross-install current onto a separate partition | To cross-install current onto a separate partition | ||||
-------------------------------------------------- | -------------------------------------------------- | ||||
# In this approach we use a separate partition to hold | # In this approach we use a separate partition to hold | ||||
# current's root, 'usr', and 'var' directories. A partition | # current's root, 'usr', and 'var' directories. A partition | ||||
# holding "/", "/usr" and "/var" should be about 2GB in | # holding "/", "/usr" and "/var" should be about 2GB in | ||||
Show All 17 Lines | COMMON ITEMS: | ||||
To upgrade in-place from stable to current | To upgrade in-place from stable to current | ||||
---------------------------------------------- | ---------------------------------------------- | ||||
<make sure you have good level 0 dumps> | <make sure you have good level 0 dumps> | ||||
make buildworld [9] | make buildworld [9] | ||||
make buildkernel KERNCONF=YOUR_KERNEL_HERE [8] | make buildkernel KERNCONF=YOUR_KERNEL_HERE [8] | ||||
make installkernel KERNCONF=YOUR_KERNEL_HERE | make installkernel KERNCONF=YOUR_KERNEL_HERE | ||||
[1] | [1] | ||||
Done Inline ActionsMove up, to be inline. grahamperrin: Move up, to be inline. | |||||
<reboot in single user> [3] | <reboot in single user> [3] | ||||
Done Inline ActionsRemove white space. grahamperrin: Remove white space. | |||||
mergemaster -Fp [5] | etcupdate -p [5] | ||||
make installworld | make installworld | ||||
mergemaster -Fi [4] | etcupdate -B [4] | ||||
make delete-old [6] | make delete-old [6] | ||||
Done Inline ActionsI know that deleting old libraries can cause breakage (if performed carelessly). Is there also risk of breakage for delete-old – without attention to libraries? I routinely: make -DBATCH_DELETE_OLD_FILES delete-old – and never encountered breakage. Touch wood. grahamperrin: I know that deleting old //libraries// can cause breakage (if performed carelessly).
Is there… | |||||
Done Inline ActionsI'm trying to focus this review on mergemsater => Etcupdate. I've already folded in one unrelated change. I hope you understand. driesm: I'm trying to focus this review on mergemsater => Etcupdate. I've already folded in one… | |||||
<reboot> | <reboot> | ||||
Make sure that you've read the UPDATING file to understand the | Make sure that you've read the UPDATING file to understand the | ||||
tweaks to various things you need. At this point in the life | tweaks to various things you need. At this point in the life | ||||
cycle of current, things change often and you are on your own | cycle of current, things change often and you are on your own | ||||
to cope. The defaults can also change, so please read ALL of | to cope. The defaults can also change, so please read ALL of | ||||
the UPDATING entries. | the UPDATING entries. | ||||
Also, if you are tracking -current, you must be subscribed to | Also, if you are tracking -current, you must be subscribed to | ||||
freebsd-current@freebsd.org. Make sure that before you update | freebsd-current@freebsd.org. Make sure that before you update | ||||
your sources that you have read and understood all the recent | your sources that you have read and understood all the recent | ||||
messages there. If in doubt, please track -stable which has | messages there. If in doubt, please track -stable which has | ||||
much fewer pitfalls. | much fewer pitfalls. | ||||
[1] If you have third party modules, such as vmware, you should disable | [1] If you have third party modules, such as vmware, you should disable | ||||
them at this point so they don't crash your system on | them at this point so they don't crash your system on | ||||
reboot. Alternatively, you should rebuild all the modules you have in | reboot. Alternatively, you should rebuild all the modules you have in | ||||
your system and install them as well. If you are running -current, you | your system and install them as well. If you are running -current, you | ||||
should seriously consider placing all sources to all the modules for | should seriously consider placing all sources to all the modules for | ||||
your system (or symlinks to them) in /usr/local/sys/modules so this | your system (or symlinks to them) in /usr/local/sys/modules so this | ||||
happens automatically. If all your modules come from ports, then adding | happens automatically. If all your modules come from ports, then adding | ||||
the port origin directories to PORTS_MODULES instead is also automatic | the port origin directories to PORTS_MODULES instead is also automatic | ||||
and effective, eg: | and effective, eg: | ||||
PORTS_MODULES+=x11/nvidia-driver | PORTS_MODULES+=x11/nvidia-driver | ||||
Done Inline ActionsTake this opportunity to renumber 3, 4, 5, 6, 8 and 9, and the referring points? (There is no footnote 2 or 7.) Then – order – begin the points, and their footnotes, at 1 instead of 7. grahamperrin: Take this opportunity to renumber 3, 4, 5, 6, 8 and 9, and the referring points?
(There is no… | |||||
Done Inline ActionsI'm trying to focus this review on mergemsater => Etcupdate. I've already folded in one unrelated change. I hope you understand. driesm: I'm trying to focus this review on mergemsater => Etcupdate. I've already folded in one… | |||||
[3] From the bootblocks, boot -s, and then do | [3] From the bootblocks, boot -s, and then do | ||||
fsck -p | fsck -p | ||||
mount -u / | mount -u / | ||||
mount -a | mount -a | ||||
sh /etc/rc.d/zfs start # mount zfs filesystem, if needed | sh /etc/rc.d/zfs start # mount zfs filesystem, if needed | ||||
cd src # full path to source | cd src # full path to source | ||||
adjkerntz -i # if CMOS is wall time | adjkerntz -i # if CMOS is wall time | ||||
Also, when doing a major release upgrade, it is required that you boot | Also, when doing a major release upgrade, it is required that you boot | ||||
into single user mode to do the installworld. | into single user mode to do the installworld. | ||||
[4] Note: This step is non-optional. Failure to do this step | [4] Note: This step is non-optional. Failure to do this step | ||||
can result in a significant reduction in the functionality of the | can result in a significant reduction in the functionality of the | ||||
system. Attempting to do it by hand is not recommended and those | system. Attempting to do it by hand is not recommended and those | ||||
that pursue this avenue should read this file carefully, as well | that pursue this avenue should read this file carefully, as well | ||||
as the archives of freebsd-current and freebsd-hackers mailing lists | as the archives of freebsd-current and freebsd-hackers mailing lists | ||||
for potential gotchas. The -U option is also useful to consider. | for potential gotchas. See etcupdate(8) for more information. | ||||
See mergemaster(8) for more information. | |||||
[5] Usually this step is a no-op. However, from time to time | [5] Usually this step is a no-op. However, from time to time | ||||
you may need to do this if you get unknown user in the following | you may need to do this if you get unknown user in the following | ||||
step. It never hurts to do it all the time. You may need to | step. | ||||
Done Inline Actions
This advice can actually break a system if the new etcupdate relies on behavior/code from the newly built world. Please remove this comment or add similar advice to the original advice, noting the potential pitfall of using etcupdate(8), which can be incompatible with the old installed world. ngie: > It never hurts to do it all the time.
This advice can actually break a system if the new… | |||||
Done Inline ActionsThis was also the case for mergemaster too. Oof... that was bad advice. ngie: This was also the case for mergemaster too. Oof... that was bad advice. | |||||
Done Inline ActionsSo the comment that was there before is also applicable for worlds after 20130425 and 20130430? As the message only hints for the pitfall if we are updating from before these revisions (the way I interpret it, possibly incorrect though). Or is it a possible pitfall in general? If so I would just drop the specific revisions mentioned there as its confusing. driesm: So the comment that was there before is also applicable for worlds after 20130425 and 20130430? | |||||
install a new mergemaster (cd src/usr.sbin/mergemaster && make | |||||
install) after the buildworld before this step if you last updated | |||||
from current before 20130425 or from -stable before 20130430. | |||||
Not Done Inline ActionsThis change is independent, but imho, not important enough to do as a separate commit. imp: This change is independent, but imho, not important enough to do as a separate commit. | |||||
[6] This only deletes old files and directories. Old libraries | [6] This only deletes old files and directories. Old libraries | ||||
can be deleted by "make delete-old-libs", but you have to make | can be deleted by "make delete-old-libs", but you have to make | ||||
sure that no program is using those libraries anymore. | sure that no program is using those libraries anymore. | ||||
[8] The new kernel must be able to run existing binaries used by an | [8] The new kernel must be able to run existing binaries used by an | ||||
installworld. When upgrading across major versions, the new kernel's | installworld. When upgrading across major versions, the new kernel's | ||||
configuration must include the correct COMPAT_FREEBSD<n> option for | configuration must include the correct COMPAT_FREEBSD<n> option for | ||||
existing binaries (e.g. COMPAT_FREEBSD11 to run 11.x binaries). Failure | existing binaries (e.g. COMPAT_FREEBSD11 to run 11.x binaries). Failure | ||||
to do so may leave you with a system that is hard to boot to recover. A | to do so may leave you with a system that is hard to boot to recover. A | ||||
GENERIC kernel will include suitable compatibility options to run | GENERIC kernel will include suitable compatibility options to run | ||||
binaries from older branches. Note that the ability to run binaries | binaries from older branches. Note that the ability to run binaries | ||||
from unsupported branches is not guaranteed. | from unsupported branches is not guaranteed. | ||||
Make sure that you merge any new devices from GENERIC since the | Make sure that you merge any new devices from GENERIC since the | ||||
last time you updated your kernel config file. Options also | last time you updated your kernel config file. Options also | ||||
change over time, so you may need to adjust your custom kernels | change over time, so you may need to adjust your custom kernels | ||||
for these as well. | for these as well. | ||||
[9] If CPUTYPE is defined in your /etc/make.conf, make sure to use the | [9] If CPUTYPE is defined in your /etc/make.conf, make sure to use the | ||||
"?=" instead of the "=" assignment operator, so that buildworld can | "?=" instead of the "=" assignment operator, so that buildworld can | ||||
override the CPUTYPE if it needs to. | override the CPUTYPE if it needs to. | ||||
MAKEOBJDIRPREFIX must be defined in an environment variable, and | MAKEOBJDIRPREFIX must be defined in an environment variable, and | ||||
not on the command line, or in /etc/make.conf. buildworld will | not on the command line, or in /etc/make.conf. buildworld will | ||||
warn if it is improperly defined. | warn if it is improperly defined. | ||||
Done Inline ActionsAdd white space between this line and the subheading that follows. grahamperrin: Add white space between this line and the subheading that follows. | |||||
FORMAT: | FORMAT: | ||||
This file contains a list, in reverse chronological order, of major | This file contains a list, in reverse chronological order, of major | ||||
breakages in tracking -current. It is not guaranteed to be a complete | breakages in tracking -current. It is not guaranteed to be a complete | ||||
list of such breakages, and only contains entries since September 23, 2011. | list of such breakages, and only contains entries since September 23, 2011. | ||||
If you need to see UPDATING entries from before that date, you will need | If you need to see UPDATING entries from before that date, you will need | ||||
to fetch an UPDATING file from an older FreeBSD release. | to fetch an UPDATING file from an older FreeBSD release. | ||||
Copyright information: | Copyright information: | ||||
Copyright 1998-2009 M. Warner Losh <imp@FreeBSD.org> | Copyright 1998-2009 M. Warner Losh <imp@FreeBSD.org> | ||||
Done Inline Actions1998–2021 grahamperrin: 1998–2021 | |||||
Done Inline ActionsI've not been the majority contributor since 2009. imp: I've not been the majority contributor since 2009. | |||||
Redistribution, publication, translation and use, with or without | Redistribution, publication, translation and use, with or without | ||||
modification, in full or in part, in any form or format of this | modification, in full or in part, in any form or format of this | ||||
document are permitted without further permission from the author. | document are permitted without further permission from the author. | ||||
THIS DOCUMENT IS PROVIDED BY WARNER LOSH ``AS IS'' AND ANY EXPRESS OR | THIS DOCUMENT IS PROVIDED BY WARNER LOSH ``AS IS'' AND ANY EXPRESS OR | ||||
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | ||||
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||||
Show All 13 Lines |
if there is no EFI system partition