tugraph-db
tugraph-db copied to clipboard
Docker container exits immediately in non-interactive mode for mac m3 pro
Issue Description
## Issue Description
When running a Docker container, it exits immediately in non-interactive mode, but runs normally in interactive mode.
## Environment Information
- **Operating System**:
```sh
$ system_profiler SPHardwareDataType
Hardware:
Hardware Overview:
Model Name: MacBook Pro
Model Identifier: Mac15,6
Model Number: Z1AU002P2CH/A
Chip: Apple M3 Pro
Total Number of Cores: 11 (5 performance and 6 efficiency)
Memory: 36 GB
System Firmware Version: 10151.140.19
OS Loader Version: 10151.140.19
Serial Number (system): F6XLNXJ0V4
Hardware UUID: A3FDC5A7-21BA-5EB4-8C10-FF07A49644BE
Provisioning UDID: 00006030-000E10493C52001C
Activation Lock Status: Enabled
-
Docker Version:
$ docker -v Docker version 20.10.8, build 3967b7d
Steps to Reproduce
-
Download the Docker image:
wget https://tugraph-web.oss-cn-beijing.aliyuncs.com/tugraph/tugraph-runtime-arm64v8-centos7-4.3.0.taz docker load < tugraph-runtime-arm64v8-centos7-4.3.0.taz docker images | grep tugraph
Output:
tugraph-arm 4.3.0 02ae44f80297 2 months ago 6.87GB
-
Run the container in interactive mode (works fine):
docker run -it --rm tugraph-arm:4.3.0 /bin/bash
Inside the container:
chmod +X tugraph-demo/setup.sh ./tugraph-demo/setup.sh
The container starts Tugraph normally.
-
Run the container in detached mode (exits immediately):
docker run -d tugraph-arm:4.3.0
Check the container status:
docker ps
Output:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
Check the container logs:
docker logs <container_id>
Inspect the container:
docker inspect <container_id>
Output:
[ { "Id": "5fd760b894d528b21932739f172aa14ed76142edecd5dc791dd8eb567c363833", "Created": "2024-08-25T10:52:24.146740711Z", "Path": "/bin/bash", "Args": [], "State": { "Status": "exited", "Running": false, "Paused": false, "Restarting": false, "OOMKilled": false, "Dead": false, "Pid": 0, "ExitCode": 0, "Error": "", "StartedAt": "2024-08-25T10:52:24.399502836Z", "FinishedAt": "2024-08-25T10:52:24.400074127Z" }, "Image": "sha256:02ae44f80297462c0c6a078b140bd7ad124ba532b3060eed2f22e1e2a0f638b6", "ResolvConfPath": "/var/lib/docker/containers/5fd760b894d528b21932739f172aa14ed76142edecd5dc791dd8eb567c363833/resolv.conf", "HostnamePath": "/var/lib/docker/containers/5fd760b894d528b21932739f172aa14ed76142edecd5dc791dd8eb567c363833/hostname", "HostsPath": "/var/lib/docker/containers/5fd760b894d528b21932739f172aa14ed76142edecd5dc791dd8eb567c363833/hosts", "LogPath": "/var/lib/docker/containers/5fd760b894d528b21932739f172aa14ed76142edecd5dc791dd8eb567c363833/5fd760b894d528b21932739f172aa14ed76142edecd5dc791dd8eb567c363833-json.log", "Name": "/practical_bose", "RestartCount": 0, "Driver": "overlay2", "Platform": "linux", "MountLabel": "", "ProcessLabel": "", "AppArmorProfile": "", "ExecIDs": null, "HostConfig": { "Binds": null, "ContainerIDFile": "", "LogConfig": { "Type": "json-file", "Config": {} }, "NetworkMode": "default", "PortBindings": {}, "RestartPolicy": { "Name": "no", "MaximumRetryCount": 0 }, "AutoRemove": false, "VolumeDriver": "", "VolumesFrom": null, "CapAdd": null, "CapDrop": null, "CgroupnsMode": "host", "Dns": [], "DnsOptions": [], "DnsSearch": [], "ExtraHosts": null, "GroupAdd": null, "IpcMode": "private", "Cgroup": "", "Links": null, "OomScoreAdj": 0, "PidMode": "", "Privileged": false, "PublishAllPorts": false, "ReadonlyRootfs": false, "SecurityOpt": null, "UTSMode": "", "UsernsMode": "", "ShmSize": 67108864, "Runtime": "runc", "ConsoleSize": [ 0, 0 ], "Isolation": "", "CpuShares": 0, "Memory": 0, "NanoCpus": 0, "CgroupParent": "", "BlkioWeight": 0, "BlkioWeightDevice": [], "BlkioDeviceReadBps": null, "BlkioDeviceWriteBps": null, "BlkioDeviceReadIOps": null, "BlkioDeviceWriteIOps": null, "CpuPeriod": 0, "CpuQuota": 0, "CpuRealtimePeriod": 0, "CpuRealtimeRuntime": 0, "CpusetCpus": "", "CpusetMems": "", "Devices": [], "DeviceCgroupRules": null, "DeviceRequests": null, "KernelMemory": 0, "KernelMemoryTCP": 0, "MemoryReservation": 0, "MemorySwap": 0, "MemorySwappiness": null, "OomKillDisable": false, "PidsLimit": null, "Ulimits": null, "CpuCount": 0, "CpuPercent": 0, "IOMaximumIOps": 0, "IOMaximumBandwidth": 0, "MaskedPaths": [ "/proc/asound", "/proc/acpi", "/proc/kcore", "/proc/keys", "/proc/latency_stats", "/proc/timer_list", "/proc/timer_stats", "/proc/sched_debug", "/proc/scsi", "/sys/firmware" ], "ReadonlyPaths": [ "/proc/bus", "/proc/fs", "/proc/irq", "/proc/sys", "/proc/sysrq-trigger" ] }, "GraphDriver": { "Data": { "LowerDir": "/var/lib/docker/overlay2/f2d361a7e5ce68275e8bb3dd97d066c60deb5c6190fb1eaba6c8842939fd7fc3-init/diff:/var/lib/docker/overlay2/ef3c514283559eb08be8c896c24be7eae09aee20b221d888b91ff539784d10f2/diff:/var/lib/docker/overlay2/1621c98605ac166282fcd9cad54c2336345ac1344dad8e71215a6f7b060869c7/diff:/var/lib/docker/overlay2/166629d5de93c675242c6c4d37b7449496e90d245bc71c5e770a9f808052351d/diff:/var/lib/docker/overlay2/d2d74122cc0a3e38d68548910cbaa7d85ecf4901a9666e29f8a66f10c6c6d4d0/diff:/var/lib/docker/overlay2/4f9f79fc8986bfe44c609ed9c7460f76c7f9d911f32ccf946679cab7cad3715d/diff:/var/lib/docker/overlay2/0db1ebb2481648616acf1a3bc16ec4f8c903e88e62dc35839d8c67abf7f936b0/diff:/var/lib/docker/overlay2/33c06050abc1208a51a67614fdd81ff6d723cdbb2c24962fd84603822d722f3a/diff:/var/lib/docker/overlay2/f7c8c890256340daaa7dc1097257dacd8d9bd1e5ff8eb4ee0e32ee0d600c7e99/diff:/var/lib/docker/overlay2/e5f189005a186cd750e00b21cddd3b0f12a47c703aba623ec520f6b785a811a6/diff:/var/lib/docker/overlay2/97ac1965d0a612b968a6098bfce87261f54ab5cc59cc10946086b371252ad849/diff:/var/lib/docker/overlay2/ad1cb7f08220690042049a35b661184db1532a00c814dfd0749863d980bfa0ab/diff:/var/lib/docker/overlay2/596a423114885197155b8cf2184806d9861c071c28a369ae2947ce4fec1e4016/diff:/var/lib/docker/overlay2/3d9d1a8790e6ea2c6510cc62bedafe356686089c05baf14b710cd5f2084efdc3/diff", "MergedDir": "/var/lib/docker/overlay2/f2d361a7e5ce68275e8bb3dd97d066c60deb5c6190fb1eaba6c8842939fd7fc3/merged", "UpperDir": "/var/lib/docker/overlay2/f2d361a7e5ce68275e8bb3dd97d066c60deb5c6190fb1eaba6c8842939fd7fc3/diff", "WorkDir": "/var/lib/docker/overlay2/f2d361a7e5ce68275e8bb3dd97d066c60deb5c6190fb1eaba6c8842939fd7fc3/work" }, "Name": "overlay2" }, "Mounts": [], "Config": { "Hostname": "5fd760b894d5", "Domainname": "", "User": "", "AttachStdin": false, "AttachStdout": false, "AttachStderr": false, "ExposedPorts": { "7070/tcp": {}, "7687/tcp": {}, "9090/tcp": {} }, "Tty": false, "OpenStdin": false, "StdinOnce": false, "Env": [ "PATH=/opt/apache-maven-3.8.7/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin", "JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk/jre/", "LD_LIBRARY_PATH=/usr/local/lib64:/usr/lib/jvm/java-1.8.0/jre/lib/amd64/server:", "PYTHONPATH=/usr/local/lib64:", "LANG=zh_CN.utf8", "LC_ALL=zh_CN.utf8" ], "Cmd": [ "/bin/bash" ], "Image": "tugraph-arm:4.3.0", "Volumes": null, "WorkingDir": "", "Entrypoint": null, "OnBuild": null, "Labels": { "org.label-schema.build-date": "20201113", "org.label-schema.license": "GPLv2", "org.label-schema.name": "CentOS Base Image", "org.label-schema.schema-version": "1.0", "org.label-schema.vendor": "CentOS", "org.opencontainers.image.created": "2020-11-13 00:00:00+00:00", "org.opencontainers.image.licenses": "GPL-2.0-only", "org.opencontainers.image.title": "CentOS Base Image", "org.opencontainers.image.vendor": "CentOS" } }, "NetworkSettings": { "Bridge": "", "SandboxID": "f80966be7458d93925ea078a49064f1cf8eced30d5c38eb3923155149405e8f0", "HairpinMode": false, "LinkLocalIPv6Address": "", "LinkLocalIPv6PrefixLen": 0, "Ports": {}, "SandboxKey": "/var/run/docker/netns/f80966be7458", "SecondaryIPAddresses": null, "SecondaryIPv6Addresses": null, "EndpointID": "", "Gateway": "", "GlobalIPv6Address": "", "GlobalIPv6PrefixLen": 0, "IPAddress": "", "IPPrefixLen": 0, "IPv6Gateway": "", "MacAddress": "", "Networks": { "bridge": { "IPAMConfig": null, "Links": null, "Aliases": null, "NetworkID": "7a0577444c5b6c0a1a83bd2b05abf74d8e4c14f727988b42c866ef3d93e7ebe4", "EndpointID": "", "Gateway": "", "IPAddress": "", "IPPrefixLen": 0, "IPv6Gateway": "", "GlobalIPv6Address": "", "GlobalIPv6PrefixLen": 0, "MacAddress": "", "DriverOpts": null } } } } ]
Expected Behavior
The container should start and run normally in non-interactive mode.
Waiting for Feedback
After submitting the issue, wait for feedback from the open-source community. If there are any further questions or information needed, update the issue accordingly.
By following these steps, you can clearly describe the issue you encountered and provide enough information for the open-source community to diagnose and resolve the problem.