perf icon indicating copy to clipboard operation
perf copied to clipboard

AWS EC2: panic: runtime error: invalid memory address or nil pointer dereference

Open hivl opened this issue 2 years ago • 2 comments

Hi, I have some problems to run perf testing from AWS EC2 instances. After installing go, checking out a repo, setting some env variables and running go run mage.go I get following ERROR (the preparation go run mage.go prepare were allready done from local mashine):

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x10c7946]

goroutine 1 [running]:
debug/elf.(*Section).ReadAt(0xc000ba0000?, {0xc0007626c0?, 0x17?, 0x16?}, 0x16?)
	<autogenerated>:1 +0x26
archive/zip.readDirectoryEnd({0x17be540, 0xc0003f5600}, 0x210)
	/usr/local/go/src/archive/zip/reader.go:581 +0xf5
archive/zip.(*Reader).init(0xc00016cc40, {0x17be540?, 0xc0003f5600}, 0x210)
	/usr/local/go/src/archive/zip/reader.go:124 +0x5c
archive/zip.NewReader({0x17be540, 0xc0003f5600}, 0x210)
	/usr/local/go/src/archive/zip/reader.go:103 +0x5e
github.com/daaku/go%2ezipexe.zipExeReaderElf({0x17c9620?, 0xc00039a298}, 0x2cc4441)
	/home/ubuntu/go/pkg/mod/github.com/daaku/[email protected]/zipexe.go:128 +0x8b
github.com/daaku/go%2ezipexe.NewReader({0x17c9620, 0xc00039a298}, 0x0?)
	/home/ubuntu/go/pkg/mod/github.com/daaku/[email protected]/zipexe.go:48 +0x98
github.com/daaku/go%2ezipexe.OpenCloser({0xc0003a4a40?, 0xc000a67980?})
	/home/ubuntu/go/pkg/mod/github.com/daaku/[email protected]/zipexe.go:30 +0x57
github.com/GeertJohan/go%2erice.init.0()
	/home/ubuntu/go/pkg/mod/github.com/!geert!johan/[email protected]/appended.go:38 +0x5e
Error: running "k6-harbor run scripts/test/get-artifact-by-digest.js --no-usage-report --vus 100 --iterations 200" failed with exit code 2
exit status 2```


have tried it out on different instance types (m5.large, c4.4xlarge) and with differetn OS (Amazon Linux 2023 AMI 2023.0.20230503.0 x86_64 HVM kernel-6.1 and Canonical, Ubuntu, 22.04 LTS, amd64 jammy image build on 2023-03-25)

what am I missing?



hivl avatar May 11 '23 15:05 hivl

Which golang version do you use?

chlins avatar May 16 '23 02:05 chlins

same error on go version go1.19.7 linux/amd64

danielzhanghl avatar May 30 '23 06:05 danielzhanghl