Microsoft MVP성태의 닷넷 이야기
오류 유형: 981. dotnet 실행 시 No usable version of the libssl was found [링크 복사], [링크+제목 복사],
조회: 295
글쓴 사람
정성태 (seongtaejeong at gmail.com)
홈페이지
첨부 파일
 

dotnet 실행 시 No usable version of the libssl was found

아마도 환경적인 요인에서 오는 것 같은데요, .NET 8 런타임이 설치된 Ubuntu 24.04에서 .NET Core 2.0으로 만들어진 웹 애플리케이션을 실행 시 이런 오류가 발생했습니다.

$ dotnet /app/corecorelin/CoreCoreLin.dll
info: Microsoft.AspNetCore.DataProtection.KeyManagement.XmlKeyManager[0]
      User profile is available. Using '/home/kevin/.aspnet/DataProtection-Keys' as key repository; keys will not be encrypted at rest.
info: Microsoft.AspNetCore.DataProtection.KeyManagement.XmlKeyManager[58]
      Creating key {3f084640-c099-4da3-8d70-077af8fb5c33} with creation date 2025-08-19 06:50:46Z, activation date 2025-08-19 06:50:46Z, and expiration date 2025-11-17 06:50:46Z.
No usable version of the libssl was found
Aborted (core dumped)

검색해 보면,

No usable version of libssl was found #4749
; https://github.com/dotnet/core/issues/4749

"dotnet new" 명령어 실행 단계에서도 저 오류가 발생했다는 건데, 답변 중 하나를 보면 libssl.so.47.0.6을 /usr/lib/libssl.so.1.0.0로 링크해 해결했다고 합니다. 제 경우에는 libssl3.so 파일이 있어서,

$ ldconfig -p | grep libssl
        libssl3.so (libc6,x86-64) => /lib/x86_64-linux-gnu/libssl3.so
        libssl.so.3 (libc6,x86-64) => /lib/x86_64-linux-gnu/libssl.so.3

$ openssl version
OpenSSL 3.0.16 11 Feb 2025 (Library: OpenSSL 3.0.16 11 Feb 2025)

링크를 걸었으나,

$ sudo ln -s /lib/x86_64-linux-gnu/libssl.so.3 /usr/lib/libssl.so.1.0.0

$ dotnet /app/corecorelin/CoreCoreLin.dll
...[생략]...
Cannot get required symbol CRYPTO_add_lock from libssl
Aborted (core dumped)

$ sudo rm /usr/lib/libssl.so.1.0.0

(다른 오류로 바뀌긴 했지만) 실행이 되지 않았습니다. 다른 답변에 보면, 1.1.1 버전의 libssl을 설치하면 된다고 해서, 1.1.1f 버전도 설치해 보았는데,

$ wget http://security.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2.24_amd64.deb
$ sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2.24_amd64.deb

$ ldconfig -p | grep libssl
        libssl3.so (libc6,x86-64) => /lib/x86_64-linux-gnu/libssl3.so
        libssl.so.3 (libc6,x86-64) => /lib/x86_64-linux-gnu/libssl.so.3
        libssl.so.1.1 (libc6,x86-64) => /lib/x86_64-linux-gnu/libssl.so.1.1

$ sudo ln -s /lib/x86_64-linux-gnu/libssl.so.1.1 /usr/lib/libssl.so.1.0.0

$ dotnet /app/corecorelin/CoreCoreLin.dll
...[생략]...
Cannot get required symbol CRYPTO_add_lock from libssl
Aborted (core dumped)

$ sudo rm /usr/lib/libssl.so.1.0.0

마찬가지입니다. 혹시나 싶어 직접 빌드해 설치하는 것도 시도했지만,

wget https://www.openssl.org/source/openssl-1.1.1c.tar.gz
tar -xzvf openssl-1.1.1c.tar.gz
cd openssl-1.1.1c
./config
make
sudo make install  // (it puts it into /usr/local/lib so it doesn't mess with the rest of your system)

