Centos 7.5源码编译安装zabbix4.0报fatal error: mysql.h: No such file or directory

时间:2022-12-29 11:56:43

系统环境:CentOS 7.5是最小化安装的

编译信息

编译选项:
root@Server01 zabbix-4.0.]# ./configure --prefix=/usr/share/applications/zabbix --enable-server --enable-agent --with-mysql=/usr/bin/mysql_config_editor --enable-ipv6 --with-net-snmp --with-libcurl --with-libxml2=/usr/lib64/libxml2.so
编译结果:
Configuration: Detected OS: linux-gnu
Install path: /usr/share/applications/zabbix
Compilation arch: linux Compiler: cc
Compiler flags: -g -O2 Library-specific flags:
database:
Net-SNMP: -I/usr/local/include -I/usr/lib64/perl5/CORE -I. -I/usr/include Enable server: yes
Server details:
With database: MySQL
WEB Monitoring: cURL
SSL certificates: /usr/share/applications/zabbix/share/zabbix/ssl/certs
SSL keys: /usr/share/applications/zabbix/share/zabbix/ssl/keys
Native Jabber: no
SNMP: yes
IPMI: no
SSH: no
TLS: no
ODBC: no
Linker flags: -L/usr/lib64 -rdynamic
Libraries: -lxml2 -lnetsnmp -lz -lpthread -levent -lcurl -lm -ldl -lresolv -lpcre
Configuration file: /usr/share/applications/zabbix/etc/zabbix_server.conf
External scripts: /usr/share/applications/zabbix/share/zabbix/externalscripts
Alert scripts: /usr/share/applications/zabbix/share/zabbix/alertscripts
Modules: /usr/share/applications/zabbix/lib/modules Enable proxy: no Enable agent: yes
Agent details:
TLS: no
Linker flags: -rdynamic
Libraries: -lz -lpthread -lcurl -lm -ldl -lresolv -lpcre
Configuration file: /usr/share/applications/zabbix/etc/zabbix_agentd.conf
Modules: /usr/share/applications/zabbix/lib/modules Enable Java gateway: no LDAP support: no
IPv6 support: yes ***********************************************************
* Now run 'make install' *
* *
* Thank you for using Zabbix! *
* <http://www.zabbix.com> *
***********************************************************

make install 报错

。。。。。。。。。。。。。。。
Making install in zbxcommshigh
make[]: Entering directory `/usr/local/src/zabbix-4.0./src/libs/zbxcommshigh'
make[]: Entering directory `/usr/local/src/zabbix-4.0./src/libs/zbxcommshigh'
make[]: Nothing to be done for `install-exec-am'.
make[]: Nothing to be done for `install-data-am'.
make[]: Leaving directory `/usr/local/src/zabbix-4.0./src/libs/zbxcommshigh'
make[]: Leaving directory `/usr/local/src/zabbix-4.0./src/libs/zbxcommshigh'
Making install in zbxdb
make[]: Entering directory `/usr/local/src/zabbix-4.0./src/libs/zbxdb'
cc -DHAVE_CONFIG_H -I. -I../../../include -g -O2 -MT libzbxdb_a-db.o -MD -MP -MF .deps/libzbxdb_a-db.Tpo -c -o libzbxdb_a-db.o `test -f 'db.c' || echo './'`db.c
db.c::: fatal error: mysql.h: No such file or directory
# include "mysql.h"
^
compilation terminated.
make[]: *** [libzbxdb_a-db.o] Error
make[]: Leaving directory `/usr/local/src/zabbix-4.0./src/libs/zbxdb'
make[]: *** [install-recursive] Error
make[]: Leaving directory `/usr/local/src/zabbix-4.0./src/libs'
make[]: *** [install-recursive] Error
make[]: Leaving directory `/usr/local/src/zabbix-4.0./src'
make: *** [install-recursive] Error

解决办法:(针对我的环境)

[root@Server01 zabbix-4.0.]# ./configure --prefix=/usr/share/applications/zabbix --enable-server --enable-agent --with-mysql --enable-ipv6 --with-net-snmp --with-libcurl --with-libxml2
[root@Server01 zabbix-4.0.]# echo $? [root@Server01 zabbix-4.0.]# make install
[root@Server01 zabbix-4.0.]# echo $?

