Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Segmentation fault when running on Ubuntu, but not when using -L #262

Open
HoorayJorge opened this issue Jan 14, 2022 · 3 comments
Open

Comments

@HoorayJorge
Copy link

HoorayJorge commented Jan 14, 2022

[04:28:33] Started sgminer 0.8.1-0
[04:28:33] * using Jansson 2.11dlerror: libamdocl-orca32.so: cannot open shared object file: No such file or directory
                                                                                                                      ./run_allium.sh: line 8: 18380 Segmentation fault

Original config -

#!/bin/bash
export GPU_FORCE_64BIT_PTR=0
export GPU_USE_SYNC_OBJECTS=1
export GPU_MAX_ALLOC_PERCENT=100
export GPU_SINGLE_ALLOC_PERCENT=100
export GPU_MAX_HEAP_SIZE=100

./sgminer -k allium_navi -o stratum+tcp://freshgarlicblocks.net:3032 -u GeVxW6scnydU7RhJZfCTr7eHXmxRFZccrB.donate -p x --difficulty-multiplier 0.5 -I 23

Working config

#!/bin/bash
export GPU_FORCE_64BIT_PTR=0
export GPU_USE_SYNC_OBJECTS=1
export GPU_MAX_ALLOC_PERCENT=100
export GPU_SINGLE_ALLOC_PERCENT=100
export GPU_MAX_HEAP_SIZE=100

./sgminer -k allium_navi -o stratum+tcp://freshgarlicblocks.net:3032 -u GeVxW6scnydU7RhJZfCTr7eHXmxRFZccrB.donate -p x --difficulty-multiplier 0.5 -I 23 -L log.txt

Adding logging to output file, and the miner start properly.

clinfo

dlerror: libamdocl-orca32.so: cannot open shared object file: No such file or directory
Number of platforms                               1
  Platform Name                                   AMD Accelerated Parallel Processing
  Platform Vendor                                 Advanced Micro Devices, Inc.
  Platform Version                                OpenCL 2.1 AMD-APP (3180.7)
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd cl_amd_event_callback cl_amd_offline_devices 
  Platform Host timer resolution                  1ns
  Platform Extensions function suffix             AMD

  Platform Name                                   AMD Accelerated Parallel Processing
