簡體   English   中英

gdal 似乎在 ArchLinux 服務器上的 RStudio-Server 中的 install.packages("sf") 期間導致非法操作

[英]gdal seems to cause an illegal operation during install.packages("sf") within RStudio-Server on a ArchLinux server

我最近開始使用舊服務器。
我們已經在設備上安裝了 AchLinux 和 RStudio 服務器(2022.07.999 build 999)。 服務器運行雙 Xeon E5-2470 和 48GB RAM。

我正在嘗試install.packages("sf")並在安裝過程中得到以下信息:

** testing if installed package can be loaded from temporary location

 *** caught illegal operation ***
address 0x55b94289a1e0, cause 'unknown'

Traceback:
 1: CPL_gdal_init()
 2: load_gdal()
 3: fun(libname, pkgname)
 4: doTryCatch(return(expr), name, parentenv, handler)
 5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
 6: tryCatchList(expr, classes, parentenv, handlers)
 7: tryCatch(fun(libname, pkgname), error = identity)
 8: runHook(".onLoad", env, package.lib, package)
 9: loadNamespace(package, lib.loc)
10: doTryCatch(return(expr), name, parentenv, handler)
11: tryCatchOne(expr, names, parentenv, handlers[[1L]])
12: tryCatchList(expr, classes, parentenv, handlers)
13: tryCatch({    attr(package, "LibPath") <- which.lib.loc    ns <- loadNamespace(package, lib.loc)    env <- attachNamespace(ns, pos = pos, deps, exclude, include.only)}, error = function(e) {    P <- if (!is.null(cc <- conditionCall(e)))         paste(" in", deparse(cc)[1L])    else ""    msg <- gettextf("package or namespace load failed for %s%s:\n %s",         sQuote(package), P, conditionMessage(e))    if (logical.return && !quietly)         message(paste("Error:", msg), domain = NA)    else stop(msg, call. = FALSE, domain = NA)})
14: library(pkg_name, lib.loc = lib, character.only = TRUE, logical.return = TRUE)
15: withCallingHandlers(expr, packageStartupMessage = function(c) tryInvokeRestart("muffleMessage"))
16: suppressPackageStartupMessages(library(pkg_name, lib.loc = lib,     character.only = TRUE, logical.return = TRUE))
17: doTryCatch(return(expr), name, parentenv, handler)
18: tryCatchOne(expr, names, parentenv, handlers[[1L]])
19: tryCatchList(expr, classes, parentenv, handlers)
20: tryCatch(expr, error = function(e) {    call <- conditionCall(e)    if (!is.null(call)) {        if (identical(call[[1L]], quote(doTryCatch)))             call <- sys.call(-4L)        dcall <- deparse(call, nlines = 1L)        prefix <- paste("Error in", dcall, ": ")        LONG <- 75L        sm <- strsplit(conditionMessage(e), "\n")[[1L]]        w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")        if (is.na(w))             w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],                 type = "b")        if (w > LONG)             prefix <- paste0(prefix, "\n  ")    }    else prefix <- "Error : "    msg <- paste0(prefix, conditionMessage(e), "\n")    .Internal(seterrmessage(msg[1L]))    if (!silent && isTRUE(getOption("show.error.messages"))) {        cat(msg, file = outFile)        .Internal(printDeferredWarnings())    }    invisible(structure(msg, class = "try-error", condition = e))})
21: try(suppressPackageStartupMessages(library(pkg_name, lib.loc = lib,     character.only = TRUE, logical.return = TRUE)))
22: tools:::.test_load_package("sf", "/home/trevor/R/x86_64-pc-linux-gnu-library/4.2/00LOCK-sf/00new")
An irrecoverable exception occurred. R is aborting now ...
ERROR: loading failed
* removing ‘/home/trevor/R/x86_64-pc-linux-gnu-library/4.2/sf’
Warning in install.packages :
  installation of package ‘sf’ had non-zero exit status

如果我install.packages("rgdal")會發生類似的錯誤。

我相信基於上述情況,ArchLinux中的gdal package存在問題,使用pacman安裝,我們已經安裝了package的所有可選部分,但錯誤仍然存在。

我們已經安裝了gdal的V3.5.0-4,如下圖:

pacman -Qi gdal
Name            : gdal
Version         : 3.5.0-4
Description     : A translator library for raster and vector geospatial data formats
Architecture    : x86_64
URL             : https://gdal.org/
Licenses        : custom
Groups          : None
Provides        : None
Depends On      : proj  blosc  crypto++  curl  libdeflate  expat  libfreexl  geos  libgeotiff  giflib  libjpeg-turbo
                  json-c  xz  libxml2  lz4  unixodbc  ocl-icd  openssl  pcre2  libpng  qhull  libspatialite  sqlite
                  libtiff  xerces-c  zlib  zstd
Optional Deps   : arrow: Arrow/Parquet support [installed]
                  cfitsio: FITS support [installed]
                  hdf5: HDF5 support [installed]
                  libheif: HEIF support [installed]
                  mariadb-libs: MySQL support [installed]
                  netcdf: netCDF support [installed]
                  openexr: EXR support [installed]
                  openjpeg2: JP2 support [installed]
                  podofo: PDF support [installed]
                  poppler: PDF support [installed]
                  postgresql-libs: PostgreSQL support [installed]
                  libwebp: WebP support [installed]
Required By     : python-gdal
Optional For    : None
Conflicts With  : None
Replaces        : None
Installed Size  : 27.98 MiB
Packager        : Bruno Pagani <archange@archlinux.org>
Build Date      : Fri Jul 1 21:44:46 2022
Install Date    : Sun Jul 24 16:22:48 2022
Install Reason  : Explicitly installed
Install Script  : No
Validated By    : Signature

任何人都可以幫助解決這個錯誤嗎?

我有同樣的問題。 我不知道如何處理它。 上次更新后,GDAL 升級到版本。 3.5.1。 並開始崩潰。 這就是依賴 gdal 的 R 包(sf、terra、rgdal 等)以及 QGIS 不起作用的原因。

一些 gdal 二進制文件(例如 gdal-config)仍然可以工作,但其中大多數會給出錯誤“非法指令(核心轉儲)”。

我的系統:

OS: Manjaro 21.3.6 Ruah
 Kernel: x86_64 Linux 5.15.57-2-MANJARO
 Uptime: 26m
 Packages: 1469
 Shell: bash
 Resolution: 1920x1080
 DE: Xfce4
 WM: Xfwm4
 WM Theme: Matcha-sea
 GTK Theme: Matcha-sea [GTK2]
 Icon Theme: Papirus-Maia
 Font: Noto Sans 10
 Disk: 1,5T / 6,8T (23%)
 CPU: AMD FX-8350 Eight-Core @ 8x 4GHz
 GPU: AMD RS780 (DRM 2.50.0 / 5.15.57-2-MANJARO, LLVM 14.0.6)
 RAM: 1829MiB / 19485MiB

核心轉儲信息:

    PID: 2333 (gdalinfo)
           UID: 1000 (rstanislav)
           GID: 1000 (rstanislav)
        Signal: 4 (ILL)
     Timestamp: Tue 2022-08-02 13:33:42 MSK (5min ago)
  Command Line: gdalinfo
    Executable: /usr/bin/gdalinfo
 Control Group: /user.slice/user-1000.slice/session-2.scope
          Unit: session-2.scope
         Slice: user-1000.slice
       Session: 2
     Owner UID: 1000 (rstanislav)
       Boot ID: 6b3e5ea1666440239afb43c4a246b953
    Machine ID: 6313df66156547e292fedaf552861e30
      Hostname: rstanislav-ipen
       Storage: /var/lib/systemd/coredump/core.gdalinfo.1000.6b3e5ea1666440239afb43c4a246b953.2333.1659436422>
     Disk Size: 743.6K
       Message: Process 2333 (gdalinfo) of user 1000 dumped core.
                
                Module linux-vdso.so.1 with build-id 125b0285aa529b1b1396ff79a856cc580f53371b
                Module libgflags.so.2.2 with build-id 7f92dc764545b3d8e058f547553713232168c9db
                Module libprotobuf.so.32 with build-id 86a9fa3c8369df69f01ddb2fb38c14307b91773d
                Module libthrift-0.16.0.so with build-id c3b31b7dd733754897f96dc1b0919b8ea6446c

一些谷歌結果假設這樣的錯誤可能是由於 CPU 不支持引起的,但我不知道如何確認。 無論如何,我的lscpu:

Архитектура:             x86_64
  CPU op-mode(s):        32-bit, 64-bit
  Address sizes:         48 bits physical, 48 bits virtual
  Порядок байт:          Little Endian
CPU(s):                  8
  On-line CPU(s) list:   0-7
ID прроизводителя:       AuthenticAMD
  Имя модели:            AMD FX(tm)-8350 Eight-Core Processor
    Семейство ЦПУ:       21
    Модель:              2
    Thread(s) per core:  2
    Ядер на сокет:       4
    Сокетов:             1
    Степпинг:            0
    Frequency boost:     enabled
    CPU(s) scaling MHz:  37%
    CPU max MHz:         4000,0000
    CPU min MHz:         1400,0000
    BogoMIPS:            8003.18
    Флаги:               fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx f
                         xsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good no
                         pl nonstop_tsc cpuid extd_apicid aperfmperf pni pclmulqdq monitor ssse3 fma cx16 sse4
                         _1 sse4_2 popcnt aes xsave avx f16c lahf_lm cmp_legacy svm extapic cr8_legacy abm sse
                         4a misalignsse 3dnowprefetch osvw ibs xop skinit wdt lwp fma4 tce nodeid_msr tbm topo
                         ext perfctr_core perfctr_nb cpb hw_pstate ssbd ibpb vmmcall bmi1 arat npt lbrv svm_lo
                         ck nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold
Virtualization features: 
  Виртуализация:         AMD-V
Caches (sum of all):     
  L1d:                   128 KiB (8 instances)
  L1i:                   256 KiB (4 instances)
  L2:                    8 MiB (4 instances)
  L3:                    8 MiB (1 instance)
NUMA:                    
  NUMA node(s):          1
  NUMA node0 CPU(s):     0-7
Vulnerabilities:         
  Itlb multihit:         Not affected
  L1tf:                  Not affected
  Mds:                   Not affected
  Meltdown:              Not affected
  Mmio stale data:       Not affected
  Retbleed:              Mitigation; untrained return thunk; SMT vulnerable
  Spec store bypass:     Mitigation; Speculative Store Bypass disabled via prctl and seccomp
  Spectre v1:            Mitigation; usercopy/swapgs barriers and __user pointer sanitization
  Spectre v2:            Mitigation; Retpolines, IBPB conditional, STIBP disabled, RSB filling
  Srbds:                 Not affected
  Tsx async abort:       Not affected

問題是箭頭 package。 https://github.com/apache/arrow/issues/12681

解決方案:根據 CPU 支持的指令集,使用 -DARROW_SIMD_LEVEL=SSE4_2 或 -DARROW_SIMD_LEVEL=NONE 標志手動重建箭頭 package

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM