歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> 關於Plone 4.1.3及4.0.7不能在Ubuntu 11.10下安裝的問題

關於Plone 4.1.3及4.0.7不能在Ubuntu 11.10下安裝的問題

日期:2017/2/28 15:58:34   编辑:Linux教程
問題如下:
64位Ubuntu 11.10,安裝了所有的升級和補丁,顯卡驅動也更新了,從Plone.org下載的Universal installation pack 4.1.3在解壓縮之後,運行如下命令:
./install.sh standalone --password=123
先是那個python編譯不能通過,說是什麼zip code的問題LookupError: Unknown Encoding: zip
然後又是zlib的問題,用了--libz=no參數依然不行
然後又是libxml的問題,用了apt-get install libxml依然不行;
然後又是buildout運行不正常導致退出的問題。到這裡死活過不去,讓人感覺這一版本的Plone簡直是漏洞百出,問題太多了。

其實根本問題就是Plone自帶的Python編譯沒有通過的問題。解決了這個問題後面的都不是問題了。
在google.com搜索LookupError: UnknowEncoding: zip這個錯誤信息,在http://stackoverflow.com網站上有一條解答,現摘錄如下:

Its an issue with the Python disutils and the new multilib setup of natty. I ran into the same issue trying to get sqlite support in Python built from source.

You can hack around it in the detect modules section of the setup.py

http://bugs.python.org/issue9762

Edit:

To work around it, change lib_dirs in the python setup.py (around line 408) to this (for an x86_64 machine):

lib_dirs = self.compiler.library_dirs + [
'/lib64', '/usr/lib64',
'/lib', '/usr/lib', '/usr/lib/x86_64-linux-gnu',
]

(the /usr/lib/x86_64-linux-gnu is missing)

在Plone/package下找到python-2.6.7-tar.bz2,將他解壓縮,找到裡面的setup.py文件,浏覽到408行附近,然後按照上面所說的,加上'/usr/lib/x86_64-linux-gnu',這些紅色的內容。別忘了逗號。然後保存這個setup.py文件。

下面還需要將解壓縮出來的文件重新壓縮成python-2.6.7-tar.bz2,再次運行install.sh standalone,Plone的安裝就能成功了。

PS:上面所說的natty,指的是Ubuntu 11.04。

最後,附上成功安裝的Console輸出。
===============================================================
Stand-Alone Zope Instance selected

Detailed installation log being written to /home/liuyz/Plone-4.1.3-UnifiedInstaller/install.log

Root install method chosen. Will install for use by system user plone

Installing Plone 4.1.3 at /usr/local/Plone

User 'plone' already exists. No need to create it.
Compiling and installing jpeg local libraries ...
Skipping zlib build
Compiling and installing readline local libraries ...
Installing Python 2.6.7. This takes a while...
Patching for Debian/Ubuntu Multiarch
Patching for thread size
Patching for disabled ssl2
Installing distribute...
Python build looks OK.
Unpacking buildout cache to /usr/local/Plone/buildout-cache
Compiling .py files in egg cache
Copying Plone-docs
Your platform's xml2/xslt are missing or out-of-date. We'll need to build them.
Copying buildout skeleton
Fixing up bin/buildout
Building lxml with static libxml2/libxslt; this takes a while...
Building Zope/Plone; this takes a while...
Setting instance ownership to plone
Setting buildout cache ownership to plone

#####################################################################
###################### Installation Complete ######################

Plone successfully installed at /usr/local/Plone
See /usr/local/Plone/zinstance/README.html
for startup instructions

Use the account information below to log into the Zope Management Interface
The account has full 'Manager' privileges.

Username: admin
Password: 123

This account is created when the object database is initialized. If you change
the password later (which you should!), you'll need to use the new password.

- If you need help, ask the mailing lists or #plone on irc.freenode.net.
- The live support channel also exists at http://plone.org/chat
- You can read/post to the lists via http://plone.org/forums

- Submit feedback and report errors at http://dev.plone.org/plone
(For install problems, specify component "Installer (Unified)")
Copyright © Linux教程網 All Rights Reserved