This post refers to an error that occurs during Tablespace creation, because the Tablespace soft links remained after the manual Elk uninstallation.
Applicable versions
C80SPC301 Elk7.1.0.SP1
Diagnostic
An error occurs during tablespace creation, because tablespace soft links remained after manual Elk uninstallation.
Cause analysis
The Elk component is manually deleted.
The HDFS directory is manually deleted by running the following command:
hadoop fs -rm -r /user/elk/tablespace/h_tbs_sdb
The local directory is manually deleted by running the following command:
rm -rf /srv/BigData/hadoop/data1/elk/elk_location_space/h_tbs_sdb
Manual deletion cannot clear the soft links of Tablespaces. As a result, Tablespaces fail to be created.
Solution
Step 1. Use the cd command to go to the CN and DN directories of the cluster.
Step 2. Run the ls -l command. The part highlighted in red in the following figure represents the remaining invalid soft links.
Step 3. Run the following command to manually delete the highlighted part:
rm -rf /srv/BigData/hadoop/data1/elk/elk_location_space/h_tbs_sdb