全球主机交流论坛

标题: Nginx + Discuz 不能上传远程附件 [打印本页]

作者: bluesky    时间: 2009-8-29 21:05
标题: Nginx + Discuz 不能上传远程附件
远程附件的FTP主机
在cPanel环境下,可以正常上传至远程主机
Nginx却上传到本地主机,远程FTP主机传不上去

请教...
Nginx 如何让 Discuz 能上传远程附件 ??
作者: cpuer    时间: 2009-8-29 21:06
标题: 回复 1# 的帖子
discuz的远程附件在哪里设置?
作者: bluesky    时间: 2009-8-29 21:07
原帖由 cpuer 于 2009-8-29 21:06 发表
discuz的远程附件在哪里设置?

後台有
作者: bluesky    时间: 2009-8-29 21:13
7.0 的附件设置如下图

(, 下载次数: 8)
(, 下载次数: 9)
作者: cpuer    时间: 2009-8-29 21:21
原帖由 bluesky 于 2009-8-29 21:07 发表

後台有


刚看了下,我的理解是,文件从本地上传到论坛空间,然后文件从论坛空间ftp模式上传到远程附件空间,这样必须在论坛空间上必须有安装PHP的ftp扩展吧,没有具体试过。
作者: cpuer    时间: 2009-8-29 21:23
默认张宴和一键安装包的PHP都在编译的时候没加上--enable-ftp
作者: bluesky    时间: 2009-8-29 21:23
原帖由 cpuer 于 2009-8-29 21:21 发表
刚看了下,我的理解是,文件从本地上传到论坛空间,然后文件从论坛空间ftp模式上传到远程附件空间,这样必须在论坛空间上必须有安装PHP的ftp扩展吧,没有具体试过。 ...

安装ftp?
哪一种ftp呢?
作者: bluesky    时间: 2009-8-29 21:25
原帖由 cpuer 于 2009-8-29 21:23 发表
默认张宴和一键安装包的PHP都在编译的时候没加上--enable-ftp

的确不含ftp
--enable-ftp
要如何安装启动?
作者: cpuer    时间: 2009-8-29 21:26
标题: 回复 7# 的帖子
只有一种,就是PHP支持FTP
这个跟Turing有讨论过,我找下帖子地址
作者: cpuer    时间: 2009-8-29 21:26
原帖由 bluesky 于 2009-8-29 21:25 发表

的确不含ftp
--enable-ftp
要如何安装启动?

重新编译。
作者: bluesky    时间: 2009-8-29 21:28
原帖由 cpuer 于 2009-8-29 21:26 发表
重新编译。

重头来过
作者: cpuer    时间: 2009-8-29 21:29
找到帖子地址了:安装xtrafile出错 http://www.sunk.eu.org/thread-2834-1-1.html
作者: bluesky    时间: 2009-8-29 21:31
一键包
有办法补强吗?
作者: cpuer    时间: 2009-8-29 21:32
标题: 回复 13# 的帖子
把一键安装包擦开来,自己修正
作者: bluesky    时间: 2009-8-29 21:34
原帖由 cpuer 于 2009-8-29 21:32 发表
把一键安装包擦开来,自己修正

偶不会分屍
作者: cpuer    时间: 2009-8-29 21:34
标题: 回复 15# 的帖子
那就按照张宴的教程一步一步自己编译,记得加上PHP的ftp支持
作者: bluesky    时间: 2009-8-29 21:35
找到关键处
这里也来copy一份

tar zxvf php-5.2.10.tar.gz
gzip -cd php-5.2.10-fpm-0.5.11.diff.gz | patch -d php-5.2.10 -p1
cd php-5.2.10/
./configure --prefix=/usr/local/webserver/php --with-config-file-path=/usr/local/webserver/php/etc --with-mysql=/usr/local/webserver/mysql --with-mysqli=/usr/local/webserver/mysql/bin/mysql_config --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-discard-path --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fastcgi --enable-fpm --enable-force-cgi-redirect --enable-mbstring --with-mcrypt --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-ldap --with-ldap-sasl --with-xmlrpc --enable-zip --enable-soap --without-pear --enable-ftp
make ZEND_EXTRA_LIBS='-liconv'
make install
cp php.ini-dist /usr/local/webserver/php/etc/php.ini
cd ../
作者: cpuer    时间: 2009-8-29 21:38
标题: 回复 17# 的帖子



作者: bluesky    时间: 2009-8-29 21:47
重新编译
冒出这啥东东?

# gzip -cd php-5.2.10-fpm-0.5.11.diff.gz | patch -d php-5.2                                                               .10 -p1
patching file configure
patching file configure.in
The next patch would create the file libevent/aclocal.m4,
which already exists!  Assume -R? [n]
作者: cpuer    时间: 2009-8-29 21:50
标题: 回复 19# 的帖子
提示文件已经存在,问你是否重试。
作者: bluesky    时间: 2009-8-29 21:51
原帖由 cpuer 于 2009-8-29 21:50 发表
提示文件已经存在,问你是否重试。

按 y 是吗?
作者: bluesky    时间: 2009-8-29 21:54
按不完 y 好多

