Disk I/O Error beim bereinigen der fhem.db

Begonnen von franky08, 26 April 2016, 17:30:43

Vorheriges Thema - Nächstes Thema

Wernieman

Könnte am Kernel <4 liegen ... der sata Treiber der "E3800 Series SATA AHCI" ist erst in der Neueren Zeit gut ...

Habe mein System schon ziemlich "generft", abgesehen von sqllite, und noch niemals so etwas gesehen ... habe allerdings auch keine Samsung sondern Crucial
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

franky08

Bleibt die Frage wie ich an einen aktuellen Kernel komme ohne auf Jessie zu gehen, dass hatte ich gestern mal auf einem zweiten System eingerichtet aber da gibt es zu viele Dinge die nicht wie erwartet funktionieren und die sqlite version ist auch neuer und ich bekomme meinen dump nicht importiert, damit wären alle Verbrauchsdaten von Gas und Strom weg.

P.S. 5min Stress macht er auch  ;)
root@zotac:~# sudo stress -d 4 -t 300
stress: info: [8049] dispatching hogs: 0 cpu, 0 io, 0 vm, 4 hdd
stress: info: [8049] successful run completed in 300s


VG
Frank
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

Wernieman

Kannst es auch auf "mehr" ausbauen:
stress --cpu 4 --io 4 --vm 2 --vm-bytes 128M --timeout 10s
stress: info: [6554] dispatching hogs: 4 cpu, 4 io, 2 vm, 0 hdd
stress: info: [6554] successful run completed in 11s


Sorry, aber dann bin ich mit meinem Wissen "am Ende" ..

P.S. Unabhängig davon, was macht der Smart-test?
Denn 3 Fehler hast Du auf der SSD ....
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

franky08

Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

Wernieman

sudo smartctl -a /dev/sda
Funktionierte doch? (s.o.)
Was bekommst Du denn als Fehler bei
sudo smartctl -t offline /dev/sda
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

franky08

Ah, jetzt:
=== START OF OFFLINE IMMEDIATE AND SELF-TEST SECTION ===
Sending command: "Execute SMART off-line routine immediately in off-line mode".
Drive command "Execute SMART off-line routine immediately in off-line mode" successful.
Testing has begun.


VG
frank
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

franky08

Hab es noch mal mit Option -a gestartet:
frank1@zotac:~$ sudo smartctl -a /dev/sda
smartctl 5.41 2011-06-09 r3365 [x86_64-linux-3.16.0-0.bpo.4-amd64] (local build)
Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Device Model:     SanDisk SDSSDXPS240G
Serial Number:    142572400594
LU WWN Device Id: 5 001b44 c3d8f2bd2
Firmware Version: X21000RL
User Capacity:    240.057.409.536 bytes [240 GB]
Sector Size:      512 bytes logical/physical
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   8
ATA Standard is:  ACS-2 revision 3
Local Time is:    Thu Apr 28 15:28:15 2016 CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x02) Offline data collection activity
was completed without error.
Auto Offline Data Collection: Disabled.
Self-test execution status:      (   0) The previous self-test routine completed
without error or no self-test has ever
been run.
Total time to complete Offline
data collection: (    0) seconds.
Offline data collection
capabilities: (0x11) SMART execute Offline immediate.
No Auto Offline data collection support.
Suspend Offline collection upon new
command.
No Offline surface scan supported.
Self-test supported.
No Conveyance Self-test supported.
No Selective Self-test supported.
SMART capabilities:            (0x0003) Saves SMART data before entering
power-saving mode.
Supports SMART auto save timer.
Error logging capability:        (0x01) Error logging supported.
General Purpose Logging supported.
Short self-test routine
recommended polling time: (   2) minutes.
Extended self-test routine
recommended polling time: (  10) minutes.

SMART Attributes Data Structure revision number: 4
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  5 Reallocated_Sector_Ct   0x0032   100   100   ---    Old_age   Always       -       83
  9 Power_On_Hours          0x0032   253   100   ---    Old_age   Always       -       1380
12 Power_Cycle_Count       0x0032   100   100   ---    Old_age   Always       -       62
166 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       1
167 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       53
168 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       70
169 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       831
171 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       32
172 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       0
173 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       12
174 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       37
184 End-to-End_Error        0x0032   100   100   ---    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   ---    Old_age   Always       -       3
188 Command_Timeout         0x0032   100   100   ---    Old_age   Always       -       0
194 Temperature_Celsius     0x0022   058   049   ---    Old_age   Always       -       42 (Min/Max 25/49)
199 UDMA_CRC_Error_Count    0x0032   100   100   ---    Old_age   Always       -       0
212 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       0
230 Head_Amplitude          0x0032   100   100   ---    Old_age   Always       -       40
232 Available_Reservd_Space 0x0033   100   100   004    Pre-fail  Always       -       99
233 Media_Wearout_Indicator 0x0032   100   100   ---    Old_age   Always       -       3321
241 Total_LBAs_Written      0x0030   253   253   ---    Old_age   Offline      -       172
242 Total_LBAs_Read         0x0030   253   253   ---    Old_age   Offline      -       18
244 Unknown_Attribute       0x0032   000   100   ---    Old_age   Always       -       0