Number of devices                                 1
  Device Name                                     gfx1032
  Device Vendor                                   Advanced Micro Devices, Inc.
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 2.0 AMD-APP (3180.7)
  Driver Version                                  3180.7 (PAL,LC)
  Device OpenCL C Version                         OpenCL C 2.0 
  Device Type                                     GPU
  Device Board Name (AMD)                         Unknown AMD GPU
  Device Topology (AMD)                           PCI-E, 03:00.0
  Device Profile                                  FULL_PROFILE
  Device Available                                Yes
  Compiler Available                              Yes
  Linker Available                                Yes
  Max compute units                               16
  SIMD per compute unit (AMD)                     4
  SIMD width (AMD)                                32
  SIMD instruction width (AMD)                    1
  Max clock frequency                             1150MHz
  Graphics IP (AMD)                               10.32
  Device Partition                                (core)
    Max number of sub-devices                     16
    Supported partition types                     None
  Max work item dimensions                        3
  Max work item sizes                             1024x1024x1024
  Max work group size                             256
  Preferred work group size (AMD)                 256
  Max work group size (AMD)                       1024
  Preferred work group size multiple              32
  Wavefront width (AMD)                           32
  Preferred / native vector sizes                 
    char                                                 4 / 4       
    short                                                2 / 2       
    int                                                  1 / 1       
    long                                                 1 / 1       
    half                                                 1 / 1        (cl_khr_fp16)
    float                                                1 / 1       
    double                                               1 / 1        (cl_khr_fp64)
  Half-precision Floating-point support           (cl_khr_fp16)
    Denormals                                     No
    Infinity and NANs                             No
    Round to nearest                              No
    Round to zero                                 No
    Round to infinity                             No
    IEEE754-2008 fused multiply-add               No
    Support is emulated in software               No
  Single-precision Floating-point support         (core)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  Yes
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              8573157376 (7.984GiB)
  Global free memory (AMD)                        8306688 (7.922GiB)
  Global memory channels (AMD)                    4
  Global memory banks per channel (AMD)           4
  Global memory bank width (AMD)                  256 bytes
  Error Correction support                        No
  Max memory allocation                           8304721920 (7.734GiB)
  Unified memory for Host and Device              No
  Shared Virtual Memory (SVM) capabilities        (core)
    Coarse-grained buffer sharing                 Yes
    Fine-grained buffer sharing                   Yes
    Fine-grained system sharing                   No
    Atomics                                       No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       2048 bits (256 bytes)
  Preferred alignment for atomics                 
    SVM                                           0 bytes
    Global                                        0 bytes
    Local                                         0 bytes
  Max size for global variable                    7474249728 (6.961GiB)
  Preferred total size of global vars             8573157376 (7.984GiB)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        16384 (16KiB)
  Global Memory cache line size                   64 bytes
  Image support                                   Yes
    Max number of samplers per kernel             16
    Max size for 1D images from buffer            134217728 pixels
    Max 1D or 2D image array size                 2048 images
    Base address alignment for 2D image buffers   256 bytes
    Pitch alignment for 2D image buffers          256 pixels
    Max 2D image size                             16384x16384 pixels
    Max 3D image size                             2048x2048x2048 pixels
    Max number of read image args                 128
    Max number of write image args                64
    Max number of read/write image args           64
  Max number of pipe args                         16
  Max active pipe reservations                    16
  Max pipe packet size                            4009754624 (3.734GiB)
  Local memory type                               Local
  Local memory size                               65536 (64KiB)
  Local memory syze per CU (AMD)                  65536 (64KiB)
  Local memory banks (AMD)                        32
  Max number of constant args                     8
  Max constant buffer size                        8304721920 (7.734GiB)
  Preferred constant buffer size (AMD)            16384 (16KiB)
  Max size of kernel argument                     1024
  Queue properties (on host)                      
    Out-of-order execution                        No
    Profiling                                     Yes
  Queue properties (on device)                    
    Out-of-order execution                        Yes
    Profiling                                     Yes
    Preferred size                                262144 (256KiB)
    Max size                                      8388608 (8MiB)
  Max queues on device                            1
  Max events on device                            1024
  Prefer user sync for interop                    Yes
  Number of P2P devices (AMD)                     0
  P2P devices (AMD)                               <printDeviceInfo:144: get number of CL_DEVICE_P2P_DEVICES_AMD : error -30>
  Profiling timer resolution                      1ns
  Profiling timer offset since Epoch (AMD)        1642112772124687777ns (Fri Jan 14 00:26:12 2022)
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
    Thread trace supported (AMD)                  Yes
    Number of async queues (AMD)                  4
    Max real-time compute queues (AMD)            1
    Max real-time compute units (AMD)             0
  printf() buffer size                            4194304 (4MiB)
  Built-in kernels                                
  Device Extensions                               cl_khr_fp64 cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_int64_base_atomics cl_khr_int64_extended_atomics cl_khr_3d_image_writes cl_khr_byte_addressable_store cl_khr_fp16 cl_khr_gl_sharing cl_khr_gl_depth_images cl_amd_device_attribute_query cl_amd_media_ops cl_amd_media_ops2 cl_khr_image2d_from_buffer cl_khr_subgroups cl_khr_gl_event cl_khr_depth_images cl_khr_mipmap_image cl_khr_mipmap_image_writes cl_amd_copy_buffer_p2p 

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  No platform
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   No platform
  clCreateContext(NULL, ...) [default]            No platform
  clCreateContext(NULL, ...) [other]              Success [AMD]
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  Success (1)
    Platform Name                                 AMD Accelerated Parallel Processing
    Device Name                                   gfx1032
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  Success (1)
    Platform Name                                 AMD Accelerated Parallel Processing
    Device Name                                   gfx1032
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  Success (1)
    Platform Name                                 AMD Accelerated Parallel Processing
    Device Name                                   gfx1032

rocm-smi

