Skip to content
Menu
TechDudes.de
  • Allgemein
  • Server
  • Linux
  • Impressum
TechDudes.de

LSI 1068E langsam/slow (13-14 MB/sec writing)

Posted on 14. August 2013 by Dennis

Der LSI SAS1068E bringt in einem Sun X6240 Blade nicht die gewünschte Datenrate und krebst wirklich daher. Bei einem dd erhalte ich folgende Werte:

time dd if=/dev/zero of=/tmp/test oflag=direct bs=64k count=16000
16000+0 records in
16000+0 records out
1048576000 bytes (1.0 GB) copied, 74.7437 s, 14.0 MB/s

real    1m14.745s
user    0m0.009s
sys     0m0.807s

Das ist natürlich viel zu lahm und vor allem möchte ich mit diesem Server ein paar Virtualisierungstests fahren, die zeigen sollen, wie leistungsfähig der gewählte Ansatz ist. Wenn die Festplatte humpelt, kann in dem Fall das gesamte Setup nicht überzeugen. Also mal etwas tiefer nachsehen, wo es hapert – hier ein kleines Log…

In dmesg sehe ich, dass der Schreibcache disabled ist, mache mir deswegen aber keine großen Sorgen, vermute ich doch ein Rebuild des Arrays oder Ähnliches als Bremse:

...
ioc0: LSISAS1068E B3: Capabilities={Initiator}
mptsas 0000:05:00.0: setting latency timer to 64
scsi6 : ioc0: LSISAS1068E B3, FwRev=01185e00h, Ports=1, MaxQ=286, IRQ=19
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 4, phy 0, sas_addr 0x5000c50012d18b05
scsi 6:0:0:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 1, phy 1, sas_addr 0x5000c50012d2646d
scsi 6:0:1:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5
mptsas: ioc0: attaching raid volume, channel 1, id 0
scsi 6:1:0:0: Direct-Access     LSILOGIC Logical Volume   3000 PQ: 0 ANSI: 2
sd 6:1:0:0: [sda] 142577664 512-byte logical blocks: (72.9 GB/67.9 GiB)
sd 6:1:0:0: [sda] Write Protect is off
sd 6:1:0:0: [sda] Mode Sense: 03 00 00 08
sd 6:1:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
 sda: sda1 sda2
sd 6:1:0:0: [sda] Attached SCSI disk
...

Zuerst reboote ich das Blade und schaue mir im MPT-BIOS vom Raidcontroller den Status des RAIDs an. Angeblich „optimal“, also der Spiegel steht, kein Resync in Arbeit, sollte also eigentlich alles flott von statten gehen (?!). Vielleicht hilft mir ein Kommandozeilentool für den Controller weiter. Also mache ich mich auf die Suche nach dem entsprechenden Tool. Einige Leute schreiben, dass sie LSI-Tool in der Bash bevorzugen. LSI hält zum Glück noch eine alte Version auf dem ‚Obsolete‘-Abstellgleis zum Download bereit (-> http://www.lsi.com/downloads/Public/Obsolete/Obsolete%20Common%20Files/LSIUtil_1.62.zip). Gelesen habe ich u.a., dass man mit LSI-Tool bzw. den Adaptereigenen Tools ein paar Paremeter tunen kann  – vielleicht ist das ja brauchbar. Also erstmal an die Installation des selbigen:

wget http://www.lsi.com/downloads/Public/Obsolete/Obsolete%20Common%20Files/LSIUtil_1.62.zip
unzip LSIUtil_1.62.zip
cd Linux
chmod +x *
./lsiutil.x86_64

Und das Tool erscheint:

LSI Logic MPT Configuration Utility, Version 1.62, January 14, 2009

1 MPT Port found

     Port Name         Chip Vendor/Type/Rev    MPT Rev  Firmware Rev  IOC
 1.  /proc/mpt/ioc0    LSI Logic SAS1068E B3     105      01185e00     0

Select a device:  [1-1 or 0 to quit] 1

Ich wähle erst 1 für den Controller,

 1.  Identify firmware, BIOS, and/or FCode
 2.  Download firmware (update the FLASH) 
 4.  Download/erase BIOS and/or FCode (update the FLASH)
 8.  Scan for devices                                   
10.  Change IOC settings (interrupt coalescing)         
13.  Change SAS IO Unit settings                        
16.  Display attached devices                           
20.  Diagnostics                                        
21.  RAID actions                                       
22.  Reset bus
23.  Reset target
42.  Display operating system names for devices
45.  Concatenate SAS firmware and NVDATA files
59.  Dump PCI config space
60.  Show non-default settings
61.  Restore default settings
66.  Show SAS discovery errors
69.  Show board manufacturing information
97.  Reset SAS link, HARD RESET
98.  Reset SAS link
99.  Reset port
 e   Enable expert mode in menus
 p   Enable paged mode
 w   Enable logging

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] 21

