Closed cuifox closed 3 years ago
参考 https://github.com/SkyAPM/SkyAPM-php-sdk/tree/master/docker 对应的php版本,检查下依赖库
我怀疑是protobuf/grpc缺失
您好: RUN set -ex \ && apk add --update --no-cache autoconf make g++ pkgconfig git openssl curl-dev protobuf-dev protobuf grpc-dev grpc re2c\
# installing skywalking && pecl install skywalking \ && docker-php-ext-enable skywalking \
里面已经安装了protobuf/grpc
config.status: creating config.h
running: make
/bin/sh /tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/libtool --mode=compile g++ -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/tmp/pear/temp/skywalking -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/include -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/main -I/tmp/pear/temp/skywalking -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/src -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/src/network/v3 -DHAVE_CONFIG_H -g -O2 -Wall -std=c++11 -Wno-deprecated-register -c /tmp/pear/temp/skywalking/skywalking.cc -o skywalking.lo
mkdir .libs
g++ -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/tmp/pear/temp/skywalking -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/include -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/main -I/tmp/pear/temp/skywalking -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/src -I/tmp/pear/temp/pear-build-defaultuserNclBFd/skywalking-4.1.1/src/network/v3 -DHAVE_CONFIG_H -g -O2 -Wall -std=c++11 -Wno-deprecated-register -c /tmp/pear/temp/skywalking/skywalking.cc -fPIC -DPIC -o .libs/skywalking.o
In file included from /tmp/pear/temp/skywalking/skywalking.cc:23:
/tmp/pear/temp/skywalking/src/segment.h:23:10: fatal error: src/network/v3/language-agent/Tracing.pb.h: No such file or directory
23 | #include <src/network/v3/language-agent/Tracing.pb.h>
| ^~~~~~~~~~~~
compilation terminated.
make: *** [Makefile:194: skywalking.lo] Error 1
ERROR: `make' failed
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月6日(星期二) 中午11:54 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
参考 https://github.com/SkyAPM/SkyAPM-php-sdk/tree/master/docker 对应的php版本,检查下依赖库
我怀疑是protobuf/grpc缺失
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
是否存在protoc 命令?
有这个命令 /var/www/html # protoc Usage: protoc [OPTION] PROTO_FILES Parse PROTO_FILES and generate output based on the options given: -IPATH, --proto_path=PATH Specify the directory in which to search for imports. May be specified multiple times; directories will be searched in order. If not given, the current working directory is used. If not found in any of the these directories, the --descriptor_set_in descriptors will be checked for required proto file. --version Show version info and exit. -h, --help Show this text and exit. --encode=MESSAGE_TYPE Read a text-format message of the given type
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月6日(星期二) 中午12:51 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
是否存在protoc 命令?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
/etc/apk/repositories https://mirrors.ustc.edu.cn/alpine/edge/main https://mirrors.ustc.edu.cn/alpine/edge/community https://mirrors.ustc.edu.cn/alpine/edge/testing
时 checking for php_json.h... found in /usr/local/include/php checking for grpc and protobuf files in default path... found in /usr found in /usr checking for gpr_now in -lgpr... no configure: error: wrong gpr lib version or lib not found ERROR: `/tmp/pear/temp/skywalking/configure --with-php-config=/usr/local/bin/php-config' failed
/etc/apk/repositories https://mirrors.ustc.edu.cn/alpine/v3.12/main https://mirrors.ustc.edu.cn/alpine/v3.12/community https://mirrors.ustc.edu.cn/alpine/v3.12/testing
时
running: make
/bin/sh /tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/libtool --mode=compile g++ -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/tmp/pear/temp/skywalking -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/include -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/main -I/tmp/pear/temp/skywalking -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/src -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/src/network/v3 -DHAVE_CONFIG_H -g -O2 -Wall -std=c++11 -Wno-deprecated-register -c /tmp/pear/temp/skywalking/skywalking.cc -o skywalking.lo
mkdir .libs
g++ -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/tmp/pear/temp/skywalking -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/include -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/main -I/tmp/pear/temp/skywalking -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/src -I/tmp/pear/temp/pear-build-defaultuserMNDJjJ/skywalking-4.1.1/src/network/v3 -DHAVE_CONFIG_H -g -O2 -Wall -std=c++11 -Wno-deprecated-register -c /tmp/pear/temp/skywalking/skywalking.cc -fPIC -DPIC -o .libs/skywalking.o
In file included from /tmp/pear/temp/skywalking/skywalking.cc:23:
/tmp/pear/temp/skywalking/src/segment.h:23:10: fatal error: src/network/v3/language-agent/Tracing.pb.h: No such file or directory
23 | #include <src/network/v3/language-agent/Tracing.pb.h>
| ^~~~~~~~~~~~
compilation terminated.
make: *** [Makefile:194: skywalking.lo] Error 1
ERROR: `make' failed
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月6日(星期二) 中午12:51 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
是否存在protoc 命令?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
又加了一个包gprbuild后 显示这个的错误
通过以上命令得到的是: /var/www/html # apk search libgnarl libgnat-10.2.1_git20210328-r0
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月6日(星期二) 中午12:51 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
是否存在protoc 命令?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
您好: 请问,这个gpr是需要引入哪个类包? checking for gpr_now in -lgpr... no configure: error: wrong gpr lib version or lib not found ERROR: `/tmp/pear/temp/skywalking/configure --with-php-config=/usr/local/bin/php-config' failed
https://github.com/SkyAPM/SkyAPM-php-sdk/blob/d8e044d972f64700bd2d23285a746b35fa8b5213/config.m4
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月6日(星期二) 中午12:51 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
是否存在protoc 命令?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
configure没有通过的情况下,不要make
gpr 来自gRPC
您好: pecl install skywalking
running: make
/bin/sh /tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/libtool --mode=compile g++ -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/tmp/pear/temp/skywalking -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/include -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/main -I/tmp/pear/temp/skywalking -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/src -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/src/network/v3 -DHAVE_CONFIG_H -g -O2 -Wall -std=c++11 -Wno-deprecated-register -c /tmp/pear/temp/skywalking/skywalking.cc -o skywalking.lo
mkdir .libs
g++ -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -I. -I/tmp/pear/temp/skywalking -DPHP_ATOM_INC -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/include -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/main -I/tmp/pear/temp/skywalking -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/src -I/tmp/pear/temp/pear-build-defaultusernIjiND/skywalking-4.1.1/src/network/v3 -DHAVE_CONFIG_H -g -O2 -Wall -std=c++11 -Wno-deprecated-register -c /tmp/pear/temp/skywalking/skywalking.cc -fPIC -DPIC -o .libs/skywalking.o
In file included from /tmp/pear/temp/skywalking/skywalking.cc:23:
/tmp/pear/temp/skywalking/src/segment.h:23:10: fatal error: src/network/v3/language-agent/Tracing.pb.h: No such file or directory
23 | #include <src/network/v3/language-agent/Tracing.pb.h>
| ^~~~~~~~~~~~
compilation terminated.
make: *** [Makefile:194: skywalking.lo] Error 1
ERROR: `make' failed
请问一下,这个错误是什么问题
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月6日(星期二) 晚上6:30 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
gpr 来自gRPC
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
@vallbuy 你是机器人么 😲
不是,我这有错误
---原始邮件--- 发件人: @.> 发送时间: 2021年4月8日(周四) 下午4:22 收件人: @.>; 抄送: @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
@vallbuy 你是机器人么 😲
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.
有完整的dockerfile吗?
您好:这是dockerfile
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月8日(星期四) 晚上9:12 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
有完整的dockerfile吗?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.
哪Dockerfile呢?
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月9日(星期五) 下午3:21 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
哪Dockerfile呢?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.
您好 在附件里面
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月9日(星期五) 下午3:21 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
哪Dockerfile呢?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.
你用邮件回复不会自带附件。
FROM php:7.3-fpm-alpine
COPY ./repositories /etc/apk/repositories
RUN set -ex \ && apk add --update --no-cache autoconf g++ protobuf-dev grpc-dev curl-dev make re2c\
# installing skywalking
&& pecl install skywalking \
&& docker-php-ext-enable skywalking
RUN mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini"
EXPOSE 9000
CMD ["php-fpm"]
repositories的内容 https://mirrors.ustc.edu.cn/alpine/v3.11/main https://mirrors.ustc.edu.cn/alpine/v3.11/community
好的,主要是github慢
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月9日(星期五) 下午3:28 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
请参考这个 https://github.com/SkyAPM/SkyAPM-php-sdk/blob/master/docker/Dockerfile.7.3
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.
docker pull skyapm/skywalking-php-7.3-fpm-alpine:latest
好的 谢谢
------------------ 原始邮件 ------------------ 发件人: "SkyAPM/SkyAPM-php-sdk" @.>; 发送时间: 2021年4月9日(星期五) 下午3:43 @.>; @.**@.>; 主题: Re: [SkyAPM/SkyAPM-php-sdk] 请问是少依赖包么?具体是哪个 请指教 (#352)
docker pull skyapm/skywalking-php-7.3-fpm-alpine:latest
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.
pecl install skywalking
In file included from /tmp/pear/temp/skywalking/skywalking.cc:23: /tmp/pear/temp/skywalking/src/segment.h:23:10: fatal error: src/network/v3/language-agent/Tracing.pb.h: No such file or directory 23 | #include <src/network/v3/language-agent/Tracing.pb.h> | ^
~~~~~~~~~~~ compilation terminated. make: *** [Makefile:194: skywalking.lo] Error 1 ERROR: `make' failed