LD_LIBRARY_PATH="/usr/local/lib" dotnet /app/corecorelin/CoreCoreLin.dll

결국은 안 되었습니다.




.NET 8.0에서 호스팅해서 그럴까 싶어 .NET 2.0 SDK를 설치해 봤는데요,

.NET 다운로드
; https://dotnet.microsoft.com/download/dotnet

.NET Core 2.0 SDK
; https://builds.dotnet.microsoft.com/dotnet/Sdk/2.1.200/dotnet-sdk-2.1.200-linux-x64.tar.gz

wget https://builds.dotnet.microsoft.com/dotnet/Sdk/2.1.200/dotnet-sdk-2.1.200-linux-x64.tar.gz
mkdir -p $HOME/dotnet
tar xf dotnet-sdk-2.1.200-linux-x64.tar.gz -C $HOME/dotnet

"No usable version of the libssl was found" 오류는 여전히 발생했습니다. 게다가 이번에는 dotnet 실행 모듈 자체도 ICU 패키지와의 호환성에 문제가 있는지 실행이 안 됩니다.

// 환경 변수를 지정했는데도 icu 오류 발생

$ DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=1 ~/dotnet/dotnet --version
FailFast: Couldn't find a valid ICU package installed on the system. Set the configuration flag System.Globalization.Invariant to true if you want to run with no globalization support.

   at System.Environment.FailFast(System.String)
   at System.Globalization.GlobalizationMode.GetGlobalizationInvariantMode()
   at System.Globalization.GlobalizationMode..cctor()
   at System.Globalization.CultureData.CreateCultureWithInvariantData()
   at System.Globalization.CultureData.get_Invariant()
   at System.Globalization.CultureData.GetCultureData(System.String, Boolean)
   at System.Globalization.CultureInfo.InitializeFromName(System.String, Boolean)
   at System.Globalization.CultureInfo.Init()
   at System.Globalization.CultureInfo..cctor()
   at System.StringComparer..cctor()
   at System.AppDomainSetup.SetCompatibilitySwitches(System.Collections.Generic.IEnumerable`1<System.String>)
   at System.AppDomain.PrepareDataForSetup(System.String, System.AppDomainSetup, System.Security.Policy.Evidence, System.Security.Policy.Evidence, IntPtr, System.String, System.String[], System.String[])
Aborted (core dumped)




결국은 .NET 2.0으로 만들어진 웹 애플리케이션을 실행할 수 없었습니다. 대신, netcoreapp3.0 이상의 웹 애플리케이션은 정상적으로, 위의 환경에서 어떠한 변화도 없이 잘 실행됐습니다. 그런 의미에서 아마도 .NET 2.0 빌드 결과물에 포함된 특정 모듈이 libssl과 호환되지 않는 듯한데... 오늘은 여기까지만 하고 끝내겠습니다. ^^ 향후로 .NET Core 2.x 앱을 사용할 일이 없을 것이므로 더 이상의 분석은 의미도 없을 것 같기에. ^^

단지 한 가지 의미를 찾는다면, .NET 버전이 올라가면서 기존 앱들이 새로운 운영체제 환경에서는 실행되지 않을 수도 있다는 점을 인식한 정도가 되겠습니다. ^^




[이 글에 대해서 여러분들과 의견을 공유하고 싶습니다. 틀리거나 미흡한 부분 또는 의문 사항이 있으시면 언제든 댓글 남겨주십시오.]







[최초 등록일: ]
[최종 수정일: 8/21/2025]

Creative Commons License
이 저작물은 크리에이티브 커먼즈 코리아 저작자표시-비영리-변경금지 2.0 대한민국 라이센스에 따라 이용하실 수 있습니다.
by SeongTae Jeong, mailto:techsharer at outlook.com

비밀번호

댓글 작성자
 




... 16  17  18  19  [20]  21  22  23  24  25  26  27  28  29  30  ...
NoWriterDateCnt.TitleFile(s)
13529정성태1/15/202412623닷넷: 2202. C# - PublishAot의 glibc에 대한 정적 링킹하는 방법
13528정성태1/14/202413633Linux: 68. busybox 컨테이너에서 실행 가능한 C++, Go 프로그램 빌드
13527정성태1/14/202414091오류 유형: 892. Visual Studio - Failed to launch debug adapter. Additional information may be available in the output window.
13526정성태1/14/202414334닷넷: 2201. C# - Facebook 연동 / 사용자 탈퇴 처리 방법
13525정성태1/13/202412668오류 유형: 891. Visual Studio - Web Application을 실행하지 못하는 IISExpress
13524정성태1/12/202411894오류 유형: 890. 한국투자증권 KIS Developers OpenAPI - GW라우팅 중 오류가 발생했습니다.
13523정성태1/12/202413606오류 유형: 889. Visual Studio - error : A project with that name is already opened in the solution.
13522정성태1/11/202414486닷넷: 2200. C# - HttpClient.PostAsJsonAsync 호출 시 "Transfer-Encoding: chunked" 대신 "Content-Length" 헤더 처리
13521정성태1/11/202412497닷넷: 2199. C# - 한국투자증권 KIS Developers OpenAPI의 WebSocket Ping, Pong 처리
13520정성태1/10/202412503오류 유형: 888. C# - Unable to resolve service for type 'Microsoft.Extensions.ObjectPool.ObjectPool`....' [1]
13519정성태1/10/202411757닷넷: 2198. C# - Reflection을 이용한 ClientWebSocket의 Ping 호출파일 다운로드1
13518정성태1/9/202413414닷넷: 2197. C# - ClientWebSocket의 Ping, Pong 처리
13517정성태1/8/202411526스크립트: 63. Python - 공개 패키지를 이용한 위성 이미지 생성 (pystac_client, odc.stac)
13516정성태1/7/202413451닷넷: 2196. IIS - AppPool의 "Disable Overlapped Recycle" 옵션의 부작용
13515정성태1/6/202411754닷넷: 2195. async 메서드 내에서 C# 7의 discard 구문 활용 사례 [1]
13514정성태1/5/202411720개발 환경 구성: 702. IIS - AppPool의 "Disable Overlapped Recycle" 옵션
13513정성태1/5/202413207닷넷: 2194. C# - WebActivatorEx / System.Web의 PreApplicationStartMethod 특성
13512정성태1/4/202413979개발 환경 구성: 701. IIS - w3wp.exe 프로세스의 ASP.NET 런타임을 항상 Warmup 모드로 유지하는 preload Enabled 설정
13511정성태1/4/202413331닷넷: 2193. C# - ASP.NET Web Application + OpenAPI(Swashbuckle) 스펙 제공
13510정성태1/3/202413131닷넷: 2192. C# - 특정 실행 파일이 있는지 확인하는 방법 (Linux)
13509정성태1/3/202414223오류 유형: 887. .NET Core 2 이하의 프로젝트에서 System.Runtime.CompilerServices.Unsafe doesn't support netcoreapp2.0.
13508정성태1/3/202415941오류 유형: 886. ORA-28000: the account is locked
13507정성태1/2/202413680닷넷: 2191. C# - IPGlobalProperties를 이용해 netstat처럼 사용 중인 Socket 목록 구하는 방법파일 다운로드1
13506정성태12/29/202312262닷넷: 2190. C# - 닷넷 코어/5+에서 달라지는 System.Text.Encoding 지원
13505정성태12/27/202316040닷넷: 2189. C# - WebSocket 클라이언트를 닷넷으로 구현하는 예제 (System.Net.WebSockets)파일 다운로드1
13504정성태12/27/202315278닷넷: 2188. C# - ASP.NET Core SignalR로 구현하는 채팅 서비스 예제파일 다운로드1
... 16  17  18  19  [20]  21  22  23  24  25  26  27  28  29  30  ...