18

Does anyone know how to avoid getting this message:

Assuming drive cache: write through

Which is showing up after performing sudo shutdown -r now.

I restarted remotely but the computer did not restart. And I can't restore my remote connection to it. I want to be sure that it won't happen again. When I physically approached the computer and turned on the display, I found 3 lines saying:

Assuming drive cache: write through

All those messages were because of my sdd disk. Later I checked and found that sdd is my external USB 1TB disk.

Any ideas on how to prevent such situations in future?

6
  • 1
    I might be wrong, but I don't think this message was the cause of the problem. Mar 26 '11 at 14:13
  • 1
    Well, you might be right... I made such assumption, because computer was frozen and only this message was seen on the screen... Sadly, I did not get any advice. Next time I will have to plan computer restart in advance so I'll be next to my server.
    – ViliusK
    Apr 3 '11 at 20:32
  • sudo update-pciids && update-usbids might fix the Assuming drive cache: write through. It is a command to update PCI and USB id's.
    – Rinzwind
    Aug 20 '11 at 13:34
  • 1
    The message "Assuming drive cache: write through" is from sd_read_cache_type() in the kernel and occurs when revalidating the device. The kernel could not determine the drive caching characteristics so it defaulted to assuming it could support write through and so it emitted this message. For some devices, this may be an erroneous default, but possibly on the majority it is OK. It is classed as an error message as you may not want it to be using this default. The message is a KERN_ERR level kernel message, hence why it appears. Nov 15 '12 at 12:26
  • 3
    why is this closed? i have the same problem
    – philx_x
    Nov 15 '15 at 11:20
6

What does the message: asking for cache data failed, assuming drive cache: write through mean?

The Linux block layer makes some assumptions about when writes are actually committed to disk. LSI RAID controller logical drives pretend to be SCSI disks, but the firmware and driver doesn't report whether the controller is in "write-through" mode or "write-back" mode. Without this information, the block layer assumes "write-through". This is safe, because the controller has a battery-backed cache.

LSI's engineers know that their driver should handle this better so you don't see this message. But it's not an error, and it doesn't affect the system.

1
  • 10
    I don't think that answers the OP's question of how to prevent those messages, @guimaluf
    – Thomas Ward
    Jul 25 '11 at 17:36
2

Stumbled onto a flint-axe type fix -- since this occurs before and after login, started looking for mechanisms that could do that, and thought it might be sent to stdio by dmesg.

Using sudo dmesg -n 1 turned off the messages. It may be possible to automate that in grub. But seems like treating the symptom, not the disease.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.