Page 2 of 2

Re: Massive data corruption after SW reboot

Posted: Mon Sep 14, 2015 11:32 am
by craggy
Hi

Yes we have been told that since and are planning to disable the WB cache once we can safely flush the current cache data to disk and stop the service without corruption occurring.

Re: Massive data corruption after SW reboot

Posted: Mon Sep 14, 2015 11:35 am
by anton (staff)
R&D should give you API entry calls and PowerShell script sample on how to do that.
craggy wrote:Hi

Yes we have been told that since and are planning to disable the WB cache once we can safely flush the current cache data to disk and stop the service without corruption occurring.

Re: Massive data corruption after SW reboot

Posted: Mon Sep 14, 2015 11:35 am
by anton (staff)
R&D should give you API entry calls and PowerShell script sample on how to do that.
craggy wrote:Hi

Yes we have been told that since and are planning to disable the WB cache once we can safely flush the current cache data to disk and stop the service without corruption occurring.

Re: Massive data corruption after SW reboot

Posted: Mon Sep 14, 2015 12:19 pm
by Vladislav (Staff)
We have finished the script.

In order to manually flush cache of your StarWind device, you should do the following:

- Download FlushCache.ps1 file attached.
- Open file with Wordpad / Notepad ++.
- Change $deviceName="imagefile1" value to correspond the name of your StarWind device.
- Save file.
- Disconnect all clients from StarWind device. The best way to perform this is to disconnect all targets in ISCSI Initiator.
- Open starwindX Powershell.
- Run FlushCache.ps1

If the script was successfully executed you will receive "Start flushing... Completed!" output in Powershell console. At this moment, the flushing process has begun.

The total capacity of your WB cache is L1 8GB + L2 60GB = 68GB which means your underlying physical storage will now perform the 68GB write operation.
If you are aware of your physical storage performance, you can calculate the approximate tame it takes to perform such operation.
For example with the transfer rate of 100 MB/sec it will take approximately 11 minutes to write 68GB of data.
Therefore, we recommend you to wait at least 15-20 minutes until flushing is finished.

After that, you can change your L2 cache mode to wright-through and restart StarWind service.

Please, contact us directly by e-mail: support@starwind.com in case if you face any difficulties.

Re: Massive data corruption after SW reboot

Posted: Tue Sep 15, 2015 11:12 am
by craggy
Cheers guys, going to test this on our lab environment before we schedule any production downtime.

Re: Massive data corruption after SW reboot

Posted: Wed Sep 16, 2015 8:57 am
by darklight
Wow, interesting script :) Will definitely take a look :)

Re: Massive data corruption after SW reboot

Posted: Mon Sep 21, 2015 2:06 pm
by craggy
Hi

We've tried to run this script in a test environment and keep getting the following error:

Start flushing...Exception The variable '$raw' cannot be retrieved because it has not been set.

Any ideas?

Re: Massive data corruption after SW reboot

Posted: Mon Sep 21, 2015 3:11 pm
by craggy
Update:

So I created a new test flat disk with L2 WB cache and ran the powershell script. It finished successfully.
However, when I try run the script on any of the existing image files I get the error above.

Re: Massive data corruption after SW reboot

Posted: Wed Sep 23, 2015 9:27 am
by Vladislav (Staff)
Community update:

We have requested more information from craggy regarding existing device settings.

Re: Massive data corruption after SW reboot

Posted: Tue Sep 29, 2015 12:11 pm
by Vladislav (Staff)
Quick community update:

Script fails to run on the particular craggy's device. We are now investigating why.

Re: Massive data corruption after SW reboot

Posted: Wed Oct 21, 2015 4:47 pm
by schraepf
Any update on this issue? Interested to learn about @craggy's system specs.

Re: Massive data corruption after SW reboot

Posted: Thu Oct 22, 2015 5:15 pm
by Vladislav (Staff)
Hello.

Just a quick update.

We have changed the initial FlushCache script and it was successfully executed in our test environment.

However, we have faced an issue on Craggy's setup, when performance monitor shows near zero activity during script execution as well as during regular file level read-write operations.

We are going to arrange a remote session to check Craggy's configuration once again and possibly locate the issue.