Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/319.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 无法在RedHat上安装py rrdtool_Python_Redhat_Rrdtool - Fatal编程技术网

Python 无法在RedHat上安装py rrdtool

Python 无法在RedHat上安装py rrdtool,python,redhat,rrdtool,Python,Redhat,Rrdtool,我使用Python2.6安装RHEL6,需要使用Python安装rrdtool。我必须手动上传和安装软件包,因为出于安全原因,网络管理员会阻止yum和pip传出流量。在安装过程中,我遇到缺少错误缺少rrdtoolmodule.c,在哪里可以找到该文件?还是我错过了什么 [user@host ~]$ sudo pip install py-rrdtool-1.0b1.tar.gz [sudo] password for user: /usr/lib/python2.6/site-packages

我使用Python2.6安装RHEL6,需要使用Python安装rrdtool。我必须手动上传和安装软件包,因为出于安全原因,网络管理员会阻止yum和pip传出流量。在安装过程中,我遇到缺少错误缺少rrdtoolmodule.c,在哪里可以找到该文件?还是我错过了什么

[user@host ~]$ sudo pip install py-rrdtool-1.0b1.tar.gz
[sudo] password for user: 
/usr/lib/python2.6/site-packages/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
Processing ./py-rrdtool-1.0b1.tar.gz
Installing collected packages: py-rrdtool
  Running setup.py install for py-rrdtool
    Complete output from command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-a5tFI5-build/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-krfsUz-record/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-2.6
    copying rrdtool.py -> build/lib.linux-x86_64-2.6
    running build_ext
    building '_rrdtool' extension
    creating build/temp.linux-x86_64-2.6
    creating build/temp.linux-x86_64-2.6/src
    gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/local/include -I/usr/include/python2.6 -c src/_rrdtoolmodule.c -o build/temp.linux-x86_64-2.6/src/_rrdtoolmodule.o
    src/_rrdtoolmodule.c:34:17: error: rrd.h: No such file or directory
    In file included from src/rrd_extra.h:37,
                     from src/_rrdtoolmodule.c:35:
    src/rrd_format.h:59: error: expected specifier-qualifier-list before ‘rrd_value_t’
    src/rrd_format.h:295: error: expected specifier-qualifier-list before ‘rrd_value_t’
    src/_rrdtoolmodule.c: In function ‘PyRRD_create’:
    src/_rrdtoolmodule.c:93: warning: implicit declaration of function ‘rrd_create’
    src/_rrdtoolmodule.c:94: warning: implicit declaration of function ‘rrd_get_error’
    src/_rrdtoolmodule.c:94: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c:95: warning: implicit declaration of function ‘rrd_clear_error’
    src/_rrdtoolmodule.c: In function ‘PyRRD_update’:
    src/_rrdtoolmodule.c:122: warning: implicit declaration of function ‘rrd_update’
    src/_rrdtoolmodule.c:123: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c: In function ‘PyRRD_fetch’:
    src/_rrdtoolmodule.c:145: error: ‘rrd_value_t’ undeclared (first use in this function)
    src/_rrdtoolmodule.c:145: error: (Each undeclared identifier is reported only once
    src/_rrdtoolmodule.c:145: error: for each function it appears in.)
    src/_rrdtoolmodule.c:145: error: ‘data’ undeclared (first use in this function)
    src/_rrdtoolmodule.c:145: error: ‘datai’ undeclared (first use in this function)
    src/_rrdtoolmodule.c:145: warning: left-hand operand of comma expression has no effect
    src/_rrdtoolmodule.c:154: warning: implicit declaration of function ‘rrd_fetch’
    src/_rrdtoolmodule.c:156: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c:165: error: expected ‘;’ before ‘dv’
    src/_rrdtoolmodule.c:191: error: ‘dv’ undeclared (first use in this function)
    src/_rrdtoolmodule.c: In function ‘PyRRD_graph’:
    src/_rrdtoolmodule.c:245: warning: implicit declaration of function ‘rrd_graph’
    src/_rrdtoolmodule.c:247: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c: In function ‘PyRRD_tune’:
    src/_rrdtoolmodule.c:297: warning: implicit declaration of function ‘rrd_tune’
    src/_rrdtoolmodule.c:298: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c: In function ‘PyRRD_last’:
    src/_rrdtoolmodule.c:324: warning: implicit declaration of function ‘rrd_last’
    src/_rrdtoolmodule.c:325: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c: In function ‘PyRRD_resize’:
    src/_rrdtoolmodule.c:350: warning: implicit declaration of function ‘rrd_resize’
    src/_rrdtoolmodule.c:351: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c: In function ‘PyRRD_info’:
    src/_rrdtoolmodule.c:380: warning: passing argument 2 of ‘PyErr_SetString’ makes pointer from integer without a cast
    /usr/include/python2.6/pyerrors.h:78: note: expected ‘const char *’ but argument is of type ‘int’
    src/_rrdtoolmodule.c:423: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:423: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:423: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:423: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:423: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:423: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:424: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:424: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:424: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:424: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:424: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:424: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:426: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:426: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:426: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:426: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:426: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:426: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:443: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:443: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:443: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:443: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:443: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:443: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:455: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:455: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:455: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:455: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:455: error: ‘unival’ has no member named ‘u_val’
    src/_rrdtoolmodule.c:455: error: ‘unival’ has no member named ‘u_val’
    error: command 'gcc' failed with exit status 1

    ----------------------------------------
Command "/usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-a5tFI5-build/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-krfsUz-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-a5tFI5-build

您很可能正在尝试编译为更新版本的rrdtool创建的rrdtool绑定版本。由于rrdtool已随时间发生变化,您可能需要确保使用与您正在使用的rrdtool版本匹配的绑定,或者使用与之匹配的绑定。

我从