Tutorial Commands Fail to Launch In Quick Start Container on macOS
- Dominant language
- C
- Stars
- 22.7k
- Forks
- 4.1k
- Avg merge
- 10d 4h
- Merged PRs (30d)
- 3
Description
On macOS Catalina running the Docker Desktop 2.5.0.1 or 3.1.0 stable, when I enter a shell in a container per the [Quick Start Guide](https://github.com/iovisor/bcc/blob/master/QUICKSTART.md) and run a [Tutorial](https://github.com/iovisor/bcc/blob/master/docs/tutorial.md#bcc-tutorial) command I get e.g.:
```sh
root@740aabbe09ba:/usr/share/bcc/tools# ./execsnoop
chdir(/lib/modules/5.4.39-linuxkit/build): No such file or directory
Traceback (most recent call last):
File "./execsnoop", line 165, in
b = BPF(text=bpf_text)
File "/usr/lib/python2.7/dist-packages/bcc/__init__.py", line 325, in __init__
raise Exception("Failed to compile BPF text")
Exception: Failed to compile BPF text
```
It looks like the directory of interest is a soft link to a linux headers dir:
```sh
root@740aabbe09ba:/usr/share/bcc/tools# ls -lat /lib/modules/5.4.39-linuxkit/build
lrwxrwxrwx 1 root root 38 May 8 2020 /lib/modules/5.4.39-linuxkit/build -> /usr/src/linux-headers-5.4.39-linuxkit
```
And those ostensibly should be availabe from the `/usr/src` dir on the host since the container was launched with:
```sh
docker run -it --rm \
--privileged \
-v /lib/modules:/lib/modules:ro \
-v /usr/src:/usr/src:ro \
-v /etc/localtime:/etc/localtime:ro \
--workdir /usr/share/bcc/tools \
zlim/bcc
```
But I haven't installed bcc tools on the my Mac. The Quick Start guide didn't say I had to.
Is there a Docker image that works on macOS? Preferably one that doesn't require installing other things on my Mac to get the tutorial to work.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.