dongmo3413 2012-07-02 11:26
浏览 13
已采纳

如何优化大型内容网站的网页和数据库

A website which is related to shopping e-commerce. The website having huge number of data to be stored in DB. so far the products table in db is having nearly 18K records with 20 fields. i have created the db structure as follows

 - brands
 - products
 - shopslist
 - shopping_details

The website is having 100+ pages everything related to products and brands.

eg.pages are 
www.example.com/nokia-mobile-phones.php , www.example.com/samsung-mobile-phones.php 
www.example.com/samsung-galaxy-s3-price.php,www.example.com/android-mobile-phones.php

i have written the queries to fetch the product details corresponding to the pages dynamically. This makes my website some what slower in grabbing the data from db ans displaying.

Currently website is having nearly 14k to 15k visits per day. suddenly the website becomes very slow and stops responding for more than 10hrs a day. The technical people on hosting side said the problem is due to more number of requests in a single day and your db occupies 75% of the memory , optimize your site and db for better results . The website is hosted in VPS with better configurations.

Kindly give a solutions for optimizing a website , queries and db.

  • 写回答

3条回答 默认 最新

  • dougan7657 2012-07-02 11:49
    关注
    1. Use Caching Systems

    2. Avoid Resizing Images in HTML, If an image is originally 1280x900px in dimension. (i.e. <img width="400" height="280" src="myimage.jpg" />)

    3. Use External JS and CSS Files

    4. Optimize the Way You Write Code - For example, instead of using <h1><em>Your heading</em></h1>, you can easily use CSS to make your headings italics using the font-style property

    5. Use a Content Delivery Network (CDN)

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(2条)

报告相同问题?

悬赏问题

  • ¥15 为什么使用javacv转封装rtsp为rtmp时出现如下问题:[h264 @ 000000004faf7500]no frame?
  • ¥15 乘性高斯噪声在深度学习网络中的应用
  • ¥15 运筹学排序问题中的在线排序
  • ¥15 关于docker部署flink集成hadoop的yarn,请教个问题 flink启动yarn-session.sh连不上hadoop,这个整了好几天一直不行,求帮忙看一下怎么解决
  • ¥30 求一段fortran代码用IVF编译运行的结果
  • ¥15 深度学习根据CNN网络模型,搭建BP模型并训练MNIST数据集
  • ¥15 C++ 头文件/宏冲突问题解决
  • ¥15 用comsol模拟大气湍流通过底部加热(温度不同)的腔体
  • ¥50 安卓adb backup备份子用户应用数据失败
  • ¥20 有人能用聚类分析帮我分析一下文本内容嘛