After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 584522 - Lots of disk writes when accessing some sites
Lots of disk writes when accessing some sites
Status: RESOLVED FIXED
Product: libsoup
Classification: Core
Component: Misc
2.27.x
Other Linux
: Normal normal
: GNOME 2.28
Assigned To: libsoup-maint@gnome.bugs
libsoup-maint@gnome.bugs
Depends on:
Blocks:
 
 
Reported: 2009-06-01 17:57 UTC by Gustavo Noronha (kov)
Modified: 2009-09-08 14:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proposed solution (3.31 KB, patch)
2009-09-08 12:40 UTC, Gustavo Noronha (kov)
none Details | Review

Description Gustavo Noronha (kov) 2009-06-01 17:57:55 UTC
This bug has been reported in the Debian BTS. I believe it has something to do with cookie storage, but not sure. Quoting Luciana Fujii, from http://bugs.debian.org/530964:

After using epiphany-webkit for a while, it started writing on average
450K/s ininterruptly. Althoug epiphany-webkit is using a lot of memory
as reported in bug#530960, I've checked that the writes are not caused
by swapping.

This is a line from strace that can be useful:
write(52, "SQLite format 3\0\4\0\1\1\0@
\0\3\221\217\0\0\0\0\0\0\0\257\0\0\0\33\0\0\0\1\0\0\0\1\0\0\0\0\0\0\0\0
\0\0\0\1\0\0\0\2\0\0\0\0\0\0
\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\r\0\0\0\1
\0031\0\0031\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0
\0\0\0\0\0
\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0
\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0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\0\0\0\0\0\0\0\0\0\0
\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0
\0\0\0\0
\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0
\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\201L\1\7\27##\1
\202_tab
lemoz_cookiesmoz_cookies\2CREATE TABLE moz_cookies (id INTEGER PRIMARY
KEY, name TEXT, value TEXT, host TEXT, path TEXT,expiry INTEGER,
lastAccessed INT     EGER, isSecure INTEGER, isHttpOnly INTEGER)"...,
1024) = 1024

After closing 3 specific windows, leaving the others openned the
behaviour stopped. Those windows had the following pages opened:
http://www.techcrunch.com/2009/05/28/exclusive-video-interview-with-the-google-wave-founders/
http://wave.google.com/
http://www.orkut.com.br/Main#Home.aspx
Comment 1 Gustavo Noronha (kov) 2009-09-08 12:34:57 UTC
Turns out this is caused by cookie handling. Some sites set and delete dozens of cookies per second. Have fun watching this video: http://kov.eti.br/~kov/orkut-disk-IO.ogv.

Cookie handling is also responsible for UI hangs in some sites, such as ohloh.net, which uses a number of cookies. SQLite wants to fsync/fdatasync every write, and this is done synchronously in the main thread.

Openning/closing the DB handle is responsible for its own share of flushes, of course.
Comment 2 Gustavo Noronha (kov) 2009-09-08 12:40:28 UTC
Created attachment 142694 [details] [review]
proposed solution
Comment 3 Gustavo Noronha (kov) 2009-09-08 14:03:17 UTC
Pushed to master.