记录关于Devops运维,虚拟化容器云计算,数据库,网络安全等各方面问题。
解决Win2003频繁出现无法连接MySQL 服务器环境Win2003+IIS+MySQL5搭建的DedeCMS和Discuz,总是频繁出现无法连接MySQL数据库,刷新又正常了,错误如下:MySQL ErrorMessage: Can not connect to MySQL serverSQL:Error: Can't connect to MySQL server on 'localhost' (10061)Errno.: 2003有时出空白页,有时很慢,搜索了许多方法都没有解决,包括MySQL数据库优化,注册表中TcpTimedWaitDelay设置为30 ~ 60 之间,没有用,重启MySQL服务,也没有用,总是经常出现无法连接MySQL,刷新一下又好了。一直以为是DedeCMS或Discuz引起的无法连接MySQL数据库,搜索网络中提供的很多方法都没有用,疏不知,这是微软补丁KB967723造成的MySQL频繁无法连接。Win2003频繁出现无法连接MySQL的解决方法微软官方解决方案:http://support.microsoft.com/kb/q196271老方法:卸载KB967723补丁:登录服务器,进入控制面板 — 添加和删除程序 — (勾选上方的“显示更新”)在里面可以看到更新的KB967723这个补丁,然后就想卸载普通软件一样卸载,卸载中会提示你,如果卸载可能导致程序运行出错,没关系,选择“是”,继续卸载。卸载完成后程序...
MySQL错误:Got error 28 from storage engine 今天打开网站登陆会员时提示MySQL错误:Got error 28 from storage engine ,查到错误的原因。产生该错误的原因是:临时空间不够,无法执行此SQL语句。解决办法:清空/tmp目录,或者修改my.cnf中的tmpdir参数,指向具有足够空间目录。类似的错误提示有:ERROR 1030 (HY000): Got error 28 from storage engine而我的VPS 查看硬盘空间100%了。然后想起apache日志文件很多。删除下日志文件。就恢复正常了
PureFTPd+Mysql+PHP_Manager实现虚拟用户磁盘限额 前几天为了让全校老师都能用上校内的FTP,决定在FreeBSD4.9下装支持虚拟用户带磁盘限额的FTP软件。开始的时候我想过用PROFTPD,可是试了一下,对Mysql数据的用户管理支持不能满足我的要求,听大家说PureFTPd对Mysql等数据库的支持不错,于是开始转向这个FTP软件。 在安装PureFTPd以前,要做好以下准备工作: 1. 安装FreeBSD4.9系统。 2. 定制内核,在内核中加入“options QUOTA”以实现用户配额的支持(注:其他*nix系统如何实现,请各位自己搜索实现。) 3. 安装好APACHE+PHP平台,因为我们后面要用PHP_Manager实现用户在线管理。(注:关于这个安装的内容网上有很多教程,在FreeBSD下可以直接用PORTS方式安装就可以了。) 做好以上准备工作之后,我们就可以开始进入真正的安装过程了。 (注:以下安装全部采用PORTS方式安装) 一、 安装Mysql 我安装的Mysql是4.0版本的,所以如果有最新大家也可以尝试啊。 # cd /usr/ports/datab...
今天接到电信通知,说我服务器发送垃圾邮件要封IP,赶紧检查,果然发现有600多个发送列表,只能马上关闭POSTFIX,但是我的POSTFIX是要验证才能发送MAIL的呀,原来是SQUID 惹的麻烦,最后得到高人指点,修改了SQUID的配置才,把问题解决了. ########## Base control ########## cache_mgr webmaster cache_effective_user squid cache_effective_group squid http_port 61.152.246.142:80 icp_port 0 cache_dir ufs /tmp/squid 300 16 256 error_directory /usr/local/etc/squid/errors/Simplify_Chinese icon_directory /usr/local/etc/squid/icons mime_table /usr/local/etc/squid/mime.conf coredump_dir /usr/local/squid pid_filename /usr/local/squid/logs/squid.pid hosts_file /etc/hosts ########## Performance control ########## cache_mem 128 MB #\xb8\xfc\xb8\xc4\xce\xaa\xc4\xe3\xd0\xe8\xd2\xaa\xbb\xba\xb3\xe5\xb5\xc4\xc4\xda\xb4\xe6\xb4\xf3\xd0\xa1\xa3\xac\xb5\xab\xb d\xa8\xd2\xe9\xb2\xbb\xb4\xf3\xd3...
xen web 管理软件 openQRM Installation openQRM 4.9 on CentOS/RHEL: 1) Add the RPMforge repository -> http://wiki.centos.org/AdditionalResources/Repositories/RPMForge 2) run "yum install subversion make" 3) run "svn co https://openqrm.svn.sourceforge.net/svnroot/openqrm openqrm" 4) run "cd openqrm/trunk/src" 5) run "make && make install && make start" Update to openQRM 4.9 on CentOS/RHEL: 1) Follow steps 1-4) of "Installation openQRM 4.9 on CentOS/RHEL" 2) Instead of step 5) run "make && make update" xenwebmanager CentOS¶ If you want to install xenwebmanager on a CentOS 5&...
Zimbra 安装配置准备 安装环境:RHEL 5.4 X86_64 关闭防火墙:[root@zimbra-test ~]# service iptables stop 运行ntsysv,设定iptables不自动启动 关闭SELINUX:[root@zimbra-test ~]# setenforce0 修改/etc/sysconfig/selinux,设定SELINUX=disabled 确定安装服务器的IP地址,本例中使用10.182.0.37 关闭sendmail服务:[root@zimbra-test ~]# service sendmail stop [root@zimbra-test ~]# chkconfig sendmail off 设定host zimbra的安装需要配置正确的FQDN,即需要在host文件中加入当前服务器的IP与域名,形如 10.182.0.37 mail.zimbra-test.com mail 安装配置DNS解析 这一步骤不是必须的,如果你的安装环境中存在DNS服务器,且该DNS的MX记录未被占用或可以更改,那么请修改你的DNS服务器MX记录,然后跳过此步骤; 如果你需要进行zimbra的测试安装,或需要保持原有邮件系统的正常运行,待指定时间进行系统切换,那么请完成此步骤。 确定服务器是否安装了named,确定如下包已安装 [root@zimbra-test ~]# rpm -qa | grep bind bind-9.3.6-4.P1.el5 ypbind-1.19-12.el5 bind-libs-9.3.6-4.P1.el5 bind-chroot-9.3.6-4.P1.el5 bind-utils-...
FLV 在ASP网站上用不了MIME type 的功能你可以添加
MIME类型:flv-application/octet-stream 扩展名:.flv
或者
MIME类型: video/x-flv 扩展名:.flv
处理apache虚拟主机权限 Windows下处理apache虚拟主机的权限: 1、开启安全模式,可以禁用exec()、system()等函数。 2、在httpd.conf中用php_admin_value open_basedir限制PHP的存取目录。 3、在php_admin_value open_basedir别忘了加上php.ini中指定的PHP临时上传目录和session保存目录,不然会无法上传文件、存取session。 php.ini中按如下配置: upload_tmp_dir = "E:/APMServ5.2.0/PHP/uploadtemp/" session.save_path = "E:/APMServ5.2.0/PHP/sessiondata/" 4、Apache2.0配置示例: <VirtualHost *:80> ServerName www.abc.com DocumentRoot "E:/smis" Options FollowSymLinks IncludesNOEXEC Indexes DirectoryIndex index.html index.htm default.htm index.php default.php AllowOverride None Order Deny,Allow Allow from all php_admin_value open_basedir "E:/smis/;E:/APMServ5.2.0/PHP/uploadtemp/;E:/APMServ5.2.0/PHP/sessiondata/" php_admin_value safe_mode On &...
在apache下限制每个虚拟主机的并发数!!!!下载模块: http://www.nowhere-land.org/prog ... st_limit-0.4.tar.gz 官方网址: http://www.nowhere-land.org/programs/mod_vhost_limit/ 安装: apxs -c mod_vhost_limit.c -o /path/to/libexec/mod_vhost_limit.so 在 httpd.conf 加入: LoadModule vhost_limit_module libexec/mod_vhost_limit.so AddModule mod_vhost_limit.c 配置: MaxClients 150 ExtendedStatus On NameVirtualHost * <VirtualHost *> ServerName server1DocumentRoot /some/where/1 MaxVhostClients 100</VirtualHost><VirtualHost *> ServerName server2 DocumentRoot /some/where/2 MaxVhostClients 30</VirtualHost> <VirtualHost *> ServerName server3 DocumentRoot /some/where/3 </VirtualHost> 其中: server1 被限制为 100 个并发线程数。 server2 被限制为 30 个并发线程数。 server3 没有被限制。 注:需 mod_status 的 ExtendedStatus On 支持如超出限制的并发数在客户端就会出现503错误: Service Temporarily Unavailable The server is temporarily unable to service your request due to main...
Centos 6.0 yum源修改 首先登陆SSH,然后先备份一下/etc/yum.repos.d/CentOS-Base.repo 展开/关闭 下载 code.txt1
#mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak然后把/etc/yum.repos.d/CentOS-Base.repo文件改为以下的yum源 展开/关闭 下载 code.txt1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# CentOS-Base.repo
#
# This file uses a new mirrorlist system developed by Lance Davis for CentOS.
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror ...
最新评论