Librenegade.so 오류

이미 이전에 llama 3.1 8B 모델로 양자화도 하고 아티팩트도 만들어서 실행도 확인했었는데요.
해당 모듈을 다시 실행시키니 librenegade.so를 찾을 수 없다는 오류가 발생하고 있습니다.

quickstart.py에 있는 아래 코드를 수행시키면

from furiosa_llm import LLM, SamplingParams

llm = LLM.load_artifact(“furiosa-ai/Llama-3.1-8B-Instruct-FP8”, devices=“npu:0”)

다음과 같은 오류가 발생하고 있습니다.

Exception has occurred: PanicException
called Result::unwrap() on an Err value: Runtime(Npu(Loading(DlOpen { desc: “librenegade.so: cannot open shared object file: No such file or directory” })))
File “/home/elicer/workspace/qickstart.py”, line 5, in
llm = LLM.load_artifact(“furiosa-ai/Llama-3.1-8B-Instruct-FP8”, devices=“npu:0”)
pyo3_runtime.PanicException: called Result::unwrap() on an Err value: Runtime(Npu(Loading(DlOpen { desc: “librenegade.so: cannot open shared object file: No such file or directory” })))

현재 환경은 아래와 같습니다.

(llama_ve310) (base) elicer@2481b7b6a418:/usr/local/lib$ pip list | grep furiosa
furiosa-llm 2025.3.1
furiosa-llm-models 2025.3.0
furiosa-model-compressor 2025.3.0
furiosa-model-compressor-impl 2025.3.0
furiosa-models-lang 2025.3.0
furiosa-native-compiler 2025.3.1
furiosa-native-llm-common 2025.3.1
furiosa-native-runtime 2025.3.1
furiosa-smi-py 2025.3.0
furiosa-torch-ext 2025.3.1

(llama_ve310) (base) elicer@2481b7b6a418:/usr/local/lib$ dpkg -l | grep furiosa
ii furiosa-compiler 2025.3.0-3 amd64 FuriosaAI NPU Compiler for DNN models
ii furiosa-driver-rngd 2025.3.0-3 amd64 FuriosaAI Renegade driver
ii furiosa-libsmi 2025.3.0-3 amd64 Furiosa AI’s System Management Interface
ii furiosa-pert-rngd 2025.3.0-3 amd64 Furiosa AI PERT for RNGD
ii furiosa-smi 2025.3.0-3 amd64 Furiosa AI’s System Management Interface CLI
ii furiosa-toolkit 0.11.0-3 amd64 Furiosa AI’s NPU management tools

librenegade.so를 찾아보니 해당 파일이 없어서.. gpt에 문의해 보니 furiosa-runtime 또는 furiosa-runtime-rngd를 설치하라고 해서.

sudo apt install furiosa-driver-rngd furiosa-pert-rngd

위의 명령을 수행시키면 아래와 같은 상태인데요

(llama_ve310) (base) elicer@2481b7b6a418:~/workspace$ sudo apt install furiosa-driver-rngd furiosa-pert-rngd
Reading package lists… Done
Building dependency tree… Done
Reading state information… Done
furiosa-pert-rngd is already the newest version (2025.3.1-3).
furiosa-driver-rngd is already the newest version (2025.3.1-3).
0 upgraded, 0 newly installed, 0 to remove and 214 not upgraded.

여러 작업을 시도하다 보니 메시지가 아래와 같이 변경된 상태입니다.

Exception has occurred: RuntimeError
Error: “libfuriosa_hal.so: cannot open shared object file: No such file or directory”
File “/home/elicer/workspace/qickstart.py”, line 2, in
from furiosa_llm import LLM, SamplingParams
RuntimeError: Error: “libfuriosa_hal.so: cannot open shared object file: No such file or directory”

이전에는 artfact 로드할 때 librenegade.so 가 없다고 오류가 나더니 지금은 furiosa_llm을 import할 때 오류가 발생하고 있습니다.
어떻게 처리해야 할까요?

안녕하세요?

불편 드려 죄송합니다. 연휴 등으로 답장이 조금 늦었습니다. 혹시 해당 환경에서 furiosa-smi info 등으로 장치가 보이는지 한번 확인 부탁드려도 될까요?