dann 21 für das Raid-Action Menü und lasse mir den Status des Spiegels ausgeben.

 1.  Show volumes
 2.  Show physical disks
 3.  Get volume state
 4.  Wait for volume resync to complete
23.  Replace physical disk
26.  Disable drive firmware update mode
27.  Enable drive firmware update mode
30.  Create volume
31.  Delete volume
32.  Change volume settings
33.  Change volume name
50.  Create hot spare
51.  Delete hot spare
99.  Reset port
 e   Enable expert mode in menus
 p   Enable paged mode
 w   Enable logging

RAID actions menu, select an option:  [1-99 or e/p/w or 0 to quit] 3

Die Ausgaben der Menüauflistung, habe ich auch mal auf die Seite für Referenzzwecke gepackt.

RAID actions menu, select an option:  [1-99 or e/p/w or 0 to quit] 3

Volume 0 is Bus 0 Target 0, Type IM (Integrated Mirroring)

Volume 0 State:  optimal, enabled

Offensichtlich ist das RAID1 also gesund. Woran liegt es dann? Ich befrage Google zu dem Thema und finde einen Beitrag im .pQd´s Blog und dieser verlinkt weiter zu pocitace.tomasek.cz . In beiden Fällen soll der Schreibcache aktiviert werden. Variante1: Man soll im Expert mode ein paar Parameter beim Caching neu setzen. An diesse Parameter bin ich übrigens auch nicht direkt über die Serielle Konsole im MPT-BIOS rangekommen, insofern erscheint mir das Tool als mächtigeres Werkzeug ;). Variante 2 setzt das Caching beim RAID-Volume und nicht auf dem Controller selbst.

Bevor es jetzt weitergeht möchte ich hier aber noch eine Warnung anbringen

Warnung

Das Aktivieren des Write-Caches ohne Raidcontroller Batterie führt im Falle eines Stromausfalls evtl. zu einem defekten Dateisystem!

Für mich ist das in einem Testsetup nicht weiter von Bedeutung. Der Server an sich ist redundant mit Strom versorgt (2 Leitungen, 2 Kraftwerke) und außerdem nur eine Spiel- und Testmaschine. Mal abgesehen davon ist der 1068E wirklich nicht mehr taufrisch, wie das gesamte Blade. Für alle flotten Leser: Variante 2 führte bei mir zum Erfolg, Variante 1 hat aber bei anderen Leuten geklappt.

Variante 1 – Caching für den Controller generell aktivieren

Also erstmal den Expertmode angeschaltet. Siehe da, ich habe deutlich mehr Optionen

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] e

Enabled expert mode in menus

 1.  Identify firmware, BIOS, and/or FCode
 2.  Download firmware (update the FLASH)
 3.  Upload firmware
 4.  Download/erase BIOS and/or FCode (update the FLASH)
 5.  Upload BIOS and/or FCode
 6.  Download SEEPROM
 7.  Upload SEEPROM
 8.  Scan for devices
 9.  Read/change configuration pages
10.  Change IOC settings (interrupt coalescing)
13.  Change SAS IO Unit settings
14.  Change IO Unit settings (multi-pathing, queuing, caching)
15.  Change persistent mappings
16.  Display attached devices
17.  Show expander routing tables
18.  Change SAS WWID
19.  Test configuration page actions
20.  Diagnostics
21.  RAID actions
22.  Reset bus
23.  Reset target
24.  Clear ACA
33.  Erase non-volatile adapter storage
34.  Remove device from initiator table
35.  Display Log entries
36.  Clear (erase) Log entries
37.  Force full discovery
40.  Display current events
42.  Display operating system names for devices
44.  Program manufacturing information
45.  Concatenate SAS firmware and NVDATA files
46.  Upload FLASH section
47.  Display version information
48.  Display chip VPD information
49.  Program chip VPD information
50.  Dump MPT registers
51.  Dump chip memory regions
52.  Read/modify chip memory locations
54.  Identify FLASH device
55.  Force firmware to fault (with C0FFEE)
56.  Read/write expander memory
57.  Read/write expander ISTWI device
59.  Dump PCI config space
60.  Show non-default settings
61.  Restore default settings
66.  Show SAS discovery errors
67.  Dump all port state
68.  Show port state summary
69.  Show board manufacturing information
70.  Dump all device pages
80.  Set SAS phy offline
81.  Set SAS phy online
90.  Send SCSI CDB
95.  Send SATA request
96.  Send SMP request
97.  Reset SAS link, HARD RESET
98.  Reset SAS link
99.  Reset port
 e   Disable expert mode in menus
 p   Enable paged mode
 w   Enable logging

