Q: enable iscsi read/write cache

724 views
Skip to first unread message

info-dtnet

unread,
May 5, 2008, 3:14:22 PM5/5/08
to open-iscsi
Hi,

while looking around in google, if found a logfile
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=467390, where the
iscsi LUN cache is enabled, read+write:
Feb 21 22:19:15 localhost kernel: sd 1:0:0:0: [sdc] Write cache:
enabled, read
cache: enabled, supports DPO and FUA

My dmsg tells me a not enabled write-cache:
May 5 20:48:00 xen04 kernel: scsi190 : iSCSI Initiator over TCP/IP
May 5 20:48:01 xen04 iscsid: connection189:0 is operational now
May 5 20:48:02 xen04 kernel: scsi 190:0:0:0: Direct-Access
SUN SOLARIS 1 PQ: 0 ANSI: 5
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] 10485726 512-byte
hardware sectors (5369 MB)
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] Write Protect is off
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] Write cache:
disabled, read cache: enabled, doesn't support DPO or FUA
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] 10485726 512-byte
hardware sectors (5369 MB)
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] Write Protect is off
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] Write cache:
disabled, read cache: enabled, doesn't support DPO or FUA
May 5 20:48:02 xen04 kernel: sdh: sdh1
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: [sdh] Attached SCSI disk
May 5 20:48:02 xen04 kernel: sd 190:0:0:0: Attached scsi generic sg11
type 0
M
Question: Who can i enable the cache ? hdparms does not work:

[root@xen04 /var/log]$ hdparm -W 1 /dev/sdh

/dev/sdh:
setting drive write-caching to 1 (on)
SG_IO: bad/missing ATA_16 sense data:: 70 00 05 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
HDIO_DRIVE_CMD(setcache) failed: Input/output error
HDIO_DRIVE_CMD(identify) failed: Invalid argument


regards
Danny

Konrad Rzeszutek

unread,
May 5, 2008, 3:51:39 PM5/5/08
to open-...@googlegroups.com

You can't. The disk firmware doesn't support it. Thought I wouldn't worry much about it as
the iSCSI target (EqualLogic, NetApp, IBM, etc) will have a write/read cache - so
the data is being cached and isn't synchronous I/O (unless you define it as so).

Mike Christie

unread,
May 5, 2008, 4:25:46 PM5/5/08
to open-...@googlegroups.com

If you can change this parameter you normally have to do it in some sort
of target setup screen or config file instead of hdparm.

Why do you want this btw? Is it for that bug? If it is you can use the
kernel modules and tools from
http://www.open-iscsi.org/bits/open-iscsi-2.0-869.tar.gz
where the bug is fixed.

Reply all
Reply to author
Forward
0 new messages