![]() So I increased my swap space to 10 Gb (10240) (since I had plenty of hard disk space free) by running: sudo dd if=/dev/zero of=/swap_file bs=10240 count=1M I think the reason so much memory was already being used was because I was running also running a full node to support a Substrate-based chain on that machine. Total used free shared buff/cache available I checked how much swap space i had with free -h, which showed I only had 1.4 Gb RAM free and only 150Mb of swap space free: free -h I checked how much hard disk space i had with df -H and it showed I still had 20 Gb free = note: collect2: fatal error: ld terminated with signal 9 Įrror: could not compile `node-cli` due to previous error Ĭompiling node-cli v3.0.0-dev (/root/substrate/bin/node/cli)Įrror: linking with `cc` failed: exit status: 1 I tried building with cargo build, but during the installaion I got the error during the build. I had followed the official documentation instructions to install Substrate here and all relevant dependencies on Ubuntu. I had cloned the latest commit of Substrate's 'master' branch dated 9th March 2023. I had at least 36 Gb SSD hard disk space available. When I entered lscpu it output AMD EPYC 7601 32-Core Processor, so the CPU speed was 2.2 GHz. I had accidentally used a less performant "Linode 4 GB" machine, which has only 2 CPUs, 4 Gb RAM. I recently got the same error on an Ubuntu 22.04.2 LTS machine. On macOS you can show Swap space usage in the terminal by running sysctl vm.swapusage: > sysctl vm.swapusage Since you they say you need at least 4 Gb RAM to run Substrate, you would want the output to say you have at least 4000M unused since that corresponds with ~4 Gb. ![]() On macOS you can show CPU and memory usage in the terminal by running top -l 1 | grep -E "^CPU|^Phys": > top -l 1 | grep -E "^CPU|^Phys"ĬPU usage: 15.61% user, 26.72% sys, 57.66% idle ![]() ![]() It is likely because your machine didn't have the minimum required RAM or Swap space free to run Substrate. I can build other projects but not this one. ![]() Warning: build failed, waiting for other jobs to dkg-substrate % = note: "cc" "-arch" "arm64" "/var/folders/5w/j2mkxftx2xz55c696xp23gzh0000gn/T/rustciwy51y/symbols.o" "/Users/elioprifti/dkg-substrate/target/debug/deps/dkg_standalone_" "/Users/elioprifti/dkg-substrate/target/debug/deps/dkg_standalone_" "/Users/elioprifti/dkg-substrate/target/debug/deps/dkg_standalone_" "/Users/elioprifti/dkg-substrate/target/debug/deps/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_std_workspace_alloc-d0e3d0b2f5dc30fb.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libunwind-12083e42f9a7d1fc.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcfg_if-def158ba03cb504e.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/liblibc-e83dd9bd71bd52bd.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/liballoc-a149d8756e403a5c.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_std_workspace_core-95a7e52c78a3fba1.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcore-dd6de681850a671c.rlib" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcompiler_builtins-ec608688b97371b8.rlib" "-lgmp" "-framework" "Security" "-framework" "Security" "-lc++" "-framework" "SystemConfiguration" "-framework" "Security" "-framework" "CoreFoundation" "-liconv" "-lSystem" "-lresolv" "-lc" "-lm" "-liconv" "-L" "/Users/elioprifti/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib" "-o" "/Users/elioprifti/dkg-substrate/target/debug/deps/dkg_standalone_node-3e72bef5f25657ad" "-Wl,-dead_strip" "-nodefaultlibs"Ĭlang: error: linker command failed with exit code 1 (use -v to see invocation)Įrror: could not compile `dkg-standalone-node` due to previous error Not able to build a project because of this issue: error: linking with `cc` failed: exit status: 1 ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |