Upgrade Debian 5 Lenny zu Debian 6 Squeeze

Ich habe mir gedacht das es an der Zeit ist das Update auf Debian Squeeze zu testen.

Gesagt getan, leider gab es nach dem Upgrade noch die ein oder andere Hürde zu nehmen, aber jetzt erst mal von Anfang an.

Beenden aller Dienste:

apache2ctl stop
mysqladmin shutdown -p
mysqladmin status -p

22:59 starten von jiffybox backup

23:30 Backup erfolgreich

7423:~# screen -list
There are screens on:
25073.ftp (05/29/2012 11:35:12 PM) (Detached)
24796.mysql (05/29/2012 11:02:47 PM) (Detached)
24758.upgrade (05/29/2012 10:58:14 PM) (Detached)
17374.php (05/29/2012 02:03:39 PM) (Detached)
386.backup (05/27/2012 09:12:55 PM) (Detached)
31552.piwik (05/27/2012 05:34:08 PM) (Detached)
23936.apache (05/25/2012 10:34:08 PM) (Detached)
22907.cache (05/25/2012 09:10:57 PM) (Detached)
30901.dbteam (05/23/2012 02:45:14 PM) (Detached)
16047.www (08/16/2011 10:42:14 AM) (Detached)
16385.disk (07/17/2011 01:57:26 PM) (Detached)
9101.load (07/13/2011 04:27:40 PM) (Detached)
2446.top (07/05/2011 11:52:39 PM) (Detached)
24818.ssl (07/04/2011 08:27:12 PM) (Detached)
23214.log (07/04/2011 07:21:00 PM) (Detached)
10545.firewall (06/26/2011 05:39:18 PM) (Detached)
9942.apt (06/26/2011 05:12:44 PM) (Detached)
9932.blog (06/26/2011 05:11:17 PM) (Detached)
18 Sockets in /var/run/screen/S-root.

23:45 Upgrade starten

j7423:~# cat /etc/debian_version
5.0.7

How to solve “The following packages cannot be authenticated”

apt-get install debian-archive-keyring
nano /etc/apt/sources.list.d/mysources.list
#deb http://backports.debian.org/debian-backports lenny-backports main
apt-get update
apt-get upgrade
apt-get dist-upgrade
nano /etc/apt/sources.list
deb http://ftp.at.debian.org/debian/ squeeze main
#deb-src http://ftp.at.debian.org/debian/ squeeze main
deb http://security.debian.org/ squeeze/updates main

00:00 Starten des OS Upgrades

apt-get update
apt-get install apt dpkg aptitude