========================        ROCm System Management Interface        ========================
================================================================================================
GPU[0] 		: GPU ID: 0x73ff
================================================================================================
================================================================================================
GPU[0] 		: Temperature: 33.0c
================================================================================================
================================================================================================
GPU[0] 		: GPU Clock Level: 1 (0Mhz)
GPU[0] 		: GPU Memory Clock Level: 3 (1150Mhz)
GPU[0] 		: PCIE Clock Level: 1 (8.0GT/s, x8 619Mhz)
================================================================================================
================================================================================================
GPU[0] 		: Fan Level: 175 (68.63)%
================================================================================================
================================================================================================
GPU[0] 		: Current Performance Level: manual
================================================================================================
================================================================================================
GPU[0] 		: Current GPU OverDrive value: 0%
================================================================================================
================================================================================================
GPU[0] 		: Current GPU Memory OverDrive value: 0%
================================================================================================
================================================================================================
GPU[0] 		: Max Graphics Package Power: 140.0W
================================================================================================
================================================================================================
GPU[0] 		: 
GPU[0] 		: PROFILE_INDEX(NAME) CLOCK_TYPE(NAME) FPS MinFreqType MinActiveFreqType MinActiveFreq BoosterFreqType BoosterFreq PD_Data_limit_c PD_Data_error_coeff PD_Data_error_rate_coeff
GPU[0] 		:  0 BOOTUP_DEFAULT :
GPU[0] 		:                     0(       GFXCLK)       0       5       1       0       4     800 4587520  -65536       0
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0 3276800   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       1       0       4     800  327680  -65536       0
GPU[0] 		:  1 3D_FULL_SCREEN :
GPU[0] 		:                     0(       GFXCLK)       0       5       1       0       4     650 4587520   -3276  -65536
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0  655360   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       4     850       4     800  327680  -65536       0
GPU[0] 		:  2   POWER_SAVING :
GPU[0] 		:                     0(       GFXCLK)       0       5       1       0       3       0 5898240  -65536       0
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0 3407872   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       1       0       3       0 1966080  -65536       0
GPU[0] 		:  3          VIDEO :
GPU[0] 		:                     0(       GFXCLK)       0       5       1       0       4     500 4587520  -65536       0
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0 3473408   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       1       0       4     500 1966080  -65536       0
GPU[0] 		:  4             VR :
GPU[0] 		:                     0(       GFXCLK)       0       5       4    1000       1       0 3932160       0       0
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0  655360   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       1       0       4     800  327680  -65536       0
GPU[0] 		:  5        COMPUTE*:
GPU[0] 		:                     0(       GFXCLK)       0       5       1       0       4     800 4587520  -65536       0
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0 3276800   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       1       0       4     800  327680  -65536       0
GPU[0] 		:  6         CUSTOM :
GPU[0] 		:                     0(       GFXCLK)       0       5       1       0       4     800 4587520  -65536       0
GPU[0] 		:                     1(       SOCCLK)       0       5       1       0       1       0 3276800   -6553   -6553
GPU[0] 		:                     2(        MEMLK)       0       5       1       0       4     800  327680  -65536       0
================================================================================================
================================================================================================
GPU[0] 		: Average Graphics Package Power: 17.0W
================================================================================================
================================================================================================
GPU[0] 		: Supported GPU clock frequencies on GPU0
GPU[0] 		: 0: 500Mhz 
GPU[0] 		: 1: 700Mhz *
GPU[0] 		: 2: 1150Mhz 
GPU[0] 		: 
GPU[0] 		: Supported GPU Memory clock frequencies on GPU0
GPU[0] 		: 0: 96Mhz 
GPU[0] 		: 1: 541Mhz 
GPU[0] 		: 2: 675Mhz 
GPU[0] 		: 3: 1150Mhz *
GPU[0] 		: 
GPU[0] 		: Supported PCIE clock frequencies on GPU0
GPU[0] 		: 0: 2.5GT/s, x1 81Mhz 
GPU[0] 		: 1: 8.0GT/s, x8 619Mhz *
GPU[0] 		: 
================================================================================================
================================================================================================
GPU[0] 		: Current GPU use: 0%
================================================================================================
================================================================================================
GPU[0] 		: WARNING: Unable to read /sys/class/drm/card0/device/pcie_bw
GPU[0] 		: Cannot get PCIe bandwidth
================================================================================================
========================               End of ROCm SMI Log              ========================

lshw -C display

