Patent ID: 8078908

Claim:
A data storage apparatus, comprising: a cache memory configured to store data including user data and control information of the apparatus; a nonvolatile memory; a power supply configured to supply an instant power after an occurrence of a power failure; and a processor configured to execute a process including: when the power failure occurs, saving the user data and the control information stored in the cache memory into the nonvolatile memory by using the instant power; when the power failure recovers, restoring the data stored in the nonvolatile memory into the cache memory, updating the control information stored in the cache memory, and erasing the data stored in the nonvolatile memory after restoring the data into the cache memory; and when another power failure occurs during erasing the data stored in the nonvolatile memory after recovering the power failure, stopping the erasing, erasing all of the control information stored in the nonvolatile memory by using the instant power if the control information is remained in the nonvolatile memory and saving, into the nonvolatile memory, all of the control information stored in the cache memory and the user data which has been erased from the nonvolatile memory.