最新消息:20210816 当前crifan.com域名已被污染,为防止失联,请关注(页面右下角的)公众号

【记录】网站搬家之通过ftp上传wordpress文件到新的虚拟空间hawk中

TransferWebHosting crifan 3264浏览 0评论

【背景】

折腾:

【记录】网站搬家之在新空间hawk的cpanel中创建ftp账户和确认压缩格式支持的类型

完毕后,接着就是直接去上传,整个的wordpress的文件,先压缩为rar,再通过ftp,到对应的hawk的空间上去即可。

【折腾过程】

1.先去压缩本地的整个wordpress网站的所有文件,包括了其下的bbs文件夹内的vanilla,以及files下面的doc等等文件,1.12G的东西,压缩都要压缩几分钟。

2.压缩后得到0.98GB的www_crifan_com.rar

然后就可以去试着上传到hawk上面了:

upload whole crifan com wordpress files to hawk

看起来,就很爽,速度达到了1MB/s还多。

后来速度就稳定在1.1MB/s了。

总的来说,1GB文件,上传一下,也就不到20分钟就搞定。

还是足够爽了。

注:我是12M的宽带。

3.另外,注意到,原先的hawk的www下面,就有个.htaccess文件,内容如下:

# -FrontPage-

IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthName crifan.com
AuthUserFile /home/xxx/public_html/_vti_pvt/service.pwd
AuthGroupFile /home/xxx/public_html/_vti_pvt/service.grp

而我之前自己的网站上面的.htacess的内容是

# Use PHP5 Single php.ini as default
AddHandler application/x-httpd-php5s .php

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress



# Fancy directory listings
#Include httpd-autoindex.conf


#
# Directives controlling the display of server-generated directory listings.
#
# Required modules: mod_autoindex, mod_alias
#
# To see the listing of a directory, the Options directive for the
# directory must include "Indexes", and the directory must not contain
# a file matching those listed in the DirectoryIndex directive.
#

......
#
# IndexIgnore is a set of filenames which directory indexing should ignore
# and not include in the listing.  Shell-style wildcarding is permitted.
#
IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t

所以,还是很不一样的。

但是不管旧的了,到时候也是直接完整的覆盖再说。

4.上传完毕后,再去解压:

for www crifan com rar to decompress

然后点击 Extact Files:

sure to extract files

结果却是坑爹的显示出了:

The File Manager does not support extracting this type of archive.

The File Manager does not support extracting this type of archive

很明显,是不支持rar。。。

但是郁闷的是,既然不支持rar,为何你之前还对于rar文件,可以正常显示出压缩图标,搞得我以为你支持呢。。。

你妹的。。。

5.所以,只能

删除已上传的www_crifan_com.rar

重新压缩一个www_crifan_com.zip

然后再重新上传www_crifan_com.zip

re upload www crifan com zip

然后再解压www_crifan_com.zip

extracting archive www crifan com zip

然后很快也就解压完毕了:

for www crifan com zip show extracting result

for www crifan com zip show extracting result done

再去把www_crifan_com.zip删除掉,以腾出空间。

 

【总结】

上传整站的wordpress文件,如果是一个个文件慢慢传,那由于文件太多太碎,导致传的很慢。

而由于支持在线解压缩,所以最好把整站的文件都压缩后,上传,然后在线解压,再移动文件到根目录。就可以了。

需要注意的是:

cpanel中的文件管理器,貌似不支持rar。

(之前已验证过,不支持7z的:

【记录】网站搬家之在新空间hawk的cpanel中创建ftp账户和确认压缩格式支持的类型

所以,对于整站的文件的压缩,最好使用zip,这样确保是支持的。


接下来的,就只是:

修改对应的wp-config.php ,以及,新建对应的数据库,以及其中的用户名和密码,等等事情了。

 

关于网站搬家的全过程,参见:

【记录】在本地测试wordpress已成功后去实现在线的wordpress网站搬家(换主机)

转载请注明:在路上 » 【记录】网站搬家之通过ftp上传wordpress文件到新的虚拟空间hawk中

发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址
83 queries in 0.175 seconds, using 22.13MB memory