Are old balena os versions stored somewhere? How can I access them?
I am running into an API mismatch problem because I am running a very old version of openbalena. I believe I need balenaOS version 2.58 like my other devices are running, but I can only find the most recent version on the website.
Hi, the documentation at openBalena - Home states to download a new unmanaged image from balenaOS - Run Docker containers on embedded IoT devices. That is the same as using balena os download. You will then configure it as per the instructions with balena os configure to join your openBalena fleet.
Yes… and that page does not have previous versions of balenaOS, hence the impetus to use the CLI command in the first place.
When clicking one of the buttons on that page, the query string of the download url has a query param. I tried modifying this param to see if other versions were hosted but not linked to, but haven’t tried a version that worked. Should I keep exploring this option?
If you run balena os versions <your-device-type> you’ll see a list of all the versions of balenaOS that are available to download. Running, for example, balena os download fincm3 --version v2.95.8will allow you to download specifically version v2.95.8 for the balenaFin. Let us know if this resolves your question!
balena os versions raspberrypi3 returns the following: Error: No balenaOS versions found for device type 'raspberrypi3'.
Same thing when I swap in raspberrypi4-64 for the device type. Is this because I am using openBalena? The documentation indicates that balena os versions is not supported on openBalena.
I am using 12.55.11, I believe when I try to use version 13/the latest version there is an issue with API endpoints not working. Do I need to try using a later version?
❯ ./balena os download fincm3 --version v2.95.8 -o test-download.img
Getting device operating system for fincm3
BalenaRequestError: Request error: Internal Server Error
** Hint: some OS releases require specifying the full OS version including
** the '.prod' or '.dev' suffix, e.g. '--version 2021.10.2.prod'
Additional information may be available with the `--debug` flag.
For further help or support, visit:
https://www.balena.io/docs/reference/balena-cli/#support-faq-and-troubleshooting
❯ ./balena os download fincm3 --version v2.95.8 -o test-download.img --debug
[debug] new argv=[/Users/ikaros/Downloads/balena-cli/balena,/snapshot/volume/bin/balena,os:download,fincm3,--version,v2.95.8,-o,test-download.img] length=8
Getting device operating system for fincm3
[debug] Event tracking error: Response code 404 (Not Found)
BalenaRequestError: Request error: Internal Server Error
** Hint: some OS releases require specifying the full OS version including
** the '.prod' or '.dev' suffix, e.g. '--version 2021.10.2.prod'
BalenaRequestError: Request error: Internal Server Error
** Hint: some OS releases require specifying the full OS version including
** the '.prod' or '.dev' suffix, e.g. '--version 2021.10.2.prod'
at Object.<anonymous> (/snapshot/volume/node_modules/balena-sdk/node_modules/balena-request/build/request.js:193:27)
at Generator.next (<anonymous>)
at fulfilled (/snapshot/volume/node_modules/balena-sdk/node_modules/tslib/tslib.js)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
For further help or support, visit:
https://www.balena.io/docs/reference/balena-cli/#support-faq-and-troubleshooting
❯ ./balena os download fincm3 --version v2.95.8.prod -o test-download.img --debug
[debug] new argv=[/Users/ikaros/Downloads/balena-cli/balena,/snapshot/volume/bin/balena,os:download,fincm3,--version,v2.95.8.prod,-o,test-download.img] length=8
Getting device operating system for fincm3
[debug] Event tracking error: Response code 404 (Not Found)
BalenaRequestError: Request error: Internal Server Error
BalenaRequestError: Request error: Internal Server Error
at Object.<anonymous> (/snapshot/volume/node_modules/balena-sdk/node_modules/balena-request/build/request.js:193:27)
at Generator.next (<anonymous>)
at fulfilled (/snapshot/volume/node_modules/balena-sdk/node_modules/tslib/tslib.js)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
For further help or support, visit:
https://www.balena.io/docs/reference/balena-cli/#support-faq-and-troubleshooting
❯ ./balena os versions raspberrypi4-64 --debug
[debug] new argv=[/Users/ikaros/Downloads/balena-cli/balena,/snapshot/volume/bin/balena,os:versions,raspberrypi4-64] length=4
[debug] Event tracking error: Response code 404 (Not Found)
BalenaRequestError: Request error: Internal Server Error
BalenaRequestError: Request error: Internal Server Error
at Object.<anonymous> (/snapshot/volume/node_modules/balena-sdk/node_modules/balena-request/build/request.js:193:27)
at Generator.next (<anonymous>)
at fulfilled (/snapshot/volume/node_modules/balena-sdk/node_modules/tslib/tslib.js)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
For further help or support, visit:
https://www.balena.io/docs/reference/balena-cli/#support-faq-and-troubleshooting
❯ ./balena version
13.10.1
Here is the output of docker ps on the server running openBalena if that helps:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
06ff4b982f7e openbalena_haproxy "/docker-entrypoint.…" 4 weeks ago Up 4 weeks 0.0.0.0:80->80/tcp, :::80->80/tcp, 0.0.0.0:443->443/tcp, :::443->443/tcp, 222/tcp, 5432/tcp, 0.0.0.0:3128->3128/tcp, :::3128->3128/tcp, 6379/tcp openbalena_haproxy_1
fb8ed40546fe balena/open-balena-vpn:v9.16.1 "/usr/bin/entry.sh" 4 weeks ago Up 4 weeks 80/tcp, 443/tcp, 3128/tcp openbalena_vpn_1
8c8361f63d39 balena/open-balena-registry:v2.13.11 "/usr/bin/entry.sh" 4 weeks ago Up 4 weeks 80/tcp openbalena_registry_1
a4fbaf0c54ef balena/open-balena-api:v0.109.2 "/usr/bin/entry.sh" 4 weeks ago Up 4 weeks 80/tcp openbalena_api_1
839b08e8214c balena/open-balena-s3:v2.9.9 "/usr/bin/entry.sh" 4 weeks ago Up 4 weeks 80/tcp openbalena_s3_1
9df89788cfbf openbalena_cert-provider "/entry.sh /usr/src/…" 4 weeks ago Up 4 weeks 80/tcp openbalena_cert-provider_1
5220a3423ccb balena/open-balena-db:v4.1.0 "/balena-entrypoint.…" 4 weeks ago Up 4 weeks 5432/tcp openbalena_db_1
ed0867f4bd2a redis:alpine "docker-entrypoint.s…" 4 weeks ago Up 4 weeks 6379/tcp openbalena_redis_1
Could you paste the output of balena devices supported [1]? As this is an openBalena deployment, it could be that some aspect of the device-type setup or OS image malfunctioned. The CLI command I mentioned should tell us what the API recognizes as valid device types.
If this command also errors as your other commands have (thanks for pasting the outputs of those commands by the way!), you could try looking at the logs for your open-balena-api service to see if there’s a more specific error message returned from the CLI command than a status code.
This command also fails… I checked the logs on the container as you requested, and this error jumped out (there are lots of logs coming quickly but I can post the whole thing if needed)
GET SyntaxError: Could not resolve relationship mapping from 'device type' to 'is default for,application'
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.ResolveRelationship (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:811:10)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.NavigateResources (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1351:36)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.AddNavigation (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1408:27)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.Lambda (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1043:26)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.Property (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1139:16)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.ReferencedProperty (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1076:21)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.BooleanMatch (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:975:19)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.SelectFilter (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:688:22)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.AddQueryOptions (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1330:9)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.PathSegment (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:589:9)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at OData2AbstractSQL.match (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:333:24)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/uri-parser.ts:165:43
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/es5-ext/function/#/partial.js:12:16
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/memoizee/lib/configure-map.js:61:24
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/memoizee/lib/weak.js:87:21
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/uri-parser.ts:242:50
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at Object.exports.translateUri (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/uri-parser.ts:404:28)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at prepareRequest (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:981:48)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:997:16
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at mapTill (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/control-flow.ts:45:19)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:991:20
Aug 06 03:08:26 a4fbaf0c54ef api[984]: at exports.handleODataRequest (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:1056:21)
Aug 06 03:08:26 a4fbaf0c54ef api[984]: 2022-08-06T03:08:26.296Z 99.89.195.194 a/2 GET /resin/device_type?$orderby=name asc&$filter=is_default_for__application/any(idfa:(idfa/is_host eq true) and (idfa/is_archived eq false))&$expand=is_of__cpu_architecture($select=slug)&$select=slug,name 500 23.928ms balena-sdk/16.22.0
This is the error in the container logs when I run ./balena os download fincm3 --version v2.95.8 -o test-download.img
Aug 06 03:19:19 a4fbaf0c54ef api[984]: } GET SyntaxError: Could not resolve relationship mapping from 'device type' to 'device type alias'
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.ResolveRelationship (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:811:10)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.NavigateResources (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1351:36)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.AddNavigation (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1408:27)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.Lambda (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1043:26)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.Property (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1139:16)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.ReferencedProperty (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1076:21)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.BooleanMatch (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:975:19)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.SelectFilter (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:688:22)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.AddQueryOptions (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:1330:9)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.PathSegment (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:589:9)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at OData2AbstractSQL.match (/usr/src/app/node_modules/@balena/odata-to-abstract-sql/src/odata-to-abstract-sql.ts:333:24)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/uri-parser.ts:165:43
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/es5-ext/function/#/partial.js:12:16
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/memoizee/lib/configure-map.js:61:24
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/memoizee/lib/weak.js:87:21
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/uri-parser.ts:242:50
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at Object.exports.translateUri (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/uri-parser.ts:404:28)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at prepareRequest (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:981:48)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:997:16
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at mapTill (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/control-flow.ts:45:19)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at /usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:991:20
Aug 06 03:19:19 a4fbaf0c54ef api[984]: at exports.handleODataRequest (/usr/src/app/node_modules/@balena/pinejs/src/sbvr-api/sbvr-utils.ts:1056:21)
Aug 06 03:19:19 a4fbaf0c54ef api[984]: 2022-08-06T03:19:19.633Z 99.89.195.194 a/2 GET /resin/device_type?$orderby=name asc&$top=1&$filter=device_type_alias/any(dta:dta/is_referenced_by__alias eq 'fincm3')&$select=slug 500 18.568ms balena-sdk/16.22.0