*-display                 
       description: VGA compatible controller
       product: Navi 23 [Radeon RX 6600/6600 XT/6600M]
       vendor: Advanced Micro Devices, Inc. [AMD/ATI]
       physical id: 0
       bus info: pci@0000:03:00.0
       version: c1
       width: 64 bits
       clock: 33MHz
       capabilities: pm pciexpress msi vga_controller bus_master cap_list rom
       configuration: driver=amdgpu latency=0
       resources: irq:136 memory:d0000000-dfffffff memory:e0000000-e01fffff ioport:f000(size=256) memory:fcc00000-fccfffff memory:c0000-dffff

driver package

Package: amdgpu-pro
Version: 21.30-1286092
Priority: optional
Section: metapackages
Maintainer: Advanced Micro Devices (AMD) <slava.grigorev@amd.com>
Installed-Size: 17,4 kB
Depends: amdgpu (= 21.30-1286092), amdgpu-pro-core (= 21.30-1286092), libgl1-amdgpu-pro-glx (= 21.30-1286092), libegl1-amdgpu-pro (= 21.30-1286092), libgles2-amdgpu-pro (= 21.30-1286092), libglapi1-amdgpu-pro (= 21.30-1286092), libgl1-amdgpu-pro-ext (= 21.30-1286092), libgl1-amdgpu-pro-dri (= 21.30-1286092), libgl1-amdgpu-pro-appprofiles (= 21.30-1286092)
Download-Size: 5 332 B
APT-Sources: file:/var/opt/amdgpu-pro-local ./ Packages
Description: Meta package to install amdgpu Pro components.```
@fancyIX
Copy link
Owner

fancyIX commented Jan 14, 2022

Seems like your driver is not installed properly.

@HoorayJorge
Copy link
Author

HoorayJorge commented Jan 14, 2022

Perhaps. I've been looking into it.

linux-vdso.so.1 (0x00007ffc28727000)
	libOpenCL.so.1 => /opt/amdgpu-pro/lib/x86_64-linux-gnu/libOpenCL.so.1 (0x00007f2c15c4a000)
	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f2c15a46000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f2c15655000)
	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f2c15436000)
	/lib64/ld-linux-x86-64.so.2 (0x00007f2c1606c000)

	Version information:
	/usr/bin/clinfo:
		libdl.so.2 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libdl.so.2
		libOpenCL.so.1 (OPENCL_1.0) => /opt/amdgpu-pro/lib/x86_64-linux-gnu/libOpenCL.so.1
		libc.so.6 (GLIBC_2.3) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.14) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.3.4) => /lib/x86_64-linux-gnu/libc.so.6
	/opt/amdgpu-pro/lib/x86_64-linux-gnu/libOpenCL.so.1:
		libdl.so.2 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libdl.so.2
		libpthread.so.0 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libpthread.so.0
		libc.so.6 (GLIBC_2.3.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.17) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libc.so.6
	/lib/x86_64-linux-gnu/libdl.so.2:
		ld-linux-x86-64.so.2 (GLIBC_PRIVATE) => /lib64/ld-linux-x86-64.so.2
		libc.so.6 (GLIBC_PRIVATE) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libc.so.6
	/lib/x86_64-linux-gnu/libc.so.6:
		ld-linux-x86-64.so.2 (GLIBC_2.3) => /lib64/ld-linux-x86-64.so.2
		ld-linux-x86-64.so.2 (GLIBC_PRIVATE) => /lib64/ld-linux-x86-64.so.2
	/lib/x86_64-linux-gnu/libpthread.so.0:
		ld-linux-x86-64.so.2 (GLIBC_2.2.5) => /lib64/ld-linux-x86-64.so.2
		ld-linux-x86-64.so.2 (GLIBC_PRIVATE) => /lib64/ld-linux-x86-64.so.2
		libc.so.6 (GLIBC_2.14) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.3.2) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.4) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_2.2.5) => /lib/x86_64-linux-gnu/libc.so.6
		libc.so.6 (GLIBC_PRIVATE) => /lib/x86_64-linux-gnu/libc.so.6
clinfo | egrep '^  Platform Version|^  Device Version|^  Device Name' | sed 's/^\(.*Device Name.*\)$/\n\1/'
  Platform Version                                OpenCL 2.1 AMD-APP (3180.7)

  Device Name                                     gfx1032
  Device Version                                  OpenCL 2.0 AMD-APP (3180.7)

@HoorayJorge
Copy link
Author

So far I get the same behavior with PAL and ROCr OCL

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants