lmstudio-ai / .github

34 stars 3 forks source link

Does not run in Ubuntu 22.04 (/usr/local/lib/libclblast.so.1 not found) #18

Closed luisvalenzuelar closed 5 months ago

luisvalenzuelar commented 5 months ago

Hi there, this is the error message I get when runnign the AppImage file:


Reading gpu_preferences at /home/NNN/.cache/lm-studio/gpu-preferences.json
13:26:09.506 › GPU Preferences: null
13:26:09.531 › GPU info: 00:02.0 VGA compatible controller: Intel Corporation TigerLake-LP GT2 [Iris Xe Graphics] (rev 01)

13:26:09.532 › Got GPU Type: intel
A JavaScript error occurred in the main process
Uncaught Exception:
Error: /usr/local/lib/libclblast.so.1: cannot open shared object file: No such file or directory
    at process.func [as dlopen] (node:electron/js2c/asar_bundle:2:1822)
    at Module._extensions..node (node:internal/modules/cjs/loader:1326:18)
    at Object.func [as .node] (node:electron/js2c/asar_bundle:2:1822)
    at Module.load (node:internal/modules/cjs/loader:1096:32)
    at Module._load (node:internal/modules/cjs/loader:937:12)
    at f._load (node:electron/js2c/asar_bundle:2:13330)
    at Module.require (node:internal/modules/cjs/loader:1120:19)
    at require (node:internal/modules/cjs/helpers:103:18)
    at 6829 (/tmp/.mount_LM_StuHcPhIi/resources/app/.webpack/main/index.js:2:1756)
    at r (/tmp/.mount_LM_StuHcPhIi/resources/app/.webpack/main/index.js:8:420150)

I have installed some libraries (libclblast1, libclblas-dev) to not avail. Any ideas?

luisvalenzuelar commented 5 months ago

There is a missing library, required at least for version LM_Studio-0.2.10-beta-v6. Here is the solution in Ubuntu 22.04:

#install the library
$ sudo apt-get install libclblast-dev
# find where the static library you just installed is located on your computer. If you dont know how to do it install plocate
$ sudo apt-get install plocate
$ locate libclblast.so.1
# In my case it was installed here: /usr/lib/x86_64-linux-gnu/libclblast.so.1
# now you just need to syslink these libraries, notice that LM Studio wants not only libclblast.so, but also libclblast.so.1, so here's the syslinks i've used:
$ sudo ln -s /usr/lib/x86_64-linux-gnu/libclblast.so.1 /usr/local/lib/libclblast.so.1
$ sudo ln -s /usr/lib/x86_64-linux-gnu/libclblast.so /usr/local/lib/libclblast.so

Source: Rovaris @ LM Studio Discord