Ext4 on SSD Intel X25-M
Hi,
[please, leave me on cc because I'm not subscribed on this ML]
I'm using Intel SSD X25-M on my laptop, and I always hear that is not a good idea use journal on SSD (it decrease the life time).
I ask Intel about this, but I don't receive any answer.
So, I would like to know if is possible disable Journal on EXT4.
I'm using Debian Testing (squeeze).
Regards,
Renato S. Yamane
Quoted 9 lines · Renato S. Yamane
Hi,
[please, leave me on cc because I'm not subscribed on this ML]
I'm using Intel SSD X25-M on my laptop, and I always hear that is not a good idea use journal on SSD (it decrease the life time).
I ask Intel about this, but I don't receive any answer.
So, I would like to know if is possible disable Journal on EXT4.
It is possible, mkfs with "-O ^has_journal" but then of course you ... have no journaling.
However, Intel has always said, I think, that you should treat their SSDs just like you would treat any other hard drive, so I probably would not hesitate to leave the journal intact.
There is a write lifetime of course, but I think it's much better than if you were writing to, say, a securedigital card.
-Eric
Quoted 8 lines
I'm using Debian Testing (squeeze).
Regards,
Renato S. YamaneSignature · 3 lines
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 10 lines · Renato S. Yamane
Hi,
[please, leave me on cc because I'm not subscribed on this ML]
I'm using Intel SSD X25-M on my laptop, and I always hear that is not a good idea use journal on SSD (it decrease the life time).
I ask Intel about this, but I don't receive any answer.
So, I would like to know if is possible disable Journal on EXT4.
It is possible to create an ext4 file system without a journal. It would mean that unclean shutdowns would require a full fsck, which on a freshly created file system on an SSD isn't _that_ bad. Depending on how full/fragmented your filesystem happens to be, it will probably be under 10 seconds.
That being said, though, it shouldn't be necessary to avoid using a journal on the Intel SSD. Intel says that laptop will last at least 5 years with 10GB worth of writes per day, and that's a huge amount. I have an X25-M SSD in my laptop, using an ext4 file system and with the journal enabled, and since the file system was created 266 days ago, when I put my X25-M into service, the drive has seen 570GB worth of writes, so I'm averaging 2.14 GB writes per day. That's well under the 20GB of writes/per day upon which Intel based its 5 year lifetime (and most hard drives, and heck, most laptops generally aren't in service for that long before they are replaced.)
I have done a few things to reduce needless disk utilization, such as using tmpfs for /tmp and configuring firefox to place its cache in /tmp, but the bottom line is I wouldn't really worry that much about the journal. If you really want to run without a journal, you can use "mke2fs -t ext4 -O ^has_journal /dev/XXX" to format an ext4 filesystem without a journal. But there will be some distinct tradeoffs with omitting the journal, including possibility that sometimes on an unclean shutdown you will need to do a manual e2fsck pass.
Best regards,
- Ted
Quoted 16 lines · Theodore Tso
Quoted 8 lines · Renato S. Yamane
[please, leave me on cc because I'm not subscribed on this ML]
I'm using Intel SSD X25-M on my laptop, and I always hear that is not a good idea use journal on SSD (it decrease the life time).
I ask Intel about this, but I don't receive any answer.
So, I would like to know if is possible disable Journal on EXT4.
It is possible to create an ext4 file system without a journal. It would mean that unclean shutdowns would require a full fsck, which on a freshly created file system on an SSD isn't _that_ bad. Depending on how full/fragmented your filesystem happens to be, it will probably be under 10 seconds.
Quoted 3 lines
That being said, though, it shouldn't be necessary to avoid using a journal on the Intel SSD. Intel says that laptop will last at least 5 years with 10GB worth of writes per day...
Woww! Thank you so much Theodore and Eric!
I will keep using journal on my SSD X25-M.
Regards,
Renato S. Yamane
Quoted 4 lines · Theodore Tso
I have done a few things to reduce needless disk utilization, such as using tmpfs for /tmp and configuring firefox to place its cache in /tmp,
OT, but these two together seems rather pointless, could as well keep it in its own memory then when it's in memory anyways. That will be faster.
-Andi (who generally disables firefox disk caching)
Signature · 1 line
[email protected] -- Speaking for myself only.
Quoted 9 lines · Andi Kleen
Quoted 4 lines · Theodore Tso
I have done a few things to reduce needless disk utilization, such as using tmpfs for /tmp and configuring firefox to place its cache in /tmp,
OT, but these two together seems rather pointless, could as well keep it in its own memory then when it's in memory anyways. That will be faster.
Well, technically it's not the same, since tmpfs is swappable --- but in my case where I have 4GB of memory in my laptop and swap is disabled (and perhaps for most users), you're right, it's probably better to increase firefox's memory cache and disable it's disk cache entirely.
- Ted
* Theodore Tso:
Quoted 7 lines
That being said, though, it shouldn't be necessary to avoid using a journal on the Intel SSD. Intel says that laptop will last at least 5 years with 10GB worth of writes per day, and that's a huge amount. I have an X25-M SSD in my laptop, using an ext4 file system and with the journal enabled, and since the file system was created 266 days ago, when I put my X25-M into service, the drive has seen 570GB worth of writes, so I'm averaging 2.14 GB writes per day.
That really depends on the software you use. Just fetching mail on my machine causes about 500 MB of data written to disk. That's because I'm using Gnus with nnml and slightly large mail folders and Gnus rewrites those index files from scratch each time new mail for a folder arrives. I should really consider this a bug and fix it, but I haven't yet found a good solution.
Quoted 9 lines · Florian Weimer
* Theodore Tso:
Quoted 7 lines
That being said, though, it shouldn't be necessary to avoid using a journal on the Intel SSD. Intel says that laptop will last at least 5 years with 10GB worth of writes per day, and that's a huge amount. I have an X25-M SSD in my laptop, using an ext4 file system and with the journal enabled, and since the file system was created 266 days ago, when I put my X25-M into service, the drive has seen 570GB worth of writes, so I'm averaging 2.14 GB writes per day.
Quoted 6 lines
That really depends on the software you use. Just fetching mail on my machine causes about 500 MB of data written to disk. That's because I'm using Gnus with nnml and slightly large mail folders and Gnus rewrites those index files from scratch each time new mail for a folder arrives. I should really consider this a bug and fix it, but I haven't yet found a good solution.
So sorry for this stupid question, but...
How can I know the average writes per day?
I try run smart, but it not help me:
ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE 3 Spin_Up_Time 0x0000 100 000 000 Old_age
Offline - 0
4 Start_Stop_Count 0x0000 100 000 000 Old_age
Offline - 0
5 Reallocated_Sector_Ct 0x0002 100 100 000 Old_age
Always - 0
9 Power_On_Hours 0x0002 100 100 000 Old_age
Always - 229
12 Power_Cycle_Count 0x0002 100 100 000 Old_age
Always - 62
192 Power-Off_Retract_Count 0x0002 100 100 000 Old_age Always
- 48
232 Unknown_Attribute 0x0003 100 100 010 Pre-fail Always
- 0
233 Unknown_Attribute 0x0002 099 099 000 Old_age Always
- 0
225 Load_Cycle_Count 0x0000 200 200 000 Old_age Offline - 44867 226 Load-in_Time 0x0002 255 000 000 Old_age Always
- 0
227 Torq-amp_Count 0x0002 000 000 000 Old_age Always
- 0
228 Power-off_Retract_Count 0x0002 000 000 000 Old_age Always
- 0
Reagards,
Renato S. Yamane
* Renato S. Yamane:
Quoted 1 line
How can I know the average writes per day?
I used iostat (part of sysstat). Perhaps I should have checked first if it is accurate. 8-/
Quoted 6 lines · Florian Weimer
* Renato S. Yamane:
Quoted 1 line
How can I know the average writes per day?
I used iostat (part of sysstat). Perhaps I should have checked first if it is accurate. 8-/
If you're running ext4, you can look at:
/sys/fs/ext4/sdXX/lifetime_write_kbytes and/sys/fs/ext4/sdXX/session_write_kbytes
too.
-Eric
Quoted 10 lines · Eric Sandeen
Quoted 5 lines · Florian Weimer
* Renato S. Yamane:
Quoted 1 line
How can I know the average writes per day?
I used iostat (part of sysstat). Perhaps I should have checked first if it is accurate. 8-/
If you're running ext4, you can look at:
/sys/fs/ext4/sdXX/lifetime_write_kbytesand/sys/fs/ext4/sdXX/session_write_kbytes
smartctl show me 229h Power_On_Hours (I buy it one month ago). And /sys/fs/ext4/sdXX/lifetime_write_kbytes show me 19940467
So:
229h = 9,54 days
19940467 kbytes / 9,54 days = 2Gb/day
I think that it is too much. I use it on my laptop only to see my e-mails (Thunderbird) and use OpenOffice.org on my work environment.
Regards and thanks for all!
Renato S. Yamane
Quoted 5 lines · Eric Sandeen
Quoted 4 lines · Florian Weimer
* Renato S. Yamane:
Quoted 1 line
How can I know the average writes per day?
Quoted 7 lines
Quoted 2 lines
I used iostat (part of sysstat). Perhaps I should have checked first if it is accurate. 8-/
If you're running ext4, you can look at:
/sys/fs/ext4/sdXX/lifetime_write_kbytesand/sys/fs/ext4/sdXX/session_write_kbytes
For an umounted filesystem, you can also do this:
dumpe2fs -h /dev/XXX | grep "Lifetime writes"
dumpe2fs -h /dev/XXX | grep "Filesystem created"
Then use a handy-dandy date calculator to figure the number of days between the file system creation date and today, and then divide...
- Ted
Quoted 15 lines · Renato S. Yamane
Quoted 10 lines · Eric Sandeen
Quoted 5 lines · Florian Weimer
* Renato S. Yamane:
Quoted 1 line
How can I know the average writes per day?
I used iostat (part of sysstat). Perhaps I should have checked first if it is accurate. 8-/
If you're running ext4, you can look at:
/sys/fs/ext4/sdXX/lifetime_write_kbytesand/sys/fs/ext4/sdXX/session_write_kbytessmartctl show me 229h
Power_On_Hours(I buy it one month ago). And/sys/fs/ext4/sdXX/lifetime_write_kbytesshow me 19940467
Quoted 6 lines
So:
229h = 9,54 days
19940467 kbytes / 9,54 days = 2Gb/dayI think that it is too much. I use it on my laptop only to see my e-mails (Thunderbird) and use OpenOffice.org on my work environment.
If you've only had the disk for a short while, then the initial writes to install your system is probably biasing your results. So far you have approximately 19GB of disk writes. I'm guessing that at least 3-4GB is from the initial installation of software on your system.
Also, if you are turning off your laptop at night, treating 229 hours as 9.5 days isn't really fair. If you installed the SSD a month ago, then treat that as 30 days, and we get:
16GB / 30 == 0.533 GB
This is well under the rated 20GB/day upon which Intel guarantees a five year life --- and most people don't keep their laptop and/or hard drives that long anyway.
- Ted
Quoted 32 lines · Theodore Tso
Quoted 15 lines · Renato S. Yamane
Quoted 10 lines · Eric Sandeen
Quoted 5 lines · Florian Weimer
Quoted 1 line · Renato S. Yamane
How can I know the average writes per day?
I used iostat (part of sysstat). Perhaps I should have checked first if it is accurate. 8-/
If you're running ext4, you can look at:
/sys/fs/ext4/sdXX/lifetime_write_kbytesand/sys/fs/ext4/sdXX/session_write_kbytessmartctl show me 229h
Power_On_Hours(I buy it one month ago). And/sys/fs/ext4/sdXX/lifetime_write_kbytesshow me 19940467Quoted 6 lines
So:
229h = 9,54 days
19940467 kbytes / 9,54 days = 2Gb/dayI think that it is too much. I use it on my laptop only to see my e-mails (Thunderbird) and use OpenOffice.org on my work environment.
If you've only had the disk for a short while, then the initial writes to install your system is probably biasing your results. So far you have approximately 19GB of disk writes. I'm guessing that at least 3-4GB is from the initial installation of software on your system.
Also, if you are turning off your laptop at night, treating 229 hours as 9.5 days isn't really fair. If you installed the SSD a month ago, then treat that as 30 days, and we get:
Quoted 5 lines
16GB / 30 == 0.533 GBThis is well under the rated 20GB/day upon which Intel guarantees a five year life --- and most people don't keep their laptop and/or hard drives that long anyway.
Wow! You are really right!
Thank you so much Theodore, Eric and Florian!
I'm very happy with this SSD! It's really faster!
Regards,
Renato S. Yamane
Quoted 4 lines · Theodore Tso
If you've only had the disk for a short while, then the initial writes to install your system is probably biasing your results. So far you have approximately 19GB of disk writes. I'm guessing that at least 3-4GB is from the initial installation of software on your system.
I just did a default Ubuntu Karmic x86_64 install, and it writes a approximately ten and a half GB to the root partition. It also (for no explicable reason) apparently zero's out the swap partition, which
(a) takes a long time, and (b) results in useless, pointless writes to the SSD. Someone should complain to Ubuntu about that... the workaround is to not configure swap during the Ubuntu install process, and to manually configure it yourself later.
(Or to not use swap at all, if you have enough memory in your system.)
In any case, given that means that only 8.5GB worth of data was written to your system, so over 30 days, your usage levels is averaging to 0.283 GB per calendar day.
- Ted
Quoted 14 lines · Theodore Tso
Quoted 4 lines · Theodore Tso
If you've only had the disk for a short while, then the initial writes to install your system is probably biasing your results. So far you have approximately 19GB of disk writes. I'm guessing that at least 3-4GB is from the initial installation of software on your system.
I just did a default Ubuntu Karmic
x86_64install, and it writes a approximately ten and a half GB to the root partition. It also (for no explicable reason) apparently zero's out the swap partition, which
(a) takes a long time, and (b) results in useless, pointless writes to the SSD. Someone should complain to Ubuntu about that... the workaround is to not configure swap during the Ubuntu install process, and to manually configure it yourself later.
Quoted 5 lines
(Or to not use swap at all, if you have enough memory in your system.)
In any case, given that means that only 8.5GB worth of data was written to your system, so over 30 days, your usage levels is averaging to 0.283 GB per calendar day.
I'm working with my laptop by 9h right now (this is my tipical business day) and /sys/fs/ext4/sda1/session_write_kbytes show me "324732"
So, I think that you is really right.
Renato S. Yamane