ZPanel是一个免费的虚拟主机控制面板,支持Windows,Linux,UNIX和MacOSX等多个操作系统的VPS或者服务器。目前,ZPanel最新的版本命名为ZPanelX(10),基于个人使用习惯,我这里只要是简单介绍ZPanelX在linux系统的安装和使用。ZPanelX支持的linux操作系统包括CentOS 6和Ubuntu 11.10,12.04等(其他诸如Debian等暂未支持)。
ZPanel主机管理面板简单介绍――方法/步骤ZPanel主机管理面板简单介绍 1、
我依然使用比较熟悉的CentOS系统,先重做下VPS系统为CentOS 6.
首先,下载源码,传入VPS。您可以直接下载到本地解压后用SFTP传上去,也可以直接SSH登陆下载解压,我们需要用到的是installer.sh.x,假设我们已经放入root目录,接下来命令。
cd /root #进入目录
chmod +x installer.sh.x #设定权限
yum install ld-linux.so.2 #此步非必须
./installer.sh.x #编译安装
对了,建议大家在执行命令前先screen,因为安装过程可能超过30分钟,干等是很不明智的。
执行编译后,暂时别离开,这时候,我们需要确定和设定一些项目,除了要输入y之后,还需要你设定时区,比如:Asia/Shanghai,以及MySQL的root密码(2次)。全部完成后,等他自己装,看电视先。
ZPanel主机管理面板简单介绍 2、
安装完成后,我们以IP/zpanel打开登陆页面,默认的用户名和密码:zadmin/password(登陆后记得修改,这是好习惯)。
确认登陆无误,我们开始汉化的过程(以下过程全部引用,敬请留意)
1.通过ZPANELX面板打开PHPMYADMIN,分别选中对应的表,执行以下SQL语句
========core库=========ALTER TABLE `x_accounts` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_aliases` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_bandwidth` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_cronjobs` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_distlists` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_distlistusers` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_dns` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_faqs` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_forwarders` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_ftpaccounts` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_groups` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_htaccess` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_mailboxes` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_logs` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_mailboxes` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_modcats` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_modules` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_mysql` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_mysql_databases` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_mysql_dbmap` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_mysql_users` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_packages` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_permissions` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_profiles` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_quotas` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_settings` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_translations` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `x_vhosts` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
============postfix库===========ALTER TABLE `admin` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `alias` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `alias_domain` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `config` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `domain` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `domain_admins` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `fetchmail` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `log` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `mailbox` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `quota` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `quota2` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `vacation` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `vacation_notification` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
============proftpd库(实际上我觉得这一部分做不做无所谓)===========ALTER TABLE `ftpgroup` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `ftpquotalimits` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `ftpquotatallies` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `ftpuser` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
============roundcube库===========ALTER TABLE `cache` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `contactgroupmembers` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `contactgroups` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `contacts` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `identities` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `messages` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `session` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;ALTER TABLE `users` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
注意,上面的SQL执行过程可能有报错,赵容在3台VPS上测试,每台都有报错的情况,但不影响最终的汉化结果,不过,您有能力的话,可以针对报错内容修改执行。
ZPanel主机管理面板简单介绍 3、
2.修改文件,先修改/etc/zpanel/panel/dryden/db/driver.class.php文件,找到
public function query($query) { try {
在try里面加入
$FIXSql1 = “set character_set_server=’utf8′”; $FIXSql2 = “set names ‘utf8′”; $FIX = parent::query($FIXSql1); $FIX2 =parent::query($FIXSql2);
保存。
然后,接着修改/etc/zpanel/panel/etc/styles/zpanelx/master.ztml,找到
<meta http-equiv=”Content-Type” content=”text/html; charset=ISO-8859-1″>
修改为
<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″ />
保存。
ZPanel主机管理面板简单介绍 4、
3.接下来又是数据库,到core库执行:
ALTER TABLE `x_translations` ADD `tr_Chinese_tx` TEXT NULL;
ZPanel主机管理面板简单介绍 5、
4.返回ZPanelX,选择我的账户,修改语言为Chinese,就可以了(这之前请确保你的邮箱也设定了,我试过账户中没有设定邮箱提交不成功)。说了这么久,上一张图片:
ZPanel主机管理面板简单介绍 6、
添加文件管理插件
ZPanelX最大的缺点在文件管理,就一个FTP,太弱了,所以,我们再加一个文件管理插件,让他能自由的在线管理文件,上传下载、压缩解压等等。(以下为引用,敬请留意)
SSH登陆服务器,依次执行:
zppy repo add zppy.vjvj.tk
zppy update
zppy install ajaxplorer
完成后,登陆ZPanelX,选择服务器管理→模块管理,勾选AjaXplorer中你要授权使用的用户组。