SMART Error Log Version: 1
ATA Error Count: 3
CR = Command Register [HEX]
FR = Features Register [HEX]
SC = Sector Count Register [HEX]
SN = Sector Number Register [HEX]
CL = Cylinder Low Register [HEX]
CH = Cylinder High Register [HEX]
DH = Device/Head Register [HEX]
DC = Device Command Register [HEX]
ER = Error register [HEX]
ST = Status register [HEX]
Powered_Up_Time is measured from power on, and printed as
DDd+hh:mm:SS.sss where DD=days, hh=hours, mm=minutes,
SS=sec, and sss=millisec. It "wraps" after 49.710 days.

Error 3 occurred at disk power-on lifetime: 1375 hours (57 days + 7 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  51 40 02 00 00 00 a0 

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  ef 10 02 00 00 00 a0 08      00:00:00.000  SET FEATURES [Reserved for Serial ATA]
  ef 10 02 00 00 00 a0 08      00:00:00.000  SET FEATURES [Reserved for Serial ATA]
  ec 00 00 00 00 00 a0 08      00:00:00.000  IDENTIFY DEVICE
  ef 03 46 00 00 00 a0 08      00:00:00.000  SET FEATURES [Set transfer mode]
  ef 10 02 00 00 00 a0 08      00:00:00.000  SET FEATURES [Reserved for Serial ATA]

Error 2 occurred at disk power-on lifetime: 1375 hours (57 days + 7 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  51 40 00 00 00 00 a0

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  ec 00 00 00 00 00 a0 08      00:00:00.000  IDENTIFY DEVICE
  ef 03 46 00 00 00 a0 08      00:00:00.000  SET FEATURES [Set transfer mode]

Error 1 occurred at disk power-on lifetime: 1375 hours (57 days + 7 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  51 40 00 00 00 00 00 

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  60 10 28 20 f7 0b 40 08      00:00:00.000  READ FPDMA QUEUED

SMART Self-test log structure revision number 1
No self-tests have been logged.  [To run self-tests, use: smartctl -t]


Device does not support Selective Self Tests/Logging
frank1@zotac:~$
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

stromer-12

Es könnte am trim liegen. Ich rufe bei mir per cron ein mal am Tag fstrim auf um den freien Speicher der SSD mitzuteilen.
Ich hatte auch mal das Problem.
FHEM (SVN) auf RPi1B mit HMser | ESPLink
FHEM (SVN) virtuell mit HMLAN | HMUSB | CUL

franky08

Hallo stromer-12 wie ist der Konsolenbefehl für trim? Ich kan iMo nicht mit dem Rechner auf fhem und den Host zugreifen, habe gerade die Platten ausgebaut um eine sector to sector Kopie auf eine mechanische hdd zu machen.

VG
Frank
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

stromer-12

Die option -v gibt dir zurück wieviel Speicher freigegeben wurde.
/opt ist mein Mountpoint für meine SSD.

/sbin/fstrim -v /opt
FHEM (SVN) auf RPi1B mit HMser | ESPLink
FHEM (SVN) virtuell mit HMLAN | HMUSB | CUL

franky08

#40
Habe es gerade mal laufen lassen:
frank1@zotac:~$ sudo nano /etc/fstab
frank1@zotac:~$ sudo nano /etc/cron.daily/trim
frank1@zotac:~$ sudo fstrim -v /
/: 208842264576 bytes were trimmed
frank1@zotac:~$


Und noch mal auf /opt
frank1@zotac:~$ sudo fstrim -v /opt
/opt: 373022720 bytes were trimmed
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

Wernieman

Hatte DIr tri9m auch schon oben gesagt, würde einfach:
fstrim -av

a: Alle Partitionen
v: verbose: Sag was Du machst
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

franky08

#42
Ja, kann ich noch mal laufen lassen. In der fstab hab ich zusätzlich noch die Option discard eingefügt, hatte ich mir mal für ssds aufgeschrieben.

Option -a nimmt er nicht:
fstrim: Ungültige Option -- a

Usage:
fstrim [options] <mount point>

Options:
-h, --help          this help
-o, --offset <num>  offset in bytes to discard from
-l, --length <num>  length of bytes to discard from the offset
-m, --minimum <num> minimum extent length to discard
-v, --verbose       print number of discarded bytes

For more information see fstrim(8).


VG
Frank
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...

Wernieman

Nimm es mal raus .. ich weiß nicht bei welcher Kernel-Version, aber es gab damit mal Probleme (unabhängig von Deinen jetzigen).

Laut kernelLog werden (momentan) immer noch das wöchentliche aufruf von fstrim per cron empfohlen. Alternativ kann es auch häufiger, aber das "discard" wird (momentan) nicht empfohlen.
- Bitte um Input für Output
- When there is a Shell, there is a Way
- Wann war Dein letztes Backup?

Wie man Fragen stellt: https://tty1.net/smart-questions_de.html

franky08

So, nach ewigen probieren z.B.einen Klone der SSD mit clonezilla auf eine mechanische hdd komme ich nicht weiter. Die SSD hat mittlerweile Fehler und ich würde gerne beim Start oder beim runterfahren forcefsck ausführen. Das Problem ist das sich das System nicht mehr sauber runterfahren lässt.
Kann man z.B. in der init.d beim Start fsck ausführen lassen?

VG
Frank
Debian Wheezy auf ZBOX nano/ Debian Bullseye auf 2.ter ZBOX nano F2F an 2x RaspiB
22Zoll ViewSonic als Infodislay (WVC)
3xHMLAN mit vccu ,fhem5.8, CCU2,
ECMD an AVR-NET-IO mit DAC u. ADC an Junkers Stetigregelung, Siemens LOGO!8, JeeLink uvm...