Main menu, select an option:  [1-99 or e/p/w or 0 to quit]

Ich wähle die 14, um die Caching Parameter zu manipulieren, wähle aber erstmal die Default werte, um zu sehen, ob ich damit wirklich die gleichen Ergebnisse erhalte:

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] 14

Multi-pathing:  [0=Disabled, 1=Enabled, default is 1] 1
SATA Native Command Queuing:  [0=Disabled, 1=Enabled, default is 1] 1
SATA Write Caching:  [0=Disabled, 1=Enabled, default is 1] 1

Anschließend möchte ich mit einem Neustart testen, ob sich etwas verändert hat.

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] 0

     Port Name         Chip Vendor/Type/Rev    MPT Rev  Firmware Rev  IOC
 1.  /proc/mpt/ioc0    LSI Logic SAS1068E B3     105      01185e00     0

Select a device:  [1-1 or 0 to quit] 0

[root@testserverKVM]# reboot

Nach kurzem Warten fährt das Blade wieder an.

...
mptbase: ioc0: Initiating bringup                                                                                                                                                                    
ioc0: LSISAS1068E B3: Capabilities={Initiator}                                                                                                                                                       
scsi6 : ioc0: LSISAS1068E B3, FwRev=01185e00h, Ports=1, MaxQ=286, IRQ=19                                                                                                                             
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 4, phy 0, sas_addr 0x5000c50012d18b05                                                                                                        
scsi 6:0:0:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5                                                                                                                         
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 1, phy 1, sas_addr 0x5000c50012d2646d                                                                                                        
scsi 6:0:1:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5                                                                                                                         
mptsas: ioc0: attaching raid volume, channel 1, id 0                                                                                                                                                 
scsi 6:1:0:0: Direct-Access     LSILOGIC Logical Volume   3000 PQ: 0 ANSI: 2                                                                                                                         
sd 6:1:0:0: [sda] 142577664 512-byte logical blocks: (72.9 GB/67.9 GiB)                                                                                                                              
sd 6:1:0:0: [sda] Write Protect is off                                                                                                                                                               
sd 6:1:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA                                                                                                             
 sda: sda1 sda2                                                                                                                                                                                      
sd 6:1:0:0: [sda] Attached SCSI disk
...

hier also schonmal keine Änderung. Und wie stehts mit DD?

time dd if=/dev/zero of=/tmp/test oflag=direct bs=64k count=16000
16000+0 records in
16000+0 records out
1048576000 bytes (1.0 GB) copied, 77.8506 s, 13.5 MB/s

real    1m17.923s
user    0m0.011s
sys     0m1.056s

Genauso schlecht wie vorher. Also das gleiche Procedere nochmal. Dieses mal mit den Parametern aus dem Blog.

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] 14

Multi-pathing:  [0=Disabled, 1=Enabled, default is 1] 0
SATA Native Command Queuing:  [0=Disabled, 1=Enabled, default is 1] 0
SATA Write Caching:  [0=Disabled, 1=Enabled, default is 1] 1

Meiner Meinung nach hat Multipathing in meinem Setup keinen Einfluss auf die Geschwindigkeit. NCQ abzuschalten gefällt mir nicht ganz so, finde ich das Feature zumindest in der Theorie ganz gut – ich kann aber nicht sagen, wie es sich im RAID-Verbund verhält und ob es dort sinnvoll ist.