안녕하세요.
요청하신 정보는 다음과 같습니다.
(base) elicer@2481b7b6a418:~$ furiosa-smi info
±------±-----±-------±-----------------±-----------------±--------±--------±-------------+
| Index | Arch | Device | Firmware | PERT | Temp. | Power | PCI-BDF |
±------±-----±-------±-----------------±-----------------±--------±--------±-------------+
| 0 | rngd | npu6 | 2025.3.0+c097ea0 | 2025.3.1+52e5705 | 30.37°C | 35.52 W | 0000:bd:00.0 |
±------±-----±-------±-----------------±-----------------±--------±--------±-------------+
| 1 | rngd | npu7 | 2025.3.0+c097ea0 | 2025.3.1+52e5705 | 32.23°C | 36.48 W | 0000:be:00.0 |
±------±-----±-------±-----------------±-----------------±--------±--------±-------------+

참고로 현재 furiosa관련된 so 파일을 찾아봐도 없는 것 같습니다.

(llama_ve310) (base) elicer@2481b7b6a418:~$ find ./ libfuriosa_hal.so > /dev/null
find: ‘libfuriosa_hal.so’: No such file or directory

(llama_ve310) (base) elicer@2481b7b6a418:~$ find / libfuri*.so > /dev/null

find: ‘libfuri*.so’: No such file or directory

현재 quickstart.py를 수행시키면 아래와 같은 오류가 발생하고 있습니다.

