本站用于记录日常工作内容,虚拟化云计算,系统运维,数据库DBA,网络与安全。
Apache伪静态(URL Rewrite)设置方法 一 打开 Apache 的配置文件 httpd.conf 二 将#LoadModule rewrite_module modules/mod_rewrite 前面的#去掉三 在 httpd.conf中添加:RewriteEngine On # 伪静态规则保存到这里,以下为DZ论坛伪静态RewriteRule ^(.*)/archiver/((fid|tid)-[\w\-]+\.html)\?*(.*)$ $1/archiver/index\.php\?$2&$4RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/forumdisplay\.php\?fid=$2&page=$3&$4RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/viewthread\.php\?tid=$2&extra=page\%3D$4&page=$3&$4RewriteRule ^(.*)/space-(username|uid)-(.+)\.html\?*(.*)$ $1/space\.php\?$2=$3&$4RewriteRule ^(.*)/tag-(.+)\.html\?*(.*)$ $1/tag\.php\?name=$2&$3四 保存httpd.conf 并重启Apache
64位CentOS安装KLOXO面板的一些问题新开了的VPS,打算先装KLOXO,系统是centos 64位首先是 提示selinux 必须关闭,所以先关掉它:vi /etc/sysconfig/selinuxSELINUX=enforcing --> SELINUX=disabled ESC:wq 如果安装过 apache + mysql +php , 则要先删除卸载:yum -y remove httpd* #卸载跟apache有关的所有资料yum -y remove mysql* #卸载跟mysql有关的所有资料yum -y remove php* #卸载跟php有关的所有资料开始安装面板:sh ./kloxo-install-master.sh 顺利安装了,查看防火墙信息,CentOS 默认只开了SSH的22端口 /etc/init.d/iptables status开启指定端口:/sbin/iptables -I INPUT -p tcp --dport 80 -j ACCEPT/sbin/iptables -I INPUT -p tcp --dport 7777 -j ACCEPT/sbin/iptables -I INPUT -p tcp --dport 7778 -j ACCEPT/sbin/iptables -I INPUT -p tcp --dport 21 -j ACCEPT/etc/rc.d/init.d/iptables save #保存/etc/init.d/iptables restart #重启如果重启不了可以直接用 reboot 再看下防火墙状态: /etc/init.d/iptable...
修改kloxo面板中phpmyadmin 导入数据库sql的大小 默认8M值 不少使用VPS的用户经常问到这个问题,phpmyadmin限制了最大导入数据库文件的大小,如果超过8M,则无法通过kloxo面板导入,本文将完美解决这个问题。默认情况下,kloxo控制面板自带的phpmyadmin最大的sql导入文件大小的限制是8192KB(即8M)。网上的教程大多是让修改 /etc/php.ini配置来解决,其实那是完全错误的。因为kloxo服务使用了一个独立的php.ini配置。/etc/php.ini只对客户的 php环境起作用。正确的方法应该是:vi /usr/local/lxlabs/ext/php/etc/php.ini 只需要修改一个参数值post_max_size = 80M因为其他几个参数值kloxo默认就设置得很大,不用修改。保存后重启kloxo服务/etc/init.d/kloxo restart这时再返回到kloxo的phpmyadmin导入界面,你会发现最大限制已经变为了81,920 KB
更换Kloxo的主IP后,网站显示默认页的解决办法 刚刚帮人家Kloxo 更换了主域名,但是发现面板里开的站点,打开全部是默认页了。重启时候,apache错误提示 虚拟主机没有指定 NameVirtualHost查看/home/httpd/site.com/conf/kloxo.site.com 配置文件,没有问题。所以,很可能问题出在apache的配置文件。vi /etc/httpd/conf/kloxo/virtualhost.conf 发现新的IP没有配置 NameVirtualHost 汗,里面显示的还是老IP的80和443端口于是更改下,ESC退出 :wq 保存, 再重启apache服务 service httpd restart再次访问站点域名,已经显示正常!
去除discuz x2底部版权和去掉头部“powered by discuz!一、去除头部版权 在原来的discuz X2版本中,标题中去掉“Powered by Discuz!”版权标识很容易,只需要修改模板文件的头部公用文件,将“Powered by Discuz!”这一行字去掉即可。 但是discuz X2 似乎对这点有所防备,把-Powered by Discuz!中的-放在了变量里,所以删除后,标题一句话结束后会有一个小-尾巴,对搜索引擎很不友好,所以也有一个好的办法完美解决,即: 打开\template\default\common\header_common.htm文件,找到<title><!–{if !empty($navtitle)}–>$navtitle – <!–{/if}–><!–{if empty($nobbname)}–> $_G['setting']['bbname']-<!–{/if}–>Powered by Discuz!</title> 将其中的“Powered By Discuz!”字串改为“{lang secondtitle}”。 再打开source/language/lang_template.php。 在变量的最后,也就是整个数组的目录后按以前的格式,加上“‘secondtitle’ => ‘你的论坛名称!”,” 。 更新缓存即可。 二、去除底部的版本打开template\default\common,找到footer.htm文件,用deamweaver打开,点击编辑,再点击查找和替换powerd by,知道...
Squid3.0缓存服务器配置全记录 Squid3.0缓存服务器配置一台缓存服务器对多台虚拟主机 第一步: 123wget http://www.squid-cache.org/Versions/v3/3.0/squid-3.0.STABLE25.tar.gztar zxvf squid-3.0.STABLE25.tar.gzcd squid-3.0.STABLE25123456789101112131415161718192021222324252627./configure --prefix=/usr/local/squid3 \--enable-async-io=100 \--with-pthreads \--enable-storeio="aufs,diskd,ufs" \--enable-removal-policies="heap,lru" \--enable-icmp \--enable-delay-pools \--enable-useragent-log \--enable-referer-log \--enable-kill-parent-hack \--enable-arp-acl \--enable-default-err-language=Simplify_Chinese \--enable-err-languages="Simplify_Chinese English" \--disable-poll \--disable-wccp \--disable-wccpv2 \--disable-ident-lookups \--disable-internal-dns \--enable-basic-auth-helpers="NCSA" \--enable-stacktrace \--with-large-files \--disable-mempools \--with-filedescriptors=65536 \--enable-ssl \--enable-x-accelerator-varmakemake install第二步...
Linux VPS Nginx+PHP 安装ionCube 今天下载了一个whmcs,在自己的VPS上测试一下,但是提示:Site error: the file /home/test/whmcs/index.php requires the ionCube PHP Loader ioncube_loader_lin_5.2.so to be installed by the site administrator.上面的提示是没有安装ionCube的原因。首先,执行uname -a 查看系统是32位还是64位,打开http://www.ioncube.com/loaders.php页面根据Linux是32位还是64位下载适当的软件包,比如我的是32位的,切换到/usr/local/目录,执行cd /usr/local ,wget http://downloads2.ioncube.com/loader_downloads/ioncube_loaders_lin_x86.tar.gz 下载,再执行tar zxvf ioncube_loaders_lin_x86.tar.gz 解压软件包。修改/usr/local/php/etc/php.ini 在文件尾部添加如下代码:[ionCube Loader]zend_extension="/usr/local/ioncube/ioncube_loader_lin_5.2.so"如果以前装有Zend Optimizer,安装ionCube会和Zend Optimizer发生冲突,再执行/usr/local/php/php-fpm reload 时会发生如下错误:The Loader must appear as the first entry in the php.ini file in Unknown on line 0须将Zend Optimizer的代码删除,如LNMP中是如下代码...
Nginx 完美重启脚本vi /etc/init.d/nginx然后输入如下内容,你将能使用service nginx startservice nginx stopservice nginx restartservice nginx reload#!/bin/sh## nginx - this script starts and stops the nginx daemin## chkconfig: - 85 15 # description: Nginx is an HTTP(S) server, HTTP(S) reverse \# proxy and IMAP/POP3 proxy server# processname: nginx# config: /usr/local/nginx/conf/nginx.conf# pidfile: /usr/local/nginx/logs/nginx.pid# Source function library.. /etc/rc.d/init.d/functions# Source networking configuration.. /etc/sysconfig/network# Check that networking is up.[ "$NETWORKING" = "no" ] && exit 0nginx="/usr/local/nginx/sbin/nginx"prog=$(basename $nginx)NGINX_CONF_FILE="/usr/local/nginx/conf/nginx.conf"lockfile=/var/lock/subsys/nginxstart() { [ -x $nginx ] || exit 5 [ -f $NGINX_CONF_FILE ] ||...
说说Global.asa 网站木马的解决办法打开网站,页面提示如下错误: msxml3.dll 错误 '80072efd'A connection with the server could not be established/LM/W3SVC/670931603/Root/global.asa,行 69 一般是Global.asa 网站木马 最近在查看网站流量统计的时候发现流量有些异常,于是检查网站程序的时候发现程序多出了一个文件。文件名是Global.asa,上传时间为9月13日晚上,我的网站使用的是开源的企业建站系统,一开始没注意过这个问题,就在昨天我的网站流量一下子跌倒了低谷,当时我就怀疑是网站程序出现了问题,但是就是找不出毛病来。后来经常访问网站的客户打电话告诉我说:“从百度打开你的网站会自动跳转到某些色情网站上,并且会被360提示有木马病毒。”于是在网上搜索了一些解决Global.asa木马的方法,下面就给大家说下我的解决方法。 什么是global.asa木马呢? global.asa在百度百科里是这样介绍的: Global.asa 文件是一个可选的文件,它可包含可被ASP 应用程序中每个页面访问的对象、变量以及方法的声明。所有合法的浏览器脚本都能在Global.asa 中使用。 Global.asa 中,我们可以告知a...
Server 2008 R2服务器IIS设置asp+access程序今天为客户架设一程序,接触了下Windows Server 2008 R2系统,在IIS上新建网站[asp+access],出现数据库连接失败提示,因为这种模式的程序是最基本的服务器配置和软件配置就可以跑起来,2008竟然不能运行!是缺少驱动还是配置不兼容?不可能啊,server 2003顺利解决的问题不会到2008退化了吧。那肯定就是配置太高了,如果要跑这样的程序得把配置设置低些。。。果然,server2008默认缓冲池是64位,把32位兼容模式选中就可以了。下面我们来配置: 错误页面:------------------------------------------------------------------------------------错误信息为:Microsoft OLE DB Provider for ODBC Drivers 错误 '80004005' [Microsoft][ODBC Microsoft Access 驱动程序] 磁盘或网络错误。 /Default.asp,行 136 源程序136行为: connn.Open "driver={Microsoft Access Driver (*.mdb)};pwd=;dbq=" & mdbpathIIS中左侧简化了很多,功能都集中在右键菜单和右侧列表中。IIS几乎有了调试功能了选中“Application Pools“ ,右键菜单中Advanced Settings中Enable 32-bit Application 选择"true&quo...
总共47页,当前第40页 | 页数: - 30
- 31
- 32
- 33
- 34
- 35
- 36
- 37
- 38
- 39
- 40
- 41
- 42
- 43
- 44
- 45
- 46
- 47
最新评论