RPI3 Remote Build Failed: Internal Server Error

I’m using that project: GitHub - balenablocks/browser: A drop-in web browser block

The first push work successfully. After that, it’s always fail.

Tried With RPI3 and RPI3 64bits and recreated the app. No success.

In local build I got no issue but the container has an error :

standard_init_linux.go:211: exec user process caused "exec format error"

Remote build log:

ubuntu@DESKTOP-STEEVE:/mnt/c/Users/steev/source/repos/github.com/browser$ balena push Dashboard --debug
------------------------------------------------------------------------------
Warning: Node version "v15.13.0" does not match required versions ">=10.20.0 <13.0.0".
This may cause unexpected behavior. To upgrade Node, visit:
https://nodejs.org/en/download/
------------------------------------------------------------------------------
[debug] new argv=[/usr/bin/node,/usr/local/bin/balena,push,Dashboard] length=4
[Debug]   Using build source directory: .
[Debug]   Pushing to cloud for application: Dashboard
/ Packaging the project source...[Debug]   docker-compose.yml file found at "/mnt/c/Users/steev/source/repos/github.com/browser"
[debug] Connecting to builder at https://builder.balena-cloud.com/v3/build?slug=steeve_s_organization%2Fdashboard&dockerfilePath=&emulated=false&nocache=false&headless=false
\ Uploading source package to balenaCloud[debug] received HTTP 200 OK
[debug] handling message: {"type":"metadata","resource":"buildLogId","value":1871099}
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Starting build for dashboard, user g_steeve_g_lambert"}
[Info]     Starting build for dashboard, user g_steeve_g_lambert
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Dashboard link: https://dashboard.balena-cloud.com/apps/1849440/devices"}
[Info]     Dashboard link: https://dashboard.balena-cloud.com/apps/1849440/devices
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Building on arm06"}
[Info]     Building on arm06
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Pulling previous images for caching purposes..."}
[Info]     Pulling previous images for caching purposes...
[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[32m[Success]\u001b[39m  Successfully pulled cache images"}
[Success]  Successfully pulled cache images
[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[35m[browser]\u001b[39m  [>                                                        ] 0%"}
[browser]  [>                                                        ] 0%
[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[35m[browser]\u001b[39m  [>                                                        ] 0%"}
[browser]  [>                                                        ] 0%
[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[35m[browser]\u001b[39m  [=>                                                       ] 1%"}
[browser]  [=>                                                       ] 1%
--REDACTED--
[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[35m[browser]\u001b[39m  [=========================================================>] 99%"}
[browser]  [=========================================================>] 99%
[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[35m[browser]\u001b[39m  [=========================================================] 100%"}
[browser]  [=========================================================] 100%
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Generating image deltas from release fe542cd5babf7b8869d6727dae539ae2 (id: 1871080)"}
[Info]     Generating image deltas from release fe542cd5babf7b8869d6727dae539ae2 (id: 1871080)
[debug] handling message: {"message":"\u001b[33m[Warning]\u001b[39m  Failed to generate deltas due to an internal error; will be generated on-demand"}
[Warning]  Failed to generate deltas due to an internal error; will be generated on-demand
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Uploading images"}
[Info]     Uploading images
[debug] handling message: {"message":"[==================================================>] 100%","replace":true}
[==================================================>] 100%[debug] handling message: {"message":"[==================================================>] 100%","replace":true}
[==================================================>] 100%[debug] handling message: {"type":"metadata","resource":"cursor","value":"erase"}
[debug] handling message: {"message":"\u001b[32m[Success]\u001b[39m  Successfully uploaded images"}
[Success]  Successfully uploaded images
[debug] handling message: {"message":"\u001b[31m[Error]\u001b[39m    Error:: It is necessary that each release that has a release version1 and has a status that is equal to \"success\" and is not invalidated, belongs to an application that owns exactly one release that has a release version2 that is equal to the release version1 and has a status that is equal to \"success\" and is not invalidated.","isError":true}
[Error]    Error:: It is necessary that each release that has a release version1 and has a status that is equal to "success" and is not invalidated, belongs to an application that owns exactly one release that has a release version2 that is equal to the release version1 and has 
a status that is equal to "success" and is not invalidated.
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Built on arm06"}
[Info]     Built on arm06
[debug] handling message: {"message":"\u001b[32m[Success]\u001b[39m  Release successfully created!"}
[Success]  Release successfully created!
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Release: \u001b[34m7c33c94475aa115ee82fc2c59863f866\u001b[39m (id: \u001b[32m1871099\u001b[39m)"}
[Info]     Release: 7c33c94475aa115ee82fc2c59863f866 (id: 1871099)
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     \u001b[90m┌─────────\u001b[39m\u001b[90m┬────────────\u001b[39m\u001b[90m┬─────────────────────┐\u001b[39m"}
[Info]     ┌─────────┬────────────┬─────────────────────┐
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     \u001b[90m│\u001b[39m \u001b[1mService\u001b[22m \u001b[90m│\u001b[39m \u001b[1mImage Size\u001b[22m \u001b[90m│\u001b[39m \u001b[1mBuild Time\u001b[22m          \u001b[90m│\u001b[39m"}
[Info]     │ Service │ Image Size │ Build Time          │
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     \u001b[90m├─────────\u001b[39m\u001b[90m┼────────────\u001b[39m\u001b[90m┼─────────────────────┤\u001b[39m"}
[Info]     ├─────────┼────────────┼─────────────────────┤
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     \u001b[90m│\u001b[39m browser \u001b[90m│\u001b[39m 887.52 MB  \u001b[90m│\u001b[39m 1 minute, 3 seconds \u001b[90m│\u001b[39m"}
[Info]     │ browser │ 887.52 MB  │ 1 minute, 3 seconds │
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     \u001b[90m└─────────\u001b[39m\u001b[90m┴────────────\u001b[39m\u001b[90m┴─────────────────────┘\u001b[39m"}
[Info]     └─────────┴────────────┴─────────────────────┘
[debug] handling message: {"message":"\u001b[36m[Info]\u001b[39m     Build finished in 1 minute, 43 seconds"}
[Info]     Build finished in 1 minute, 43 seconds
[debug] handling message: {"message":"\u001b[1m\u001b[34m\t\t\t    \\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t     \\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t      \\\\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t       \\\\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t        >\\/7\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t    _.-(6'  \\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t   (=___._/` \\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t        )  \\ |\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t       /   / |\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t      /    > /\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t     j    < _\\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t _.-' :      ``.\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t \\ r=._\\        `.\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t<`\\\\_  \\         .`-.\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t \\ r-7  `-. ._  ' .  `\\\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t  \\`,      `-.`7  7)   )\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t   \\/         \\|  \\'  / `-._\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t              ||    .'\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t               \\\\  (\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t                >\\  >\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t            ,.-' >.'\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t           <.'_.''\u001b[39m\u001b[22m\n\u001b[1m\u001b[34m\t\t\t             <'\u001b[39m\u001b[22m","isSuccess":true}
                            \
                             \
                              \\
                               \\
                                >\/7
                            _.-(6'  \
                           (=___._/` \
                                )  \ |
                               /   / |
                              /    > /
                             j    < _\
                         _.-' :      ``.
                         \ r=._\        `.
                        <`\\_  \         .`-.
                         \ r-7  `-. ._  ' .  `\
                          \`,      `-.`7  7)   )
                           \/         \|  \'  / `-._
                                      ||    .'
                                       \\  (
                                        >\  >
                                    ,.-' >.'
                                   <.'_.''
                                     <'
Remote build failed

RemoteBuildFailedError: Remote build failed
    at handleRemoteBuildStream (/usr/local/lib/node_modules/balena-cli/build/utils/remote-build.js:82:15)
    at processTicksAndRejections (node:internal/process/task_queues:94:5)
    at async Object.startRemoteBuild (/usr/local/lib/node_modules/balena-cli/build/utils/remote-build.js:63:13)
    at async PushCmd.pushToCloud (/usr/local/lib/node_modules/balena-cli/build/commands/push.js:79:27)
    at async PushCmd.run (/usr/local/lib/node_modules/balena-cli/build/commands/push.js:33:17)
    at async PushCmd._run (/usr/local/lib/node_modules/balena-cli/node_modules/@oclif/command/lib/command.js:43:20)
    at async Config.runCommand (/usr/local/lib/node_modules/balena-cli/node_modules/@oclif/config/lib/config.js:175:24)
    at async CustomMain.run (/usr/local/lib/node_modules/balena-cli/node_modules/@oclif/command/lib/main.js:27:9)
    at async CustomMain._run (/usr/local/lib/node_modules/balena-cli/node_modules/@oclif/command/lib/command.js:43:20)
    at async /usr/local/lib/node_modules/balena-cli/build/app.js:65:13
    at async Promise.all (index 1)
    at async oclifRun (/usr/local/lib/node_modules/balena-cli/build/app.js:83:5)
    at async Object.run (/usr/local/lib/node_modules/balena-cli/build/app.js:96:9)
    at async run (/usr/local/lib/node_modules/balena-cli/bin/balena:20:2)

Hi Steevegl :slight_smile:

I think what is happening is that in your balena.yml file the version variable is from a previous deployment, so that when you try to redeploy, your code thinks you have already deployed that version.

You either update the version every time you push code, or you can delete the version line from the balena.yml. You can see the piece of code I’m talking about in the original code on GitHub here: browser/balena.yml at 1feeac0dcc6a18360664063d923a9b3c70b36464 · balenablocks/browser · GitHub

The bit in the error code that indicates this is the problem is: Error:: It is necessary that each release that has a release version1 and has a status that is equal to “success” and is not invalidated, belongs to an application that owns exactly one release that has a release version2 that is equal to the release version1 and has a status that is equal to “success” and is not invalidated.

I hope this helps! Let me know if you have any other problems :slight_smile:

Thanks it’s works!

As a DevOps engineer I would say it’s a very bad idea to set a version in source code.

Thank you @steevegl for your feedback! You are right and we are working in order to reduce friction here.