我試圖導入RRDtool成Python,因爲我想要訪問使用Python的RRD數據庫,但是當我試圖import rrdtool
我收到以下錯誤。無法導入RRDtool的在Python
Python 2.6.5 (r265:79063, Apr 16 2010, 13:57:41)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path.append('/opt/rrdtool-1.4.5/bin')
>>> import rrdtool
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named rrdtool
我的RRDtool位於/opt/rrdtool-1.4.5/bin
。
所以正是我應該怎麼辦? – Hunt 2011-02-26 19:36:35