Clearing Atlas 500 Drive Data
Scenarios
Use the Linux command dd to clear data from a drive. When running the dd command, you need to specify parameters to overwrite data on the drive.
This operation is for reference only. You can also use other methods to clear data from the drive.
- The cleared drive data cannot be restored. Exercise caution when performing this operation.
- Do not perform other operations on the WebUI when the drive data is being cleared. If the server is powered off or the network is abnormal, you need to clear drive data again.
Procedure
- Log in to the Atlas IES.
For details, see Logging In to the Atlas IES WebUI.
- Choose Management > Drive > Local Drive Management.Figure 9-4 Local Drive Management
- Check the drive letter of the drive whose data is to be cleared, for example, /dev/hdisk0.
- Log in to the IES CLI.
- Use SSH to log in to the IES CLI.
- Enter the username and password.
- Default username: admin
- Default password: Huawei12#$
For details, see Logging In Over a Network Port by Using PuTTY.
It takes a long time to clear drive data, so you need to configure the heartbeat links between the client and the edge station.
Before running PuTTY, click Connection and configure heartbeat links, as shown in Figure 9-5. - Run the following command to set the parameter to 0 so that the connection will not time out:
timeout 0
- Switch to the developer mode.
- Run the following command to obtain the permission of the root user:
develop
Information similar to the following is displayed:
IES:/->develop input root passwd Password: Last login: Tue Jun 4 15:38:59 UTC 2019 on pts/0 Euler:~ #
- Enter the password of the root user as prompted.
Default password: Huawei@SYS3
- Run the following command to obtain the permission of the root user:
- Run the following command to set parameter to 0 so that the connection will not time out:
TMOUT=0
- Run the following command to obtain the device name of the drive:
Command: ll Drive letter
Example: ll /dev/hdisk0
If the following information is displayed, it indicates that the device name of hdisk0 is /dev/sda.
lrwxrwxrwx 1 root root 3 Jan 8 03:42 /dev/hdisk0 -> sda
- Run the following command to clear drive data:
Command: dd if=/dev/urandom of=Device name bs=4096 status=progress
Example: dd if=/dev/urandom of=/dev/sda bs=4096 status=progress
The data is cleared if the following information is displayed:
Euler:~ # dd if=/dev/urandom of=/dev/sda bs=4096 status=progress 2000359772160 bytes (2.0 TB, 1.8 TiB) copied, 22918 s, 87.3 MB/s dd: error writing '/dev/sda': No space left on device 488378647+0 records in 488378646+0 records out 2000398934016 bytes (2.0 TB, 1.8 TiB) copied, 22921 s, 87.3 MB/s Euler:~ #
- If "error writing '/dev/sda': No space left on device" is displayed, the drive has no erasable space, which is normal.
- This operation takes a long time. Please wait.
- If the command fails to execute, contact technical support.
- To ensure secure data deletion, repeat 9 for three times.
- If the device is restarted or powered off unexpectedly during or after drive data clearance, a storage partition lost alarm may be generated after the device is restarted.