02-01-2024 06:34 AM - edited 02-01-2024 07:12 AM
Issue:
Basic Real-Time firmware now (2024) requires 70% of the available disk on sbRIO-9607, instead of just 36% e.g. in LabVIEW 2020! Leaving too little to even retrieve an image of the device.
Background:
Testing LabVIEW 2024Q1 32bit I successfully deployed one of our applications currently maintained in LabVIEW 2020/22 to one of our sbRIO-9607s (unable to compile in 64 bit version, but that's another issue...), but was unable to take an image of the device afterwards. The issue it turned out was that the primary drive only had 80 MB of space left (after installing our RT application). This has never been an issue on a fresh install before though so I began to look at how a formatted sbRIO gets filled up by the firmware....
Details:
2020
With Firmware version 8.8.0f0 (LabVIEW 2020) the necessary firmware left 246 of 387 MB free...so the firmware took up 141 MB, as seen here:
2024
The system image for 2024Q1 on the same device with just the recommended packages (unnecessarily pushes VISA Remote, System link client etc. on it) grabs 270 MB, most of the drive.
With just 117 MB left, before adding our own application(!), retriving images is no longer possible due to lack of available temporary storage.
Skipping the unnecessary recommended packages though we still end up with the firmware taking up 269 MB(!) and too little space on the drive to retrive images of it (RT app adds 20MB too).
Solution?
Is there anything we can do to get around this (reduce the required size preferably...), or are we forced to stay with an older version of LabVIEW with these sbRIO targets?
Not having much space for the RT application and its files is bad enough (storage can be added, but some things should be put on the primary drive...). But not being able to retrieve images of the controllers is even worse.
02-01-2024 03:13 PM - edited 02-06-2024 03:34 AM
Running on older firmware / OS and drivers is not an option either. LabVIEW 2024 will not deploy apps to those.
02-05-2024 09:25 AM
I'm just talking to myself so far here it seems🤔...but anyway; the real jump seems to have come when you could no longer choose to install "cRIO" on the target, but had to choose a "system image".
The 2021 system image stripped down takes 262 MB, which is about double what it used to be before that (just 111 MB in 2018, 126 MB in 2019....).
With just 387 MB available on a blank sbRIO-9607 it was a problem already then, I just only noticed it now when considering upgrading to the 2024 image.☹️
02-06-2024 03:40 AM
Thanks for testing this. One thing to remember when my last application for the sbRIO-9651 ever is considered for upgrade: Don't go beyond 2020! (It was developed in 2018 and still is).
02-06-2024 05:14 AM
I feel like at somepoint NI did start including more packages pre-installed in the image that were commonly used.
It might be worth comparing the opkg list output and seeing what has changed.
02-06-2024 09:23 AM - edited 02-06-2024 11:22 AM
It seems you are right James,
60 or so python packages included whether you want it or not for example 😲
Getting rid of them is not straight forward though as other packages, among them parts of the sys-api, seems to depend on python now (could be that those are not critical though..who knows).
I did a forced remove of the python packages though just to see and that got rid of 58 MB (!). I have not yet tested how that affects the system though.
02-06-2024 01:12 PM
Unfortunately, I believe you're running into a known issue from LabVIEW RT 2021 (1506353).
02-06-2024 02:09 PM - edited 02-06-2024 02:09 PM
Ok, so it's in a known issues list...(why is it not kept in the known issues for 2022-2024, when the affected targets are still otherwise "supported"?) but will not be resolved and there is no workarounds (no way to skip any opkg packages without losing the ability to run the RT app OK?)?
If this was just due to the convenience of using Python for some functions that disk space loss was a high cost... 😞
02-06-2024 03:30 PM
Hi Mads,
The issue is caused by a mix of some components moving to use Salt under the hood and us moving away from our custom driver installation thing to the more industry standard DKMS. These both happened at the same time and bloated the install.
We do have an internal KB and workaround for the issue. The workaround is not ideal though, it will leave opkg in a not great state dependency wise, and you won't be able to modify software from MAX. If you want to modify software from MAX again, you will need to boot safemode, format runmode, and reinstall it. It will let you get your working system down to <50% of used disk space and be able to take an image.
opkg remove gcc gcc-dev gcc-symlinks cpp kernel-dev kernel-devsrc libgcc-s-dev shared-mime-info binutils binutils-dev *ncurses* libfmi-dev libbfd bison-dev bison flex-dev flex-libf1 flex libstdc++-dev *perl* libmpc3 libmpfr4 --force-remove --nodeps
opkg remove*python3* ni-skyline-tag-client ni-skyline-file-client ni-skyline-message-client
ni-sysmgmt-salt-minion-support ni-sysmgmt-sysapi-expert salt-minion salt-common libmpc-dev libmpfr-dev libdbus-glib-1-2 ni-arch-gen
cat /proc/modules | awk '{print "kernel-module-"$1"-[0-9]"}' | sed 's/_/-/g' > modules-in-use.txt
opkg list-installed | grep kernel-module- | awk '{print $1}' | grep -v -f modules-in-use.txt | xargs opkg remove --nodeps
Frees: ~7MB02-07-2024 05:09 AM - edited 02-07-2024 05:13 AM
Thanks for the detailed reply Michael🙂
Test done so far
Before getting that recipe I did this on an sbRIO-9607 running RT System Image 22.8/firmware 24.0.0f131-x64:
Results:
I have not tried to do this on a target with a 2024 system image yet though...And I have not tried your recipe yet (the warned side-effects seem worse than for what I tested, but then I do not know fully what the effects of my changes are 😨...).
It would be nicer to safely be able to move all development along to 2024 instead of having partially stick to 2020 just for the sake of these sbRIO targets.