wiki:jessie-upgrade-tech-notes

Version 16 (modified by Jamie McClelland, 8 years ago) ( diff )

--

Technical notes on upgrading from wheezy to jessie

Welcome to upgrade Saturday! Our plan is to upgrade all the moshes today.

Start by reviewing this page to familiarize yourself with the steps and the potential problems. Then, go to the upgrade page to see the list of servers. Edit the page and put your name next to the server you want to start with so we don't step on each other's toes. Then, when you are done, put a strike through the server to indicate that it is done. Feel free to work on a few at the same time.

Steps to take

  • Ensure current distribution is up to date:
    apt-get update
    apt-get dist-upgrade
    
  • Delete all files in /etc/apt/sources.list.d and /etc/apt/preferences.d (these are controlled by puppet and will be replaced when we next run puppet)
  • Edit /etc/apt/sources.list and change wheezy to jessie
  • Run: apt-get update to update to the current distribution
  • Run: apt-get install dpkg apt to update the package install tools
  • Run: apt-get install mysql-server to reduce mysql downtime
  • Run: apt-get install apache2 to reduce apache downtime
  • Run: apt-get install dovecot-core to reduce dovecot downtime
  • Run: apt-get upgrade to upgrade packages that don't have any new dependencies
  • Run: apt-get dist-upgrade to upgrade all packages
  • Install ruby-rgen
    apt-get install ruby-rgen
    
  • Delete /etc/puppet/puppet.conf
    rm -f /etc/puppet/puppet.conf
    
  • Run: freepuppet-run to update our configuration files
  • Run: apt-get update to refresh the package list
  • Run: apt-get dist-upgrade to pull in new packages based on puppet changes
  • Run: apt-get autoremove to remove any packages we no longer need
  • Run: deborphan look at additional unneeded packages
  • Run: apt-get purge $(deborphan) remove those unneeded packages.
  • Run: mf-turn-off-auto-fscks to ensure we don't have to wait for fsck's on reboot
  • Run: shutdown -h now to reboot the system (yes, we say "-h" which means halt, but our virtualization engine will detect that it is off and restart it for us)
  • Ensure that postgrey is running. If not:
    systemctl enable postgrey
    systemctl start postgrey
    

Errors and special situations

  • When upgrading phpmyadmin you will be asked if you want to create the phpmyadmin database. Answer Yes. When prompted for the admin password, open a new root terminal and copy and paste the password in /root/.my.cnf.
  • Apache has changed from reading /etc/apache2/conf.d to reading /etc/apache2/conf-enabled (which should contain symlinks to /etc/apache2/conf-available). Apache may warn:
    Directory /etc/apache2/conf.d is not empty - leaving as is
    Please note, that directory is considered obsolete and not read anymore by default
    
    Do a directory listing of /etc/apache2/conf.d. If the only files you see are phpmyadmin and maxclients.conf, you can safely: rm -rf /etc/apache2/conf.d. If you see other files, check to see if they have been properly added to /etc/apache2/conf-{available,enabled}.
  • Apache may also warn:
    AH00526: Syntax error on line 9 of /etc/apache2/mods-enabled/php5.conf:
    Invalid command 'Order', perhaps misspelled or defined by a module not included in the server configuration
    
  • This seems to be due to the order in which Apache and PHP is ugpraded. You can ignore it.
  • Apache may warn about:
    The SSLCertificateChainFile directive (/etc/apache2/sites-enabled/001-octavia.mayfirst.org.ssl.conf:29) is deprecated, SSLCertificateFile should be used instead
    
    Many of our members still use a ChainFile. Jaime is working on fixing those. You can safely ignore this.

Configuration files to keep

When upgrading, you will be prompted to overwrite some files. You generally want to install the package maintainer's version. If we need to modify the file - those modifications should be handled by puppet so you don't have to worry about them when upgrading.

The following are exceptions to this rule. For the following files, please keep the local version:

  • /etc/cron.d/awstats
  • /etc/default/grub
  • /var/log/sysstat: The newer version of sysstat asks that you delete the current files, do it
Note: See TracWiki for help on using the wiki.