首页 > linux, mysql > ext4 mysql flush_log 相关

ext4 mysql flush_log 相关

2013年6月7日 eric 发表评论 阅读评论

最近有一些业务服务器开始使用6.3服务器,顾客开始说访问页面会卡,主要反映在切换页面,数据交互等,开始开始技术排查问题,同样的代码,同样的 apache mysql php 的配置,在 5.5 上运行很正常,在 6.3 运行就会卡。把问题转交到我手上,我开始对操作系统进行了排查。
发现 5.5 服务器内核是 2.6.18,6.3的服务器内核是 2.6.32。查看硬件配置也是一样的,查看两边的 mysql配置文件也一样,这时候我觉得是不是 6.3 与 5.5 开机挂载磁盘的参数不一样呢?

两边都执行 cat /proc/mounts 后发现6.3 多一个 barrier=1 参数 而 5.5 没有,经过 google 发现这个参数是 2.6.22 以上内核开始有的,barrier=1,可以保证文件系统在日志数据写入磁盘之后才写commit记录,但影响性能。但是我们的 mysql 有个参数是每次的操作都要flush日志,这样的话每次就要提交两次,一就是有序写入。我们之前都是无序写入,虽然提高了安全性能,但是降低了性能,权衡之后我还是把 mysql 的参数改为2,这样的话我最多能丢失上一秒的数据,在可控范围内innodb_flush_log_at_trx_commit = 2
这样 6.3 不会出现卡的情况了。

转载请注明:文章转载自:Eric's linux and nginx! (http://www.nginxs.com)
本文地址:http://www.nginxs.com/linux/511.html

