nebula1.2.1源码编译成功后,打包报错

首先感谢解决了我昨天在源码编译中遇到的问题

现在源码编译成功后,打包过程中出现异常

打包命令

./package.sh -v 1.2.1

报错如下:

[100%] Building CXX object src/daemons/CMakeFiles/nebula-graphd.dir/GraphDaemon.cpp.o
[100%] Linking CXX executable ../../bin/nebula-graphd
[100%] Built target nebula-graphd
+ popd
/opt/modules/nebula/package
+ package FALSE
+ strip_enable=FALSE
+ pushd /opt/modules/nebula/package/..//build/
/opt/modules/nebula/build /opt/modules/nebula/package
+ args=
+ [[ FALSE == TRUE ]]
+ cpack -G RPM --verbose
CPack: Enable Verbose
CPack Verbose: Read CPack config file:
CPack Verbose: Read CPack configuration file: /opt/modules/nebula/build/CPackConfig.cmake
CPack Verbose: Specified generator: RPM
CPack Verbose: Use generator: cmCPackRPMGenerator
CPack Verbose: For project: nebula
CPack: Create package using RPM
CPack Verbose: Read description file: /opt/vesoft/toolset/cmake/share/cmake-3.15/Templates/CPack.GenericDescription.txt
CPack Verbose: [RPM] requested component grouping = ALL_COMPONENTS_IN_ONE
CPack Verbose: [RPM] requested component grouping = ALL_COMPONENTS_IN_ONE
CPack: Install projects
CPack: - Run preinstall target for: Nebula Graph
CPack: - Install project: Nebula Graph
CPack: -   Install component: common
CPack Verbose: Install configuration: "Release"
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/nebula.service
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/services.sh
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/utils.sh
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/meta.hosts
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/storage.hosts
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/graph.hosts
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/share/resources/gflags.json
CPack: -   Install component: console
CPack Verbose: Install configuration: "Release"
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/nebula
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/share/resources/completion.json
CPack: -   Install component: graph
CPack Verbose: Install configuration: "Release"
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/nebula-graphd
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/etc/nebula-graphd.conf.default
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/etc/nebula-graphd.conf.production
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/nebula-graphd.service
CPack: -   Install component: meta
CPack Verbose: Install configuration: "Release"
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/nebula-metad
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/etc/nebula-metad.conf.default
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/etc/nebula-metad.conf.production
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/nebula-metad.service
CPack: -   Install component: storage
CPack Verbose: Install configuration: "Release"
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/nebula-storaged
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/etc/nebula-storaged.conf.default
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/etc/nebula-storaged.conf.production
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/scripts/nebula-storaged.service
CPack: -   Install component: tool
CPack Verbose: Install configuration: "Release"
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/storage_perf
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/storage_integrity
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/simple_kv_verify
CPack Verbose: Installing: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux/ALL_COMPONENTS_IN_ONE/usr/     local/nebula/bin/db_dump
CPack: Create package
CPack Verbose: Package files to: /opt/modules/nebula/build/_CPack_Packages/Linux/RPM/nebula-1.2.1-Linux.rpm
CPack Verbose: Packaging all groups in one package...(CPACK_COMPONENTS_ALL_[GROUPS_]IN_ONE_PACKAGE is set)
CMake Error at /opt/vesoft/toolset/cmake/share/cmake-3.15/Modules/Internal/CPack/CPackRPM.cmake:774 (message):
  RPM package requires rpmbuild executable
Call Stack (most recent call first):
  /opt/vesoft/toolset/cmake/share/cmake-3.15/Modules/Internal/CPack/CPackRPM.cmake:1879 (cpack_rpm_generate_package)


CPack Error: Error while execution CPackRPM.cmake
CPack Error: Problem compressing the directory
CPack Error: Error when generating package: nebula
+ echo '>>> package nebula failed <<<'
>>> package nebula failed <<<
+ exit -1

打包失败之后,package目录如下:

打包的目的是: 用源码编译后打的包进行集群部署
继续问一下,如果打包成功目录结构大致是什么样的? 打好的包,可以用做这个文档下面的安装包么?
集群部署文档

十分感谢!

看报错信息, 应该是你没有安装rpmbuild包,
RPM package requires rpmbuild executable.
打好的包,可以按照集群部署文档进行部署测试.

如果你想使用master最新代码编译好的包, 可以去这里直接下载:

这里的包都是每天晚上编译打包一次

1 个赞

感谢您的回答,发完这个帖子之后,我认真排查了一下日志,确实是这个问题,现在已经打包成功! 再次感谢

该主题在最后一个回复创建后7天后自动关闭。不再允许新的回复。

浙ICP备20010487号