j7423:~# apt-get dist-upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be REMOVED:
libxcb-xlib0 proftpd
The following NEW packages will be installed:
bc dbconfig-common diffutils dmsetup firmware-linux-free gettext-base grub-pc insserv isc-dhcp-client isc-dhcp-common javascript-common libbsd0 libc-bin libcap2 libdb4.7 libevent-1.4-2
libfile-copy-recursive-perl libfont-freetype-perl libgssapi-krb5-2 libjs-mootools libk5crypto3 libkrb5-3 libkrb5support0 libltdl7 libnfnetlink0 libonig2 libpci3 libqdbm14 libudev0
libuuid-perl linux-base linux-image-2.6.32-5-xen-amd64 lockfile-progs pciutils php5-suhosin usbutils wwwconfig-common
The following packages will be upgraded:
adduser apache2 apache2-mpm-prefork apache2-utils apache2.2-bin apache2.2-common base-files base-passwd bash bsd-mailx bsdmainutils bsdutils busybox ca-certificates coreutils cpio cron
cron-apt curl dash debconf debconf-i18n debian-archive-keyring debianutils defoma dhcp3-client dhcp3-common diff dmidecode e2fslibs e2fsprogs ed exim4 exim4-base exim4-config
exim4-daemon-light file findutils fontconfig-config ftp gcc-4.3-base gnupg gnupg-curl gpgv grep groff-base grub grub-common gzip hostname htop ifupdown info initramfs-tools initscripts
install-info iproute iptables iputils-ping klibc-utils less libacl1 libapache2-mod-php5 libapr1 libaprutil1 libaprutil1-dbd-sqlite3 libaprutil1-ldap libattr1 libblkid1 libbz2-1.0 libc6
libcache-memcached-perl libcomerr2 libconsole libcurl3 libcurl3-gnutls libcwidget3 libdb4.6 libdb4.8 libdbd-mysql-perl libdbi-perl libdevmapper1.02.1 libedit2 libexpat1 libfontconfig1
libfreetype6 libgcc1 libgcrypt11 libgd2-xpm libgdbm3 libgnutls26 libgpg-error0 libhtml-template-perl libidn11 libjpeg62 libkeyutils1 libklibc libkrb53 libldap-2.4-2 liblocale-gettext-perl
liblockfile1 libmagic1 libmcrypt4 libmysqlclient16 libnet-daemon-perl libnewt0.52 libpam-modules libpam-runtime libpam0g libpcre3 libplrpc-perl libpng12-0 libpopt0 libpq5 libreadline5
libsasl2-2 libselinux1 libsepol1 libsigc++-2.0-0c2a libslang2 libsqlite3-0 libss2 libssh2-1 libssl0.9.8 libt1-5 libtasn1-3 libtext-charwidth-perl libtext-iconv-perl libtext-wrapi18n-perl
libusb-0.1-4 libwrap0 libx11-6 libx11-data libxau6 libxcb1 libxdmcp6 libxext6 libxml2 libxmuu1 libxpm4 linux-image-xen-amd64 locales login logrotate lsb-base makedev man-db manpages mawk
memcached mime-support mktemp module-init-tools mount mysql-common nano ncurses-base ncurses-bin net-tools netbase openssh-client openssh-server openssl openssl-blacklist passwd perl
perl-base perl-modules php5 php5-cli php5-common php5-gd php5-mcrypt php5-mysql phpmyadmin phpsysinfo procps proftpd-basic proftpd-mod-ldap proftpd-mod-mysql proftpd-mod-pgsql psmisc
readline-common rsyslog screen sed sgml-base shorewall shorewall-common shorewall-doc shorewall-shell ssl-cert sysv-rc sysvinit sysvinit-utils tar tasksel tasksel-data tcpd traceroute
ttf-dejavu-core tzdata ucf udev ulogd unzip update-inetd util-linux vim-common vim-tiny wget whiptail x11-common xauth xml-core zlib1g
216 upgraded, 37 newly installed, 2 to remove and 0 not upgraded.
Need to get 139 MB of archives.
After this operation, 142 MB of additional disk space will be used.
Do you want to continue [Y/n]? Y
┌──────────────────────────────────────────────┤ Configuring phpmyadmin ├───────────────────────────────────────────────┐
│                                                                                                                       │
│ The phpmyadmin package must have a database installed and configured before it can be used.  This can be optionally   │
│ handled with dbconfig-common.                                                                                         │
│                                                                                                                       │
│ If you are an advanced database administrator and know that you want to perform this configuration manually, or if    │
│ your database has already been installed and configured, you should refuse this option.  Details on what needs to be  │
│ done should most likely be provided in /usr/share/doc/phpmyadmin.                                                     │
│                                                                                                                       │
│ Otherwise, you should probably choose this option.                                                                    │
│                                                                                                                       │
│ Configure database for phpmyadmin with dbconfig-common?                                                               │
│                                                                                                                       │
│                                                                               <No>                                    │

00:38 Dist-Upgrade fertig

j7423:~# cat /etc/debian_version
6.0.5

00:43 Reboot

reboot

Problem nach Reboot !! stdin: is not a tty

Troubleshooting Debian Squeeze / JiffyBox

Debian Squeeze Upgrade von Lenny
Debian Squeeze Xen PV Kernel

Hallo Christian,

eine Vermutung von uns für den Fehler oben wäre, dass Sie vergessen haben „udev“ zu installieren. Sie haben auch in dem Fall trotz der Fehlermeldung Zugriff direkt per SSH und können es nachinstallieren. Alternativ geht das auch über das Rescue System. Dazu müssen Sie die Platte mounten und danach folgende Befehle ausführen:

Code:

mount /dev/xvdX /mnt
mount -t proc none /mnt/proc
mount -o bind /dev /mnt/dev
chroot /mnt

Danach können Sie mit dem folgenden Befehl „udev“ installieren:

Code:

aptitude install udev

Vielleicht hilft es ja in einem ähnlichen Fall noch einmal

Mit freundlichen Grüßen

Nils Dornblut
Communityservice

RECOVERYSYSTEM root@j7423:/# mount /dev/xvdb /mnt
RECOVERYSYSTEM root@j7423:/# cd /mnt
RECOVERYSYSTEM root@j7423:/mnt# mount -t proc none /mnt/proc
RECOVERYSYSTEM root@j7423:/mnt# mount -o bind /dev /mnt/dev
RECOVERYSYSTEM root@j7423:/mnt# chroot /mnt
j7423:/# aptitude install udev
The following packages will be REMOVED:
defoma{u} libdb4.5{u} libevent1{u} libfont-freetype-perl{u} libkrb53{u} libltdl3{u} libpq5{u} linux-modules-2.6-xen-amd64{u} openssl-blacklist{u} proftpd-basic{u} proftpd-mod-ldap{u}
proftpd-mod-mysql{u} proftpd-mod-pgsql{u} shorewall-common{u} shorewall-shell{u} x11-common{u}
0 packages upgraded, 0 newly installed, 16 to remove and 0 not upgraded.
Need to get 0 B of archives. After unpacking 23.2 MB will be freed.
Do you want to continue? [Y/n/?] Y

