Re: Upgrading Debian Distribution May 15, 2023 10:10AM |
Registered: 9 years ago Posts: 54 |
root@pogoplug-dev:~# ls -la / total 64 drwxr-xr-x 18 root root 4096 May 2 12:10 . drwxr-xr-x 18 root root 4096 May 2 12:10 .. lrwxrwxrwx 1 root root 7 May 2 12:10 bin -> usr/bin drwxr-xr-x 3 root root 4096 May 13 23:01 boot drwxr-xr-x 13 root root 2900 Jan 1 1970 dev drwxr-xr-x 76 root root 4096 May 15 17:07 etc drwxr-xr-x 2 root root 4096 Jan 22 2012 home lrwxrwxrwx 1 root root 7 May 2 12:10 lib -> usr/lib drwx------ 2 root root 16384 Feb 24 2012 lost+found drwxr-xr-x 2 root root 4096 Feb 24 2012 media drwxr-xr-x 2 root root 4096 Feb 10 2015 mnt drwxr-xr-x 2 root root 4096 Feb 24 2012 opt dr-xr-xr-x 124 root root 0 Jan 1 1970 proc drwx------ 7 root root 4096 Apr 29 01:12 root drwxr-xr-x 12 root root 600 May 15 17:07 run lrwxrwxrwx 1 root root 8 May 2 12:10 sbin -> usr/sbin drwxr-xr-x 2 root root 4096 Feb 24 2012 srv dr-xr-xr-x 12 root root 0 Jan 1 1970 sys drwxrwxrwt 4 root root 80 May 15 17:07 tmp drwxr-xr-x 11 root root 4096 Sep 24 2021 usr drwxr-xr-x 11 root root 4096 Jan 1 1970 var
Re: Upgrading Debian Distribution May 15, 2023 04:05PM |
Admin Registered: 13 years ago Posts: 18,898 |
cd /boot ls -lart
Re: Upgrading Debian Distribution May 15, 2023 06:49PM |
Admin Registered: 13 years ago Posts: 18,898 |
Quote
Ugrading to Debian stretch
This is a brief instruction about how to upgrade to Debian stretch from jessie. It also applicable to all other Debian version upgrade, i.e wheezy to jessie, stretch to the future Debian stable version.
I assume you are currently running one of my customed kernel release linux-image-xx.xx.xx-kirkwood-tld-xx from this thread. This is the reason for this post, since upgrading to the next Debian release while running a customed kernel could potentially cause some out-of-sync in the boot files. The following are 2 sections, one of them might be applicable to your system. And also see Note (section 3) at the end for how to solve possible error during upgrade. If needed in the furture, I will add more sections to this post to cover some special cases.
1. Have installed only my released kernel images
Your system is running only my released kernel linux-image-xx.xx.xx-kirkwood-tld-xx. It has never been upgraded to mainline kernel or previously running mainline kernel. Usually because you started with my released rootfs from this thread.
Back up your rootfs before starting the following steps.
a. Update the apt source list to stretch. Your source should look like the following. Note that it is a good idea to adjust the repo to near your locale, and use ftp where available.
cat /etc/apt/sources.list
deb http://ftp.us.debian.org/debian stretch main
deb-src http://ftp.us.debian.org/debian stretch main
deb http://security.debian.org/ stretch/updates main contrib non-free
deb-src http://security.debian.org/ stretch/updates main contrib non-free
deb http://http.debian.net/debian stretch-updates main contrib
deb-src http://http.debian.net/debian stretch-updates main contrib
b. Run full upgrade (or you can choose to do minimal upgrade with step c).
apt-get update
apt-get dist-upgrade
c. Skip this if you've chosen step b. Run minimal upgrade if you want to do it slow, and then update to stretch for certain packages in the future when necessary. This is OK to do if you don't care much about having your system running every latest Debian package versions (there are a lot of packages that you might never use).
apt-get update
apt-get upgrade
d. Check fstab before rebooting. Debian stretch now has stricter rules, and rejects the old syntax in fstab. So if your rootfs still has the old entry like this
/dev/root / ext3 noatime,errors=remount-ro 0 1
Then edit /media/sdb1/etc/fstab entry for root device to the new syntax to use the rootfs label:
LABEL=rootfs / ext3 noatime,errors=remount-ro 0 1
e. Usually a distribution upgrade like this would result in a new initramfs. So regenerate the uInitrd boot file. See section 4 in my kernel/rootfs installation for how to recreate uInitrd. It should look like this example: cd /boot mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-4.11.3-kirkwood-tld-2 -d initrd.img-4.11.3-kirkwood-tld-2 uInitrd
Re: Upgrading Debian Distribution May 16, 2023 07:41AM |
Registered: 9 years ago Posts: 54 |
> cd /boot > ls -lart >
root@pogoplug-dev:/boot# ls -lart total 64124 -rwxr-xr-x 1 root root 5435824 Aug 1 2021 vmlinuz-5.13.6-kirkwood-tld-1 -rw-r--r-- 1 root root 183927 Aug 1 2021 config-5.13.6-kirkwood-tld-1 -rw-r--r-- 1 root root 4403336 Aug 1 2021 System.map-5.13.6-kirkwood-tld-1 -rwxr-xr-x 1 root root 5435824 Aug 1 2021 zImage-5.13.6-kirkwood-tld-1 -rw-r--r-- 1 root root 7762080 Aug 1 2021 linux-headers-5.13.6-kirkwood-tld-1_1.0_armel.deb drwxr-xr-x 2 root root 4096 Aug 1 2021 dts -rw-r--r-- 1 root root 5435888 Sep 24 2021 uImage.orig -rw-r--r-- 1 root root 5435888 Sep 24 2021 uImage -rw-r--r-- 1 root root 9671091 Sep 24 2021 uInitrd -rwxr-xr-x 1 root root 5445938 Apr 28 22:55 zImage.fdt -rw-r--r-- 1 root root 5446002 Apr 28 22:56 uImage.pogo_e02 drwxr-xr-x 18 root root 4096 May 2 12:10 .. -rw-r--r-- 1 root root 10829167 May 2 12:50 initrd.img-5.13.6-kirkwood-tld-1 drwxr-xr-x 3 root root 4096 May 13 23:01 .
Re: Upgrading Debian Distribution May 16, 2023 07:46AM |
Registered: 9 years ago Posts: 54 |
> e. Usually a distribution upgrade like this > would result in a new initramfs. So regenerate the > uInitrd boot file. See section 4 in my > kernel/rootfs installation for how to recreate > uInitrd. It should look like this example: > > cd /boot > mkimage -A arm -O linux -T ramdisk -C gzip -a > 0x00000000 -e 0x00000000 -n > initramfs-4.11.3-kirkwood-tld-2 -d > initrd.img-4.11.3-kirkwood-tld-2 > uInitrd[/quote] >
Re: Upgrading Debian Distribution May 16, 2023 11:07PM |
Admin Registered: 13 years ago Posts: 18,898 |
root@pogoplug-dev:/boot# ls -lart total 64124 -rwxr-xr-x 1 root root 5435824 Aug 1 2021 vmlinuz-5.13.6-kirkwood-tld-1 -rw-r--r-- 1 root root 183927 Aug 1 2021 config-5.13.6-kirkwood-tld-1 -rw-r--r-- 1 root root 4403336 Aug 1 2021 System.map-5.13.6-kirkwood-tld-1 -rwxr-xr-x 1 root root 5435824 Aug 1 2021 zImage-5.13.6-kirkwood-tld-1 -rw-r--r-- 1 root root 7762080 Aug 1 2021 linux-headers-5.13.6-kirkwood-tld-1_1.0_armel.deb drwxr-xr-x 2 root root 4096 Aug 1 2021 dts -rw-r--r-- 1 root root 5435888 Sep 24 2021 uImage.orig -rw-r--r-- 1 root root 5435888 Sep 24 2021 uImage -rw-r--r-- 1 root root 9671091 Sep 24 2021 uInitrd -rwxr-xr-x 1 root root 5445938 Apr 28 22:55 zImage.fdt -rw-r--r-- 1 root root 5446002 Apr 28 22:56 uImage.pogo_e02 drwxr-xr-x 18 root root 4096 May 2 12:10 .. -rw-r--r-- 1 root root 10829167 May 2 12:50 initrd.img-5.13.6-kirkwood-tld-1 drwxr-xr-x 3 root root 4096 May 13 23:01 .
cd /boot cp -a uInitrd uInitrd.bak
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x00000000 -e 0x00000000 -n initramfs-5.13.6-kirkwood-tld-1 -d initrd.img-5.13.6-kirkwood-tld-1 uInitrd sync
Re: Upgrading Debian Distribution May 17, 2023 08:21AM |
Registered: 9 years ago Posts: 54 |
Re: Upgrading Debian Distribution May 25, 2023 10:45PM |
Registered: 9 years ago Posts: 52 |
Re: Upgrading Debian Distribution May 26, 2023 12:04AM |
Admin Registered: 13 years ago Posts: 18,898 |
Quote
apt-cache show orphan-sysvinit-scripts
Package: orphan-sysvinit-scripts
Version: 0.14
Installed-Size: 80
Maintainer: Debian sysvinit maintainers <debian-init-diversity@chiark.greenend.org.uk>
Architecture: all
Depends: ucf
Description: Orphaned System-V-like init scripts
Description-md5: 6e62a05dcaf39a4d5ec8fa894f07cfb8
Section: admin
Priority: optional
Filename: pool/main/o/orphan-sysvinit-scripts/orphan-sysvinit-scripts_0.14_all.deb
Size: 16088
MD5sum: 7ef507a4b51d81f88a3eb162678c6d08
SHA256: 18b1294829c7a3b8ff2962a16c00c0d51d233e2903ca4f09bd8ff3701fc9abfe
apt-get install orphan-sysvinit-scripts
Re: Upgrading Debian Distribution May 30, 2023 05:25AM |
Registered: 9 years ago Posts: 52 |
Re: Upgrading Debian Distribution May 30, 2023 02:58PM |
Admin Registered: 13 years ago Posts: 18,898 |
Re: Upgrading Debian Distribution June 01, 2023 01:35PM |
Admin Registered: 13 years ago Posts: 18,898 |
Re: Upgrading Debian Distribution October 20, 2023 11:05PM |
Registered: 11 months ago Posts: 4 |
Re: Upgrading Debian Distribution October 20, 2023 11:22PM |
Registered: 9 years ago Posts: 454 |
Re: Upgrading Debian Distribution October 20, 2023 11:55PM |
Admin Registered: 13 years ago Posts: 18,898 |
Re: Upgrading Debian Distribution October 21, 2023 05:27AM |
Registered: 11 months ago Posts: 4 |
Re: Upgrading Debian Distribution October 25, 2023 04:04AM |
Registered: 10 years ago Posts: 66 |
Quote
cat /etc/debian_version
11.8
Quote
/bin
/lin
/sbin
Quote
deb http://deb.debian.org/debian bullseye main contrib non-free
deb-src http://deb.debian.org/debian bullseye main contrib non-free
deb http://deb.debian.org/debian-security/ bullseye-security main contrib non-free
deb-src http://deb.debian.org/debian-security/ bullseye-security main contrib non-free
deb http://deb.debian.org/debian bullseye-updates main contrib non-free
deb-src http://deb.debian.org/debian bullseye-updates main contrib non-free
deb http://deb.debian.org/debian bullseye-backports main contrib non-free
deb-src http://deb.debian.org/debian bullseye-backports main contrib non-free
Quote
5. In Debian bookworm, the switch over to /usr is in effect. The following old sytsem folders are now symlinks to the real location in /usr.
# ls -l /{bin,lib,sbin}
lrwxrwxrwx 1 root root 7 Apr 26 14:04 /bin -> usr/bin
lrwxrwxrwx 1 root root 7 Apr 26 14:04 /lib -> usr/lib
lrwxrwxrwx 1 root root 8 Apr 26 14:04 /sbin -> usr/sbin
So if for whatever reason, your file system does not show these 3 folders as symlinks, then you'll need to adjust them.
And also make sure that your rootfs backup conform to this structure, too.
Re: Upgrading Debian Distribution October 25, 2023 12:22PM |
Admin Registered: 13 years ago Posts: 18,898 |
Re: Upgrading Debian Distribution October 28, 2023 03:16PM |
Registered: 10 years ago Posts: 66 |
Re: Upgrading Debian Distribution October 28, 2023 04:13PM |
Admin Registered: 13 years ago Posts: 18,898 |
> ln -s /bin /usr/bin > ln -s /lib /usr/lib > ln -s /sbin /usr/sbin >>
Re: Upgrading Debian Distribution December 26, 2023 04:10PM |
Admin Registered: 13 years ago Posts: 18,898 |
Quote
Updated 26 Dec 2023
Upgrade to bookworm Debian 12.4
Re: Upgrading Debian Distribution December 27, 2023 02:58PM |
Registered: 2 years ago Posts: 53 |
debian 192.168.1.5 ZyXEL NSA325 Linux version 6.6.3-kirkwood-tld-1 (root@tldDebian) (gcc (Debian 12.2.0-14) 12.2 .0, GNU ld (GNU Binutils for Debian) 2.40) #1 PREEMPT Tue Nov 28 23:25:58 PST 20 23 Debian 11.8 Wed Dec 27 21:38:21 CET 2023 up 18 minutes root@debian:Shall I upgrade directly to the last or shall I make any intermediate upgrade ?
Re: Upgrading Debian Distribution December 27, 2023 04:13PM |
Admin Registered: 13 years ago Posts: 18,898 |
Re: Upgrading Debian Distribution June 23, 2024 10:16AM |
Registered: 6 years ago Posts: 183 |
Re: Upgrading Debian Distribution June 23, 2024 11:09AM |
Registered: 2 years ago Posts: 53 |
Re: Upgrading Debian Distribution June 23, 2024 03:37PM |
Admin Registered: 13 years ago Posts: 18,898 |
Quote
if you don't want systemd destroyed, found out hard way:)
Re: Upgrading Debian Distribution June 29, 2024 07:56PM |
Registered: 6 years ago Posts: 183 |
Re: Upgrading Debian Distribution June 30, 2024 01:21AM |
Admin Registered: 13 years ago Posts: 18,898 |
Re: Upgrading Debian Distribution July 03, 2024 01:44AM |
Registered: 6 years ago Posts: 183 |
Re: Upgrading Debian Distribution July 03, 2024 01:52PM |
Admin Registered: 13 years ago Posts: 18,898 |