Upgrade Best Practices?

I’m in the process of upgrading to a new image/kernel, and have many questions regarding best practices. My goal is to stay relatively current while spending most of my time on developing my application, not on doing upgrades; my success to date has been dismal. Over the past few weeks I have installed a new image (Debian Jessie 8.2) and am running the kernel 4.1.13-ti-r36. It has taken over three weeks just to get the networking running in a stable manner; I have been successful, but I don’t think I was really doing anything totally foolish, it just took that long. I now am trying to go to the next steps, and after much googling/reading am finding the process extremely challenging (at least for me); I have more questions than answers. If someone can help, it would be appreciated.

  1. What is best practices? I have seen references to Robert Nelson’s “manual”, but can’t find where it is (I have browsed https://github.com/RobertCNelson/ but so far can’t find it). I have found many sites such as http://elinux.org/Beagleboard:BeagleBoneBlack_Debian, which has many snippets, but it assumes one knows what is going on; for example, it points to http://elinux.org/Beagleboard:BeagleBoneBlack_Debian#2015-11-03 as being the most recent version, but this looks old.

  2. My version, seems to be part of the “TI” branch, but I have seen when googling that this branch requires numerous kernel upgrades.

"### TI BSP

WARNING: do not use if you are not use to re-basing git branches, as this is based on http://git.ti.com/gitweb/?p=ti-linux-kernel/ti-linux-kernel.git;a=shortlog;h=refs/heads/ti-linux-4.1.y instead of a stable kernel branch. Thus you will have to do: (git checkout master -f ; git branch -D tmp ; git pull ; git checkout origin/ti-linux-4.1.y -b tmp) often…


Would it be better to use a “more stable” branch? Some branches also have RT in their name; I assume this stands for real-time? Is this version a good choice? how does one use the “real-time” capabilities? I can’t, to date, find a site that recommends “Best Practices” in which kernel and kernel updates to use.

  1. I have seen two methods for changing the kernel

cd /opt/scripts/tools
./update_kernel.sh --kernel “kernel_name”
I assume after this, one reboots? Where does one find what kernels are available; what is best to use for “kernel_name”? which ones should be used? can one go back and forth without repercussions?
The other method I have seen is using apt-get such as
sudo apt-get install linux-image-3.14.17-ti-r10
Which method is preferred? Are there pros and cons? Again, can one go back and forth? And which kernels are available?

Can one stay relatively up to date without re-flashing the complete eMMC and re-installing everything as this takes over a month full-time (for me, sigh!), just by doing apt-get upgrades and installing new kernels? How does know when to update the kernel and which one to use?

  1. Doing an >apt-cache search kernel shows well over a hundred choices for “linux-firmware-image…”, “linux-headers-…”, “linux-image-…” etc. Which ones should be used? What is the difference between the three choices? Is there a site which recommends the best current choice?

I have been using the BBB’s on and off for almost two years now (mostly on) and still have real problems and have to commit large amounts of time trying to stay current. I’m guessing I may be doing something fundamentally wrong; but I can’t imagine how someone just getting started could navigate this issue. Could this difficulty possibly be something that is keeping the BBB’s from getting popular?

In summary, if someone knowledgeable in this area could give guidelines on how best to stay current in an efficient manner, it would be appreciated.

I’m not the expert you are looking for, but I’ll give you what has worked for me. I’d forget all about the eMMC until you are “done” and know everything will fit in 4GB, and stick with booting SD cards during development (8GB is a good minimum).

If you want to “develop” instead of “test” I’d suggest you stick with images from “latest” at beaglebord.org as your starting point.
Basically if you need bonscript, stick with Debian 7.9 image and use apt-get update ; apt-get upgrade to stay reasonably current.

I think if doing PRU stuff you’ll want the latest 8.2 image. Again apt-get update ; apt-get upgrade should work, but that said, I’ve had some recent failures where it broke my system. I’m just getting started with PRU stuff and this was my conclusion from a lot of Google searching.

I strongly recommend that once you get to a basic, useful level of functionally that you back up your image before doing an apt-get update ; apt-get install. Its easy to use dd to make a spare SD card in Linux once you’ve shutdown and removed it from your Beaglebone. Windows has utilities to do so too, but I gave up on Windows long ago where upgrade breakage was far harder to fix, so I’ll offer no advice about cloning an SD card using Windows.

Basically on Linux:
dd if=/dev/sdg bs=4M of=/dev/sdi ; sync

copies the image on SD card /dev/sdg to the card in /dev/sdi. Take advantage of the “write protect” feature on a “micro to SD” adapter for your source image, so a typo don’t wipe you out!
Although the device node names will depend on what “flavor” of Linux you are running :frowning:

Hope this helps.