Centos 7.5源码编译安装zabbix4.0报fatal error: mysql.h: No such file or directory的更多相关文章

  1. ubuntu 安装 regex模块时 fatal error&colon; Python&period;h&colon; No such file or directory

    原因是 python-dev包没有安装 根据Py2还是py3 sudo apt-get install python-dev 或者 sudo apt-get install python3-dev 安 ...

  2. 安装MySQLdb模块遭遇&quot&semi;fatal error&colon; my&lowbar;config&period;h&colon; No such file or directory&quot&semi;的处理

    Issue       I encountered an error when I run the python script which need to import the module of & ...

  3. CentOS 7上源码编译安装和配置LNMP Web&plus;phpMyAdmin服务器环境

    CentOS 7上源码编译安装和配置LNMP Web+phpMyAdmin服务器环境 什么是LNMP? LNMP(别名LEMP)是指由Linux, Nginx, MySQL/MariaDB, PHP/ ...

  4. CentOS 7&period;4 源码编译安装 Redis

    一.CentOS 7.4  源码编译安装 Redis 1.下载源码并解压 wget http://download.redis.io/releases/redis-4.0.10.tar.gz tar ...

  5. 源码编译安装MySQL8&period;0

    源码编译安装MySQL8.0 0.前期准备条件 查看linux的版本 [root@mysql etc]# cat /etc/redhat-release CentOS Linux release 7. ...

  6. caffe编译问题-src&sol;caffe&sol;net&period;cpp&colon;8&colon;18&colon; fatal error&colon; hdf5&period;h&colon; No such file or directory compilation terminated&period;

    错误描述 src/caffe/net.:: fatal error: hdf5.h: No such : recipe 操作过程 step1: 在Makefile.config文件更改INCLUDE_ ...

  7. qingstor python-sdk 安装错误 src&sol;MD2&period;c&colon;31&colon;20&colon; fatal error&colon; Python&period;h&colon; No such file or directory

    ubuntu安装python qingstor-sdk, src/MD2.c:31:20: fatal error: Python.h: No such file or directory compi ...

  8. tesseract编译错误:fatal error&colon; allheaders&period;h&colon; No such file or directory

    错误描述: globaloc.cpp::: fatal error: allheaders.h: No such file or directory #include "allheaders ...

  9. 解决 Boost安装:fatal error&colon; bzlib&period;h&colon; No such file or directory 问题

    参考: How to install all the boost development libraries? 解决 Boost安装:fatal error: bzlib.h: No such fil ...

随机推荐

  1. genymotion安装及问题解决

     1.首先下载安装genymotion 这个现在安装教程有很多,大家自行百度一下. 下载地址:https://www.genymotion.com/download/# 我的是win10系统,64位, ...

  2. oracle存储过程中的if&period;&period;&period;elseif&period;&period;&period;else用法

    if ... then ...   elsif ... then ... else ...   end if; or     if ... then      ...   else ...   end ...

  3. 对js闭包的粗浅理解

    只能是粗浅的,毕竟js用法太灵活. 首先抛概念:闭包(closure)是函数对象与变量作用域链在某种形式上的关联,是一种对变量的获取机制.这样写鬼能看懂. 所以要大致搞清三个东西:函数对象(funct ...

  4. STL map详细用法和make&lowbar;pair函数

    今天练习华为上机测试题,遇到了map的用法,看来博客http://blog.csdn.net/sprintfwater/article/details/8765034:感觉很详细,博主的其他内容也值得 ...

  5. altium6&period;x中自动删除重复走线的位置

    在protel 2004 DXP中,“自动删除走线”的位置就在"PCB Editor"的默认页面,非常好找. 但是升级到了altium 6.7,6.9之后,很多人就找不到这个了. ...

  6. HDU 1258 Sum It Up&lpar;DFS&rpar;

    题目链接 Problem Description Given a specified total t and a list of n integers, find all distinct sums ...

  7. UVA-10037 Bridge---过河问题进阶版(贪心)

    题目链接: https://vjudge.net/problem/UVA-10037 题目大意: N个人夜里过河,总共只有一盏灯,每次最多过两个人,然后需要有人将灯送回 才能继续过人,每个人过桥都需要 ...

  8. SpringBoot进阶教程&lpar;三十&rpar;整合Redis之Sentinel哨兵模式

    Redis-Sentinel是官方推荐的高可用解决方案,当redis在做master-slave的高可用方案时,假如master宕机了,redis本身(以及其很多客户端)都没有实现自动进行主备切换,而 ...

  9. 金融量化分析【day110】:Pandas的Series对象

    一.pandas简介安装 pandas是一个强大的python数据分析的工具包 pandsa是基于NumPy构建的 1.pandas的主要功能 1.具备对其功能的数据结构DataFrame.Serie ...

  10. 又拍云 Node&period;js 实现文件上传、删除

    Node.js 服务端 使用 Node.js + Express.js 实现 服务端 const express = require("express"); const app = ...