Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Could I delete /var/lib/cloudera-service/host-monitor files?

avatar
Explorer

Hi, I want to delete the /var/lib/ cloudera-service/host-monitor files. But when I search everyone is saying its not best to delete these files. But 90% of space is used by them. I know I will loose the chart data history, that wont be a problem. If I delete them, will my production cluster can work normally like before?If not what errors will I get? We are using CDH 5.10.0 parcles. I need your insight on this issue. 

1 ACCEPTED SOLUTION

avatar
Master Guru

@kal,

 

Yup, you can stop Service Monitor and Host Monitor and then remove the contents of cloudera-host-monitor and cloudera-service-monitor directories.

When you restart Servcie and Host Monitor, new indexes will be start from scratch.

 

You will only lose the historical information.

View solution in original post

4 REPLIES 4

avatar
Master Guru

Hello @kal ,

 

First, we need to be sure about the directory to which you are referring.

You mentioned /var/lib/cloudera-service/host-monitor , but that seems unconventional.

If we are talking about the Cloudera Host Monitor Host Monitor Storage Directory, that is usually:

 

/var/lib/cloudera-host-monitor

 

If you are, indeed, referring to the directory that is defined in the Cloudera Management Service "Host Monitor Storage Directory" configuration parameter, then that is where the Host Monitor stores information collected about hosts.  Host Monitor pulls from indexes in that directory in order to provide information for Host Charts and historical data.  CDH does not depend on it so it will not impact your services.

 

If you remove the data in /var/lib/cloudera-host-monitor, then you will not have access to historical host information and your charts will start from the point the Host Monitor is restarted.

 

If you are OK with that, then you can do the following:

 

  1. Stop the Host Monitor (via Cloudera Manager)
  2. move all the contents (recursively) out of /var/lib/cloudera-host-monitor
  3. Start the Host Monitor (via Cloudera Manager)

If everything looks OK to you at that point, you could go ahead and delete the files you moved out.

 

In short, you can delete the host monitor storage files without impacting your cluster.  Host Monitor is used for charts and historical reference, but it will start from scratch if you delete all the files.

Ben

avatar
Explorer

Hello @bgooley 

 

 

I am talking about /var/lib/cloudera-service-monitor and /var/lib/clouder-host-monitor, both of these occupied almost 20GB, I want to delete the files in both of them. But not sure what will happen. Its a production cluster, so dont want impact on it by my actions.

 

cloudera-service-monitor has impala, reports, subject_record, ts and yarn folders. I want to delete the files in subject_record and ts floders, because they occupied 9GB. Is that ok to delete them? 

 

The ts folder has below files:

stream              ts_stream_rollup_PT21600S  ts_stream_rollup_PT600S     ts_stream_rollup_PT86400S  ts_type_rollup_PT3600S  ts_type_rollup_PT604800S  type

ts_entity_metadata  ts_stream_rollup_PT3600S   ts_stream_rollup_PT604800S  ts_type_rollup_PT21600S    ts_type_rollup_PT600S   ts_type_rollup_PT86400S

 

The subject_record folder has below files:

subject_ts  ts_subject

 

The cloudera-host-monitor has below floders:

subject_record  ts

Like in cloudera-service-monitor, almost same files are present in both the subject_record and ts floders.

 

Is that ok to manually delete them? if chart data is gone it is fine but we need space. Picture1.png

avatar
Explorer

Hello @bgooley 

 

I am talking about /var/lib/cloudera-host-monitor and /var/lib/cloudera-service-monitor. They occupied almost 20GB of the space and I want to delete those files. By below screenshot you will know what these folders contain.Screen Shot 2019-07-09 at 1.55.36 PM.png

I need space, if charts history is gone I am fine. Thank you.

avatar
Master Guru

@kal,

 

Yup, you can stop Service Monitor and Host Monitor and then remove the contents of cloudera-host-monitor and cloudera-service-monitor directories.

When you restart Servcie and Host Monitor, new indexes will be start from scratch.

 

You will only lose the historical information.