分类: linux, mysql 标签: , ,
  1. 2017年8月9日11:55 | #1

    Hi to every one, since I am really eager of reading this webpage’s post to be updated on a regular basis.
    It consists of pleasant data.

  2. 2017年8月9日12:14 | #2

    Yesterday i read some shocking info about Omega 3 foods and now i very wanna get it. But i’m not absolutely sure which pluses will i have. I’ve found this omega 3 info , and now i wanna purchase it with lowest price. Any idea?

  3. 2017年8月9日18:02 | #3

    If you desire to take a good deal from this paragraph then you have to apply such methods to your won website.

  4. 2017年8月9日22:35 | #4

    Hurrah! Finally I got a webpage from where I know how to genuinely
    get useful facts concerning my study and knowledge.

  5. 2017年8月10日04:13 | #5

    Yesterday i got some amazing info about Omega 3 stuff and now i really wanna buy it. But i’m not absolutely sure which pluses will i have. I’ve found this omega 3 info , and currently i wanna purchase it with best price. Any idea?

  6. 2017年8月10日17:53 | #6

    For hottest news you have to pay a visit internet and on web I found this site as a best
    web site for latest updates.

  7. 2017年8月10日20:41 | #7

    Day ago i read some amazing info about Omega 3 stuff and now i very wanna buy it. But i’m not absolutely sure which benefits will i have. I’ve found this omega 3 info , and currently i wanna get it with lowest price. Any idea?

  8. 2017年8月11日07:17 | #8

    Its like you read my mind! You appear to know so much about this, like you wrote the book
    in it or something. I think that you can do with a
    few pics to drive the message home a bit, but instead of that, this
    is great blog. A fantastic read. I’ll certainly be back.

  9. 2017年8月11日11:19 | #9

    Wonderful beat ! I would like to apprentice while you amend your web site, how
    can i subscribe for a weblog web site? The account helped me a appropriate deal.
    I had been a little bit familiar of this your broadcast offered
    brilliant transparent idea

  10. 2017年8月11日13:04 | #10

    Day ago i read some interesting info about Omega 3 stuff and now i really wanna get it. But i’m not really sure which benefits will i have. I’ve got this omega 3 info , and now i want to purchase it with best price. Any idea?

  11. 2017年8月12日05:58 | #11

    Yesterday i read some shocking info about Omega 3 foods and now i very wanna get it. But i’m not absolutely sure which pluses will i have. I’ve found this omega 3 info , and currently i wanna buy it with lowest price. Any idea?

  12. 2017年8月12日19:48 | #12

    I know this if off topic but I’m looking into starting my own blog and was wondering what all is
    required to get setup? I’m assuming having
    a blog like yours would cost a pretty penny? I’m not very web smart
    so I’m not 100% certain. Any suggestions or
    advice would be greatly appreciated. Thanks

  13. 2017年8月12日22:28 | #13

    Yesterday i read some cool info about Omega 3 foods and now i really wanna buy it. But i’m not absolutely sure which benefits will i have. I’ve got this omega 3 info , and currently i wanna get it with good price. Any idea?

  14. 2017年8月13日08:38 | #14

    What’s Taking place i am new to this, I stumbled upon this I have found It absolutely helpful and it
    has helped me out loads. I hope to contribute & aid other customers like
    its helped me. Great job.

  15. 2017年8月13日13:25 | #15

    ВНИМАНИЕ!!! Ядекс и отношение к клиентам смотреть всем!!!
    Посмотрел и был в ШОКЕ….
    Вот ссылка на Ютуб
    https://www.youtube.com/watch?v=IdYDpLcuVnA

  16. 2017年8月13日15:05 | #16

    Day ago i read some cool info about Omega 3 stuff and now i really wanna buy it. But i’m not really sure which pluses will i have. I’ve found this omega 3 info , and now i wanna get it with good price. Any idea?

  17. 2017年8月13日23:39 | #17

    [url=http://rrr.regiongsm.ru/33]
    [img]http://rrr.regiongsm.ru/32 [/img]
    [/url]
    Благоустройство и асфальтрование в г. Краснодаре и г.Кропоткин. Решение любого вопроса по Благоустройству Краснодара и края. Под ключ

    Подробнее… Благоустройство-Краснодар.РФ … +7 (861) 241-23-45
    ___________________________
    алтайский край благоустройство конкурс
    программа благоустройство дворовых территорий московская область
    благоустройство территории участка на генплане
    ооо благоустройство пермь сайт
    благоустройство территории красноярского

  18. 2017年8月14日09:08 | #18

    Day ago i got some cool info about Omega 3 foods and now i very wanna buy it. But i’m not absolutely sure which benefits will i have. I’ve found this omega 3 info , and currently i wanna get it with lowest price. Any idea?

  19. 2017年8月14日13:41 | #19

    Hello this is kinda of off topic but I was
    wanting to know if blogs use WYSIWYG editors or if you have to manually code with HTML.
    I’m starting a blog soon but have no coding knowledge
    so I wanted to get advice from someone with experience.
    Any help would be enormously appreciated!

  20. 2017年8月15日11:01 | #20

    Hurrah, that’s what I was seeking for, what a stuff!
    present here at this blog, thanks admin of this site.

  21. 2017年8月15日16:26 | #21

    If you wish for to take much from this paragraph then you have to apply
    such strategies to your won website.

  22. Avito777Max
    2017年8月16日04:13 | #22

    Пополение баланса Авито (Avito) за 50% | Телеграмм @a1garant

    Здравствуйте, дорогие друзья!

    Готовы предоставить Всем вам сервис по пополнению баланса на действующие активные аккаунты Avito (а также, абсолютно новые). Если Вам надо конкретные балансы – пишите, будем решать. Потратить можно на турбо продажи, любые платные услуги Авито (Avito).

    Аккаунты не Брут. Живут долго.

    Процент пополнения в нашу сторону и стоимость готовых аккаунтов: 50% от баланса на аккаунте.
    Если необходим залив на ваш аккаунт, в этом случае требуются логин и пароль Вашего акка для доступа к форме оплаты, пополнения баланса.
    Для постоянных заказчиков гибкая система бонусов и скидок!
    Гарантия:

    И, конечно же ничто не укрепляет доверие, как – Постоплата!!! Вперед денег не просим… А также, гасим Штрафы ГИБДД за 65% …

    Оплата:
    ЯндексДеньги, Webmoney (профессиональные счета)
    Рады сотрудничеству!

    канал Телеграмм @t.me/avito50
    ________

    турбо пакеты +на авито
    авито рубцовск доска бесплатных объявлений
    скидки +на авито
    одежда пакетом авито спб
    аккаунты авито +с балансом

  23. 2017年8月16日16:00 | #23

    You can definitely see your expertise in the work you write.
    The world hopes for even more passionate writers like you who
    aren’t afraid to say how they believe. All the
    time follow your heart.

  24. 2017年8月16日20:35 | #24

    Few days ago i read some cool knowledge about Omega 3 stuff and now i very want to get it. But i want a quality, some premium omega 3 fish oil. I’ve seen this premium omega 3 fish oil link. What do you think about this brand?

  25. 2017年8月17日00:48 | #25

    Truly no matter if someone doesn’t be aware of after that its up to other viewers that they
    will assist, so here it happens.

评论分页
1 2 3 511
订阅评论
1+3= (必填)