jpeddicord/askalono

does not work on aws lambda

Closed this issue · 6 comments

tu1ly commented

when running on aws lambda node 8.1c runtime it error with
var/task/node_modules/@apiaryio/depcheck/lib/../askalono.linux: /lib64/libc.so.6: version `GLIBC_2.18' not found (required by /var/task/node_modules/@apiaryio/depcheck/lib/../askalono.linux)

Interesting! Lambda is definitely a use case I want to support. I'll check this out soon.

To confirm, you are using the release downloaded from GitHub correct?

tu1ly commented

yes - the latest one - 0.3.0

the underlying lambda system is pretty old:
cat /etc/*-release

2018-12-03T18:20:48.417Z	28369ba8-f728-11e8-a609-a7b7c38ec14f	NAME="Amazon Linux AMI"
VERSION="2017.03"
ID="amzn"
ID_LIKE="rhel fedora"
VERSION_ID="2017.03"
PRETTY_NAME="Amazon Linux AMI 2017.03"
ANSI_COLOR="0;33"
CPE_NAME="cpe:/o:amazon:linux:2017.03:ga"
HOME_URL="http://aws.amazon.com/amazon-linux-ami/"
Amazon Linux AMI release 2017.03

ldd --version
ldd (GNU libc) 2.17

Binary diagnostics:

❯ readelf -V askalono.linux

Version symbols section '.gnu.version' contains 140 entries:
 Addr: 000000000000198e  Offset: 0x00198e  Link: 5 (.dynsym)
  000:   0 (*local*)       0 (*local*)       0 (*local*)       1 (*global*)
  004:   1 (*global*)      1 (*global*)      2 (GCC_3.3)       3 (GLIBC_2.3.2)
  008:   4 (GCC_4.2.0)     5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)
  00c:   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   7 (GCC_3.0)       8 (GLIBC_2.3)
  010:   3 (GLIBC_2.3.2)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  014:   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  018:   6 (GLIBC_2.2.5)   9 (GLIBC_2.3.4)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  01c:   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)
  020:   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)
  024:   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   a (GLIBC_2.18)    9 (GLIBC_2.3.4)
  028:   7 (GCC_3.0)       6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)
  02c:   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)
  030:   5 (GLIBC_2.2.5)   b (GLIBC_2.3.2)   7 (GCC_3.0)       c (GLIBC_2.14)
  034:   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   d (GLIBC_2.3.3)   e (GLIBC_2.2.5)
  038:   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  03c:   6 (GLIBC_2.2.5)   f (GLIBC_2.4)     6 (GLIBC_2.2.5)   2 (GCC_3.3)
  040:   5 (GLIBC_2.2.5)   0 (*local*)       6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  044:   3 (GLIBC_2.3.2)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  048:   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  04c:   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)  10 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)
  050:   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  054:   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  058:   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   7 (GCC_3.0)       5 (GLIBC_2.2.5)
  05c:   6 (GLIBC_2.2.5)   9 (GLIBC_2.3.4)   3 (GLIBC_2.3.2)   7 (GCC_3.0)
  060:   7 (GCC_3.0)       6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  064:   6 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   7 (GCC_3.0)
  068:  11 (GLIBC_2.3)     9 (GLIBC_2.3.4)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  06c:   0 (*local*)       7 (GCC_3.0)       6 (GLIBC_2.2.5)   7 (GCC_3.0)
  070:   5 (GLIBC_2.2.5)   5 (GLIBC_2.2.5)   e (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  074:   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)   0 (*local*)
  078:   0 (*local*)       3 (GLIBC_2.3.2)   5 (GLIBC_2.2.5)   6 (GLIBC_2.2.5)
  07c:   1 (*global*)      1 (*global*)      1 (*global*)      1 (*global*)
  080:   1 (*global*)      1 (*global*)      1 (*global*)      1 (*global*)
  084:   1 (*global*)      1 (*global*)      1 (*global*)      1 (*global*)
  088:   1 (*global*)      1 (*global*)      1 (*global*)      1 (*global*)

Version needs section '.gnu.version_r' contains 6 entries:
 Addr: 0x0000000000001aa8  Offset: 0x001aa8  Link: 6 (.dynstr)
  000000: Version: 1  File: ld-linux-x86-64.so.2  Cnt: 1
  0x0010:   Name: GLIBC_2.3  Flags: none  Version: 17
  0x0020: Version: 1  File: librt.so.1  Cnt: 1
  0x0030:   Name: GLIBC_2.2.5  Flags: none  Version: 16
  0x0040: Version: 1  File: libdl.so.2  Cnt: 1
  0x0050:   Name: GLIBC_2.2.5  Flags: none  Version: 14
  0x0060: Version: 1  File: libc.so.6  Cnt: 7
  0x0070:   Name: GLIBC_2.4  Flags: none  Version: 15
  0x0080:   Name: GLIBC_2.14  Flags: none  Version: 12
  0x0090:   Name: GLIBC_2.3.2  Flags: none  Version: 11
  0x00a0:   Name: GLIBC_2.18  Flags: none  Version: 10
  0x00b0:   Name: GLIBC_2.3.4  Flags: none  Version: 9
  0x00c0:   Name: GLIBC_2.3  Flags: none  Version: 8
  0x00d0:   Name: GLIBC_2.2.5  Flags: none  Version: 6
  0x00e0: Version: 1  File: libpthread.so.0  Cnt: 3
  0x00f0:   Name: GLIBC_2.3.3  Flags: none  Version: 13
  0x0100:   Name: GLIBC_2.2.5  Flags: none  Version: 5
  0x0110:   Name: GLIBC_2.3.2  Flags: none  Version: 3
  0x0120: Version: 1  File: libgcc_s.so.1  Cnt: 3
  0x0130:   Name: GCC_3.0  Flags: none  Version: 7
  0x0140:   Name: GCC_4.2.0  Flags: none  Version: 4
  0x0150:   Name: GCC_3.3  Flags: none  Version: 2

I'll see if I can configure Travis CI to use an older glibc. Failing that, might try a static build with musl-libc instead.

Note to self: this has some config to look at that could help:
https://github.com/rust-lang/rustup.rs/blob/master/.travis.yml

tu1ly commented

thx!

@tu1ly I attached a static build to the 0.3.0 release:

https://github.com/amzn/askalono/releases/download/0.3.0/askalono.linux-static

It's not exactly 0.3.0 as there's been some commits since then, but it's pretty close and functionally works the same way. The next actual release will be a static build by default, assuming this works OK. Let me know if this works for you. :)

I believe this issue is resolved (both with musl-enabled builds, and with our own Lambda "extra").