patching file configure
patching file configure.in
The next patch would create the file libevent/aclocal.m4,
which already exists!  Assume -R? [n] y
Apply anyway? [n] y
patching file libevent/aclocal.m4
Patch attempted to create file libevent/aclocal.m4, which already exists.
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED -- saving rejects to file libevent/aclocal.m4.rej
The next patch would create the file libevent/autogen.sh,
which already exists!  Assume -R? [n] y
patching file libevent/autogen.sh
The next patch would create the file libevent/buffer.c,
which already exists!  Assume -R? [n] y
patching file libevent/buffer.c
The next patch would create the file libevent/ChangeLog,
which already exists!  Assume -R? [n] y
patching file libevent/ChangeLog
The next patch would create the file libevent/compat/sys/queue.h,
which already exists!  Assume -R? [n] y
patching file libevent/compat/sys/queue.h
The next patch would create the file libevent/compat/sys/_time.h,
which already exists!  Assume -R? [n] y
patching file libevent/compat/sys/_time.h
The next patch would create the file libevent/config.h.in,
which already exists!  Assume -R? [n] y
patching file libevent/config.h.in
The next patch would create the file libevent/configure,
which already exists!  Assume -R? [n] y
patching file libevent/configure
The next patch would create the file libevent/configure.in,
which already exists!  Assume -R? [n] y
patching file libevent/configure.in
The next patch would create the file libevent/depcomp,
which already exists!  Assume -R? [n] y
patching file libevent/depcomp
The next patch would create the file libevent/devpoll.c,
which already exists!  Assume -R? [n] y
patching file libevent/devpoll.c
The next patch would create the file libevent/epoll.c,
which already exists!  Assume -R? [n] y
patching file libevent/epoll.c
The next patch would create the file libevent/epoll_sub.c,
which already exists!  Assume -R? [n] y
patching file libevent/epoll_sub.c
The next patch would create the file libevent/evbuffer.c,
which already exists!  Assume -R? [n] y
patching file libevent/evbuffer.c
The next patch would create the file libevent/event.3,
which already exists!  Assume -R? [n] y
y
patching file libevent/event.3
The next patch would create the file libevent/event.c,
which already exists!  Assume -R? [n] patching file libevent/event.c
The next patch would create the file libevent/event-config.h,
which already exists!  Assume -R? [n] y
patching file libevent/event-config.h
The next patch would create the file libevent/event-fpm.h,
which already exists!  Assume -R? [n] y
patching file libevent/event-fpm.h
The next patch would create the file libevent/event.h,
which already exists!  Assume -R? [n] y
patching file libevent/event.h
The next patch would create the file libevent/event-internal.h,
which already exists!  Assume -R? [n] y
patching file libevent/event-internal.h
The next patch would create the file libevent/evhttp.h,
which already exists!  Assume -R? [n] y
patching file libevent/evhttp.h
The next patch would create the file libevent/evport.c,
which already exists!  Assume -R? [n] y
patching file libevent/evport.c
The next patch would create the file libevent/evsignal.h,
which already exists!  Assume -R? [n] y
patching file libevent/evsignal.h
The next patch would create the file libevent/evutil.c,
which already exists!  Assume -R? [n] y
patching file libevent/evutil.c
The next patch would create the file libevent/evutil.h,
which already exists!  Assume -R? [n] y
patching file libevent/evutil.h
作者: cpuer    时间: 2009-8-29 22:00
标题: 回复 22# 的帖子
可以考虑删除那些重复的文件先,然后再编译安装。
作者: bluesky    时间: 2009-8-29 22:06
原帖由 cpuer 于 2009-8-29 22:00 发表
可以考虑删除那些重复的文件先,然后再编译安装。


加入 make clean 了
这样对吧?

tar zxvf php-5.2.10.tar.gz
gzip -cd php-5.2.10-fpm-0.5.11.diff.gz | patch -d php-5.2.10 -p1
cd php-5.2.10/
./configure --prefix=/usr/local/webserver/php --with-config-file-path=/usr/local/webserver/php/etc --with-mysql=/usr/local/webserver/mysql --with-mysqli=/usr/local/webserver/mysql/bin/mysql_config --with-iconv-dir=/usr/local --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-discard-path --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fastcgi --enable-fpm --enable-force-cgi-redirect --enable-mbstring --with-mcrypt --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-ldap --with-ldap-sasl --with-xmlrpc --enable-zip --enable-soap --without-pear --enable-ftp
make ZEND_EXTRA_LIBS='-liconv'
make clean
make install
cp php.ini-dist /usr/local/webserver/php/etc/php.ini
cd ../

( 话说 ... 偶把 y 按完了  )

作者: cpuer    时间: 2009-8-29 22:14
标题: 回复 24# 的帖子
嗯,不make clean也可以的。
作者: bluesky    时间: 2009-8-29 22:25
成功了~
可以使用远程附件辣 ... 开心
作者: cpuer    时间: 2009-8-29 22:28
标题: 回复 26# 的帖子
还不给我加分?
我不喜欢远程附件哦,除非远程附件所在服务器是自己的独立服务器   专门来存储这些东西的。
作者: bluesky    时间: 2009-8-29 22:35
可以评分耶~
作者: cpuer    时间: 2009-8-29 22:36
标题: 回复 28# 的帖子
Thx for your scores




欢迎光临 全球主机交流论坛 (https://sunk.eu.org/) Powered by Discuz! X3.4