Why nRF Connect for Desktop always tries to copy nrfutil.exe to installed directory

Hi,

I have used nRF Connect for very long time, and have just upgraded to v5.0.1. The software seems to use a sandbox tech and restores nrfutil.exe to its default version which is 4.43MB. The problem is I can't update nrfutil core in nRF Connect Apps (such as Power Profiler). It returns the following error

2024-07-10T06:38:10.946Z ERROR Error while updated nrfutil core
2024-07-10T06:38:17.355Z ERROR Error: Failed to bootstrap core functionality before executing command.

Failed to install package

  C:\Users\colin\AppData\Roaming\nrfconnect\nrfutil-
sandboxes\device\2.1.1\bootstrap\nrfutil-core-install-HbZpG1\nrfutil-x86_64-pc-
windows-msvc-7.12.0.tar.gz

using nrfutil command extracted from the same tarball.

See the details below for further information on the error.

Caused by:
    Failed to run command: "C:\\Users\\colin\\AppData\\Roaming\\nrfconnect\\nrfutil-sandboxes\\device\\2.1.1\\bootstrap\\nrfutil-core-install-HbZpG1\\nrfutil-x86_64-pc-windows-msvc-7.12.0\\data\\bin\\nrfutil.exe" "self-upgrade --from-tarball C:\\Users\\colin\\AppData\\Roaming\\nrfconnect\\nrfutil-sandboxes\\device\\2.1.1\\bootstrap\\nrfutil-core-install-HbZpG1\\nrfutil-x86_64-pc-windows-msvc-7.12.0.tar.gz"
    
    Error: Failed to install from tarball C:\Users\colin\AppData\Roaming\nrfconnect\nrfutil-sandboxes\device\2.1.1\bootstrap\nrfutil-core-install-HbZpG1\nrfutil-x86_64-pc-windows-msvc-7.12.0.tar.gz
    
    Caused by:
        0: Could not unpack package tarball

2024-07-10T06:38:17.355Z ERROR         1: failed to create `Z:\Cache\Temp\.tmpLCSG82\nrfutil-x86_64-pc-windows-msvc-7.12.0`
        2: 系统找不到指定的文件。 (os error 2) while canonicalizing Z:\Cache\Temp\.tmpLCSG82

I then have to manually copy nrfutil.exe from C:\Users\colin\AppData\Roaming\nrfconnect\nrfutil-sandboxes\device\2.1.1\tmp\ to C:\Users\colin\AppData\Roaming\nrfconnect\ to run the Apps properly. But next time I open nRF Connect Launcher everything restores to default. Please advice how I can fix this issue or just disable sandbox feature. Many appreciates.

I'm currently running Windows10 Home edition 22H2

  • Hi,

    The problem is I can't update nrfutil core in nRF Connect Apps (such as Power Profiler). It returns the following error

    Could you tell me how you tried this?

    Could you also tell me your nRF Command Line tools version?

    Regards,

    Priyanka

  • Hi,

    The nRF Command Line tools version is 10.24.2, which is shown below.

    C:\Users\colin> nrfjprog --version
    nrfjprog version: 10.24.2 external
    JLinkARM.dll version: 7.94e

    What I did is simply install nRF Command Line tools, followed by nRF Connect Desktop v5.0.1 x64 (also tried other version above v4.4) and JLink v7.94e(bundled with current version).

    Then open Power Profiler in nRF Connect for Desktop gave the above error.

  • Hi,

    I am not able to replicate this unfortunately. But could you try to manually update the nrfutil and see if this helps you?

    Download the latest version of nrfutil from the Nordic Semiconductor GitHub repository. Then extract the downloaded files manually to a temporary directory. Replace the nrfutil.exe file in C:\Users\colin\AppData\Roaming\nrfconnect with the new version.

    -Priyanka

  • Hi,

    Thank you for your quick response. I'm afraid the solution won't help because the repository is deprecated from Sep. 2022. The nRF Connect Desktop downloads the nrfutil from the official site.

    I've temporarily bypassed the problem by manually copy nrfutil.exe every time nRF Connect launches, though it's quite inconvenient.

    I'll wait and see if anyone encountered this problem.

  • Hi! I also am experiencing the same error.
    Maybe a small details can help in this case: I am using a RAM-disk (ImDisk) and so it is probably the case also for the OP.
    As a result, my temp folder is in another drive with respect of C:\. In my case is in R:\Temp, for the OP is in Z:\Cache\Temp.
    Can this help to address the issue?

    In the meantime I've created a small .bat file to be used before launching any apps from the nRF Connect for Desktop.


    @echo off
    set source="%USERPROFILE%\AppData\Roaming\nrfconnect\nrfutil-sandboxes\device\2.1.1\tmp\nrfutil.exe"
    set target="%USERPROFILE%\AppData\Roaming\nrfconnect"
    copy %source% %target% > nul
    echo nrfutil.exe  has been copied successfully!
    pause

Related