...
mptbase: ioc0: Initiating bringup                                                                                                                                                                    
ioc0: LSISAS1068E B3: Capabilities={Initiator}                                                                                                                                                       
scsi6 : ioc0: LSISAS1068E B3, FwRev=01185e00h, Ports=1, MaxQ=286, IRQ=19                                                                                                                             
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 4, phy 0, sas_addr 0x5000c50012d18b05                                                                                                        
scsi 6:0:0:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5                                                                                                                         
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 1, phy 1, sas_addr 0x5000c50012d2646d                                                                                                        
scsi 6:0:1:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5                                                                                                                         
mptsas: ioc0: attaching raid volume, channel 1, id 0                                                                                                                                                 
scsi 6:1:0:0: Direct-Access     LSILOGIC Logical Volume   3000 PQ: 0 ANSI: 2                                                                                                                         
sd 6:1:0:0: [sda] 142577664 512-byte logical blocks: (72.9 GB/67.9 GiB)                                                                                                                              
sd 6:1:0:0: [sda] Write Protect is off                                                                                                                                                               
sd 6:1:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA                                                                                                             
 sda: sda1 sda2                                                                                                                                                                                      
sd 6:1:0:0: [sda] Attached SCSI disk                                                                                                                                                                 
...

sieht schonmal schlecht aus und

[root@testsrv12_amd ~]# time dd if=/dev/zero of=/tmp/test oflag=direct bs=64k count=16000
16000+0 records in
16000+0 records out
1048576000 bytes (1.0 GB) copied, 78.103 s, 13.4 MB/s

real    1m18.154s
user    0m0.013s
sys     0m0.904s

bestätigt das.

Variante 1 hat also bei mir keinen Erfolg gebracht. Laut anderen Blogs hat diese Methode aber schon bei dem Ein oder Anderen funktoniert, daher lasse ich sie hier stehen, damit man das auch ausprobieren kann.

Variante 2 – Caching für die Volume Group aktivieren

Schauen wir also nun einmal nach der zweiten Variante und gucken, ob hier eine Änderung eintritt und ob diese dann auch persistent ist. Dazu starte ich wieder im LSI-Tool, gehe mit 21 in das Raid-Actions Menü und wähle dieses mal mit 32 „Change Volume Settings“. Danach aktiviere ich das Schreibcaching für das Volume:

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] 21

 1.  Show volumes
 2.  Show physical disks
 3.  Get volume state
 4.  Wait for volume resync to complete
23.  Replace physical disk
26.  Disable drive firmware update mode
27.  Enable drive firmware update mode
30.  Create volume
31.  Delete volume
32.  Change volume settings
33.  Change volume name
50.  Create hot spare
51.  Delete hot spare
99.  Reset port
 e   Enable expert mode in menus
 p   Enable paged mode
 w   Enable logging

RAID actions menu, select an option:  [1-99 or e/p/w or 0 to quit] 32

Volume 0 is Bus 0 Target 0, Type IM (Integrated Mirroring)

Volume 0 Settings:  write caching disabled, auto configure
Volume 0 draws from Hot Spare Pools:  0

Enable write caching:  [Yes or No, default is No] Yes
Offline on SMART data:  [Yes or No, default is No]
Auto configuration:  [Yes or No, default is Yes]
Priority resync:  [Yes or No, default is No]
Hot Spare Pools (bitmask of pool numbers):  [00 to FF, default is 01]

RAID ACTION returned IOCLogInfo = 00010005

RAID actions menu, select an option:  [1-99 or e/p/w or 0 to quit] 0

Main menu, select an option:  [1-99 or e/p/w or 0 to quit] 0

     Port Name         Chip Vendor/Type/Rev    MPT Rev  Firmware Rev  IOC
 1.  /proc/mpt/ioc0    LSI Logic SAS1068E B3     105      01185e00     0

Select a device:  [1-1 or 0 to quit] 0

Direkter Test im Anschluss:

time dd if=/dev/zero of=/tmp/test oflag=direct bs=64k count=16000
16000+0 records in
16000+0 records out
1048576000 bytes (1.0 GB) copied, 15.5918 s, 67.3 MB/s

real    0m15.608s
user    0m0.007s
sys     0m0.813s

Nun hatte ich das bei Variante 1 nicht direkt getestet, sondern nach einen Reboot. Ist jetzt die Frage, ob die Änderung persistent ist. Also schnell einen Reboot gemacht und siehe da, dmesg gibt