Traceback (most recent call last):
File “/home/elicer/workspace/qickstart.py”, line 2, in
from furiosa_llm import LLM, SamplingParams
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/init.py”, line 8, in
from . import models as models
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/models/init.py”, line 1, in
from .metadata import (
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/models/metadata.py”, line 26, in
from furiosa_llm.optimum import AttentionType, OptimizationConfig, QDtype, QuantizationConfig
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/optimum/init.py”, line 3, in
from .modeling import AutoModelForCausalLM
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/optimum/modeling.py”, line 43, in
from furiosa_llm.models.quant import (
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/models/quant.py”, line 20, in
from furiosa_llm.optimum.types import QuantizationConfig
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/optimum/types.py”, line 413, in
class FuriosaConfig(BaseModel, frozen=True):
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/optimum/types.py”, line 427, in FuriosaConfig
components_versions: ComponentVersions = ComponentVersions.default(),
File “/home/elicer/workspace/llama_ve310/lib/python3.10/site-packages/furiosa_llm/optimum/types.py”, line 361, in default
import furiosa.native_runtime
RuntimeError: Error: “libfuriosa_hal.so: cannot open shared object file: No such file or directory”

혹시 몰라서 소스도 올립니다.

from furiosa_llm import LLM, SamplingParams
'# Load the Llama 3.1 8B Instruct model
llm = LLM.load_artifact(“furiosa-ai/Llama-3.1-8B-Instruct-FP8”, devices=“npu:0”)
'# You can specify various parameters for text generation
sampling_params = SamplingParams(min_tokens=10, top_p=0.3, top_k=100)
'# Prompt for the model
message = [{“role”: “user”, “content”: “What is the capital of France?”}]
message = [{“role”: “user”, “content”: “프랑스의 수도는 어디야?”}]
prompt = llm.tokenizer.apply_chat_template(message, tokenize=False)
’ # Generate text
response = llm.generate([prompt], sampling_params)
'# Print the output of the model
print(response[0].outputs[0].text)

정보 정리해 주셔서 감사합니다. 파악해보고 업데이트 최대한 빠르게 드리겠습니다.

주신 정보에 힌트가 있는 것 같습니다. 실제 장치는 npu:6, npu:7 이 있지만 npu:0을 지정하셨었는데요. 메뉴얼한 장치 설정을 아예 제거하거나 furiosa-smi로 확인하진 존재하는 장치인 npu:0, npu:7 로 지정하시면 해결 될 것 같습니다. (아마 기존에는 npu:0, npu:1 을 할당받아 사용하셔서 문제를 안 겪으셨을 것 같습니다)

llm = LLM.load_artifact(“furiosa-ai/Llama-3.1-8B-Instruct-FP8”, devices=“npu:0”)

그리고 위 케이스에 대해 아래 에러가 발생했는데요. 이것은 내부적으로 장치가 없으면 simulator를 찾기 때문에 발생하는 문제네요. ugly 한 에러 출력으로 인해 고생하셨을 것 같네요. 죄송합니다. 아래 문제는 해결하도록 하겠습니다. 리포트 감사합니다.

Exception has occurred: PanicException
called Result::unwrap() on an Err value: Runtime(Npu(Loading(DlOpen { desc: “librenegade.so: cannot open shared object file: No such file or directory” })))
File “/home/elicer/workspace/qickstart.py”, line 5, in
llm = LLM.load_artifact(“furiosa-ai/Llama-3.1-8B-Instruct-FP8”, devices=“npu:0”)
pyo3_runtime.PanicException: called Result::unwrap() on an Err value: Runtime(Npu(Loading(DlOpen { desc: “librenegade.so: cannot open shared object file: No such file or directory” })))

혹시 제가 위에서 제안 드린대로 해보시고 여전히 문제가 있으시면 말씀 주시면 감사하겠습니다.

2 Likes

답변 감사드립니다.
외근이 있어서 답변이 늦었습니다.

  1. 왜 npu가 바뀌었는지 잘 모르겠지만 말씀하신 바와 같이 아래와 같이 코드를 수정한 후 수행시켰습니다.
    llm = LLM.load_artifact(“furiosa-ai/Llama-3.1-8B-Instruct-FP8”, devices=“npu:6”)

수행했을 때 아래와 같이 동일한 메시지가 나오고 있습니다.

Exception has occurred: RuntimeError
Error: “libfuriosa_hal.so: cannot open shared object file: No such file or directory”
File “/home/elicer/workspace/quickstart.py”, line 2, in
from furiosa_llm import LLM, SamplingParams
RuntimeError: Error: “libfuriosa_hal.so: cannot open shared object file: No such file or directory”

환경을 다시 구축하기 위해 인스턴스를 종료했다가 다시 시작하면
여러가지가 변경되는 것 같아서요..
인스턴스를 재생성하지 않고 환경을 처음부터 구축해야 한다면
어떤 순서로 하는 것이 좋을 지 알려주시면 감사하겠습니다.
기존에 설치된 패키지들을 uninstall 하고 다시 설치만 하면 될까요?

답장이 조금 늦었습니다. 새로 환경을 할당할 때 장치 변경되어 위와 같이 새로 인스턴스를 구축할 때 문제를 겪으시는 것으로 추정됩니다.

또한, 위 에러 메시지는 죄송하게도 에러메시지가 정확하게 출력되지 않아서 발생하는 문제입니다. 리포트 해주신 덕분에 위 문제는 내부적으로 수정되어 다음 릴리즈에 포함될 예정입니다.

제 생각에 가장 간단한 해결 방법은 장치를 아예 지정하지 않으시면 furiosa-llm이 자동으로 찾아서 사용하게 됩니다.

다만 이 경우 기본 설정으로 가용한 장치를 모두 사용 할 수 있는 구성을 찾게 되는데요. 이는 필요에 따라 (굳이 가용한 장치를 모두 사용하는 문제가 아니라면 신경 안쓰셔도 됩니다) LLM.load_artifact()에 인자로 data_parallel_size (dp), pipeline_parallel_size (pp)를 조정하셔서 장치를 제한하시면 됩니다.

구체적으로 예를 들기 위해 llama 8b의 경우 보통은 tensor_parallel_size=8 (1 RNGD), pipeline_parallel_size=1로 설정하여 컴파일 하셨다고 가정하겠습니다. 이런 경우 장치가 2개 있고 장치를 아예 설정하지 않으시면 모든 장치를 사용하기 위해 기본적으로 tp=8, pp=1, dp=2 로 동작하게 됩니다.

안녕하세요?
제가 다른 일정이 있어서 테스트가 늦었습니다.
인스턴스를 새로 만들지 않고 이런 저런 작업을 해 보았지만…
결국은 인스턴스를 새로 만들고 설치를 다시 해서 해결했습니다.

말씀주신바와 같이 처음에 npu 지정 이슈였는데
이것 저것 수정하다 보니 제대로 작동을 안 한 것 같습니다. ㅠㅠ

현재는 인스턴스 재생성 후 처음부터 재설치해서
정상적으로 작동중입니다.

답변 감사합니다.

1 Like