JohnTheCoolingFan Posted April 29 Posted April 29 I have an OrangePi PC with armbian installed on it. Today, probably because of my stupidity, the board couldn't boot after upgrading a bunch of stuff. When I opened the sd card on my pc, I found that there were no kernel files in /boot and there were broken symlinks. I tried to replace these with the files from the current minimal image armbian is available for the board, but encountered a UUID mismatch. I then used files from a september 2021 backup, which did allow me to boot into a functional system. It had Linux 5.10.43-sunxi. But before my attempts to fix the issue, my system had Linux 6.1.11-sunxi installed, so I am concerned about this mismatch and would like to safely remove the old kernel files and bring it back to 6.1.11, after which I would like to proceed updating the system to Bookworm (the system still says it's Armbian Buster). How do I reinstall the linux kernel and initrd files in /boot and remove the files of other kernels in /boot? I really want to keep this system going because I don't want to reconfigure and setup again everything that's running on it. Soon I'm getting a new Pi board which would be a proper replacement and for which I am willing to set up all the stuff again, to start clean. 0 Quote
JohnTheCoolingFan Posted April 29 Author Posted April 29 Here is the output of `ls -lhv`, to give a little sense to how messed up the system currently is: -rw-r--r-- 1 root root 4.0M Apr 29 17:12 System.map-5.10.43-sunxi -rw-r--r-- 1 root root 3.6M Apr 29 16:39 System.map-6.6.28-current-sunxi -rw-r--r-- 1 root root 201 Apr 29 17:21 armbianEnv.txt -rw-r--r-- 1 root root 0 Apr 29 17:22 armbianEnv.txt.out -rw-r--r-- 1 root root 1.5K Apr 29 17:12 armbian_first_run.txt.template -rw-r--r-- 1 root root 226K Apr 29 17:12 boot.bmp -rw-r--r-- 1 root root 3.7K Apr 29 17:12 boot.cmd -rw-rw-r-- 1 root root 3.8K Apr 29 17:12 boot.scr -rw-r--r-- 1 root root 4.8K Apr 29 17:12 boot-desktop.png -rw-r--r-- 1 root root 188K Apr 29 17:12 config-5.10.43-sunxi -rw-r--r-- 1 root root 207K Apr 29 16:39 config-6.6.28-current-sunxi lrwxrwxrwx 1 root root 17 Apr 29 17:12 dtb -> dtb-5.10.43-sunxi drwxr-xr-x 3 root root 12K Apr 29 17:12 dtb-5.10.43-sunxi drwxr-xr-x 3 root root 12K Apr 29 16:39 dtb-6.6.28-current-sunxi -rw-r--r-- 1 root root 9.5M Apr 29 17:12 initrd.img-5.10.43-sunxi -rw-r--r-- 1 root root 11M Apr 29 16:39 initrd.img-6.6.28-current-sunxi drwxrwxr-x 2 root root 4.0K Jun 8 2020 overlay-user lrwxrwxrwx 1 root root 21 Apr 29 17:12 uInitrd -> uInitrd-5.10.43-sunxi -rw-r--r-- 1 root root 9.5M Apr 29 17:12 uInitrd-5.10.43-sunxi -rw-r--r-- 1 root root 11M Apr 29 16:39 uInitrd-6.6.28-current-sunxi -rwxr-xr-x 1 root root 7.7M Apr 29 17:12 vmlinuz-5.10.43-sunxi -rw-r--r-- 1 root root 8.6M Apr 29 16:39 vmlinuz-6.6.28-current-sunxi lrwxrwxrwx 1 root root 21 Apr 29 17:12 zImage -> vmlinuz-5.10.43-sunxi 0 Quote
JohnTheCoolingFan Posted April 30 Author Posted April 30 Bit the bullet and decided to go and upgrade the system on my own. I changed the apt sources to point to bookworm distro (up from buster), because armbian doesn't have apt mirrors for buster anymore. Reinstalling linux-image package set up the kernel and after a reboot I was running 6.6.16-current-sunxi, awesome! Performing a full-upgrade right now. 0 Quote
Solution JohnTheCoolingFan Posted April 30 Author Solution Posted April 30 I think this will be the final update. One thing I now know for sure: it would've been easier to reinstall. But I did it my way, learned a bunch of things, broke and restored things, it was kinda fun to take my "old" server for a ride. Had to do much more upgrades, some broke the network, some broke libcrypt which broke ssh and sudo, but in the end I have a working system and software running on it is relatively up-to-date, debian bookworm edition. 0 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.