...
Fusion MPT base driver 3.04.20                                                                                                                                                                       
Copyright (c) 1999-2008 LSI Corporation                                                                                                                                                              
Fusion MPT SAS Host driver 3.04.20                                                                                                                                                                   
ACPI: PCI Interrupt Link [LNED] enabled at IRQ 19                                                                                                                                                    
mptsas 0000:05:00.0: PCI INT A -> Link[LNED] -> GSI 19 (level, low) -> IRQ 19                                                                                                                        
mptbase: ioc0: Initiating bringup                                                                                                                                                                    
ioc0: LSISAS1068E B3: Capabilities={Initiator}                                                                                                                                                       
scsi6 : ioc0: LSISAS1068E B3, FwRev=01185e00h, Ports=1, MaxQ=286, IRQ=19                                                                                                                             
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 4, phy 0, sas_addr 0x5000c50012d18b05                                                                                                        
scsi 6:0:0:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5                                                                                                                         
mptsas: ioc0: attaching ssp device: fw_channel 0, fw_id 1, phy 1, sas_addr 0x5000c50012d2646d                                                                                                        
scsi 6:0:1:0: Direct-Access     SEAGATE  ST973451SSUN72G  0302 PQ: 0 ANSI: 5                                                                                                                         
mptsas: ioc0: attaching raid volume, channel 1, id 0                                                                                                                                                 
scsi 6:1:0:0: Direct-Access     LSILOGIC Logical Volume   3000 PQ: 0 ANSI: 2                                                                                                                         
sd 6:1:0:0: [sda] 142577664 512-byte logical blocks: (72.9 GB/67.9 GiB)                                                                                                                              
sd 6:1:0:0: [sda] Write Protect is off                                                                                                                                                               
sd 6:1:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA                                                                                                              
 sda: sda1 sda2                                                                                                                                                                                      
sd 6:1:0:0: [sda] Attached SCSI disk
...

gefolgt vom Test mit:

time dd if=/dev/zero of=/tmp/test oflag=direct bs=64k count=16000
16000+0 records in
16000+0 records out
1048576000 bytes (1.0 GB) copied, 29.2247 s, 35.9 MB/s

real    0m29.268s
user    0m0.013s
sys     0m0.726s

Das sind zwar nicht ganz die 65 MB von oben, aber immernoch besser als die 13-14 Mb pro Sekunde vorher. Etwas später wiederholt scheint das Caching deutlicher zu greifen und ich erhalte wieder

time dd if=/dev/zero of=/tmp/test oflag=direct bs=64k count=16000
16000+0 records in
16000+0 records out
1048576000 bytes (1.0 GB) copied, 18.2696 s, 57.4 MB/s

real    0m18.286s
user    0m0.006s
sys     0m0.764s

Mit dem Ergebnis bin ich recht zufrieden und möchte an dieser Stelle den anderen Seiten danken, die mir geholfen haben, so schnell ans Ziel zu kommen:

  • Pawel Kudzia (.pQd -> Variante 1 – Caching im Adapter aktivieren): http://kudzia.eu/b/2009/11/slow-write-to-lsi-logic-symbios-logic-sas1068e/
  • Jan Tomášek (Variante 2 – Caching VolumeGroup): http://pocitace.tomasek.cz/SAS5iRperf/index.html
  • David Zhang (Lsi-download-link): http://www.dzhang.com/blog/2013/03/22/where-to-get-download-lsiutil

Schreibe einen Kommentar Antworten abbrechen

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

Neueste Beiträge

  • Smart 451 Schlüsselbatterie wechseln und Schlüssel wieder anlernen
  • VDR Server im LXC-Container unter Proxmox
  • Einen guten Start in 2021
  • Arch Linux in Proxmox LXC – first Steps
  • Pimp your Zbox

Kategorien

  • Allgemein
  • Android
  • Arch Linux
  • Browser
  • Chrome
  • Debian
  • Docker
  • Firefox
  • IBM (Allgemein)
  • IBM (Server)
  • KVM
  • Linux
  • LXC
  • NAS
  • Raspberry Pi
  • Redhat / CentOS
  • Server
  • Sonstiges
  • Sun
  • Thunderbird
  • Toolbox
  • Ubuntu
  • Virtualisierung
  • Windows
  • Xen

Schlagwörter

18.04 451 Acer Android Arch Linux Aspier Batterie wechseln bios bios-mod container denicid docker Dropbox DVB-C dvb-c2 DVB-S2 id4me Install Installation Kubuntu kvm lga Linux LXC mailcow microcode mSATA nextcloud pin-mod Proxmox proxmox-ve pve ReverseProxy Schlüssel Schlüssel anlernen Schlüsselbatterie Smart Smart451 SSD Thunderbird Ubuntu V3-771 V3-771G VDR vt-d
©2025 TechDudes.de | Theme: Wordly by SuperbThemes