Control-Panel: Profile und Festplatten (Kernel)

Xen-Kernel:
Nicht unterstützt werden die Xen-Kernel von Debian ab Version 6.0 (Squeeze)

PV-Kernel:
Lösung: mit diesem kann die VM wieder gebootet werden nach dem Upgrade auf Squeeze!

apt-get update
apt-get upgrade
apt-get install shorewall-common shorewall-shell

(none):~# shorewall status
Shorewall-4.4.11.6 Status at (none) - Wed May 30 01:42:49 CEST 2012

Shorewall is stopped
State:Started (Wed May 30 01:24:46 CEST 2012)

(none):~# shorewall safe-start
Compiling...
Processing /etc/shorewall/shorewall.conf...
Loading Modules...
Compiling /etc/shorewall/zones...
Compiling /etc/shorewall/interfaces...
Determining Hosts in Zones...
WARNING: *** loc is an EMPTY ZONE ***
Preprocessing Action Files...
Pre-processing /usr/share/shorewall/action.Drop...
Pre-processing /usr/share/shorewall/action.Reject...
Compiling /etc/shorewall/policy...
Processing /etc/shorewall/initdone...
Compiling TCP Flags filtering...
Compiling Kernel Route Filtering...
Compiling Martian Logging...
Compiling MAC Filtration -- Phase 1...
Compiling /etc/shorewall/rules...
Generating Transitive Closure of Used-action List...
Processing /usr/share/shorewall/action.Reject for chain Reject...
Processing /usr/share/shorewall/action.Drop for chain Drop...
Compiling MAC Filtration -- Phase 2...
Applying Policies...
Generating Rule Matrix...
Creating iptables-restore input...
Compiling iptables-restore input for chain mangle:...
Shorewall configuration compiled to /var/lib/shorewall/.start
Starting...
Starting Shorewall....
done.
Do you want to accept the new firewall configuration? [y/n] y
New configuration has been accepted

(none):~# shorewall status
Shorewall-4.4.11.6 Status at (none) - Wed May 30 01:43:58 CEST 2012

Shorewall is running
State:Started (Wed May 30 01:42:56 CEST 2012)

Hostname bei Debian Squeeze ändern

startpar: service(s) returned failure: hostname.sh … failed!

(none):~# echo "109.239.60.32 j7423.servers.jiffybox.net j7423" >> /etc/hosts

(none):~# apt-get remove isc-dhcp-client
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
dhcp3-client isc-dhcp-client
0 upgraded, 0 newly installed, 2 to remove and 0 not upgraded.
After this operation, 651 kB disk space will be freed.
Do you want to continue [Y/n]? Y
(Reading database ... 25854 files and directories currently installed.)
Removing dhcp3-client ...
Removing isc-dhcp-client ...
Processing triggers for man-db ...

(none):~# apt-get install dhcpcd
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
dhcpcd
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 51.2 kB of archives.
After this operation, 135 kB of additional disk space will be used.
Get:1 http://ftp.at.debian.org/debian/ squeeze/main dhcpcd amd64 1:3.2.3-5 [51.2 kB]
Fetched 51.2 kB in 0s (384 kB/s)
Selecting previously deselected package dhcpcd.
(Reading database ... 25838 files and directories currently installed.)
Unpacking dhcpcd (from .../dhcpcd_1%3a3.2.3-5_amd64.deb) ...
Processing triggers for man-db ...
Setting up dhcpcd (1:3.2.3-5) ...

(none):~# /etc/init.d/hostname.sh

02:25 So jetzt geht alles..

Zu guter letzt muss beim ersten Verbinden mit ssh der host key
erst wieder in der known_hosts bekannt gemacht werden.

ssh-keygen -R blix0r.de

Warning: Remote Host Identification Has Changed error and solution
Debian Linux Regenerate OpenSSH Host Keys

Quelle:
HowTo: Upgrade Debian 5 Lenny zu Debian 6 Squeeze
Paketmanagement – Updates zwischen Releases (Upgrades) installieren

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert.

Current day month ye@r *

Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre mehr darüber, wie deine Kommentardaten verarbeitet werden.