利用SOAtest建立自动化测试验证网站是否成功加载

 
当前,我利用wordpress在阿里云平台构建了一个网站,但因为网站访问量日渐加大,阿里云服务器的负载会超出符合,尤其是mysql会自动中断执行。报告如下类似错误:
intermittent MySQL crashes with error "Fatal error: cannot allocate memory for the buffer pool"
 
140416 11:37:24 mysqld_safe Number of processes running now: 0
140416 11:37:24 mysqld_safe mysqld restarted
140416 11:37:24 [Note] Plugin 'FEDERATED' is disabled.
140416 11:37:24 InnoDB: The InnoDB memory heap is disabled
140416 11:37:24 InnoDB: Mutexes and rw_locks use GCC atomic builtins
140416 11:37:24 InnoDB: Compressed tables use zlib 1.2.3
140416 11:37:24 InnoDB: Using Linux native AIO
140416 11:37:24 InnoDB: Initializing buffer pool, size = 128.0M
InnoDB: mmap(137363456 bytes) failed; errno 12
140416 11:37:24 InnoDB: Completed initialization of buffer pool
140416 11:37:24 InnoDB: Fatal error: cannot allocate memory for the buffer pool
140416 11:37:24 [ERROR] Plugin 'InnoDB' init function returned error.
140416 11:37:24 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
140416 11:37:24 [ERROR] Unknown/unsupported storage engine: InnoDB
140416 11:37:24 [ERROR] Aborting
 
 
解决方式:
调整mysql的设置,通常修改my.cnf或mysql.ini文件,将其中的innodb缓存空间设置调小,如下所示:
## Edit /etc/my.cnf, and add the following line under the [mysqld] heading.
[mysqld]
innodb_buffer_pool_size=64M
 
当修改完成后,网站还是有可能会不定期挂掉。那么如何有效地自动化测试和验证网站的有效性,我这里推荐使用SOAtest构建自动化测试场景来验证网站的有效,在SOAtest中可以快速构建网站的自动化录制场景,并且可以快速设定回归测试Tool — Diff来通过判断消响应息头是否包含正确的内容来判定网站服务是否正常开启,还是出现了问题。
 
所以,我构建了一个SOAtest自动化测试场景,并且在该工具的配置项中设定了自动发送邮件报告到我个人工作邮箱;同时,设定操作系统每晚11点自动执行该测试场景。
 
 
 

转载于:https://www.cnblogs.com/kwang-cai/p/5534715.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值