Usage: memory_used_percent [prefix] where prefix is Metrics prefix.
Your GCP custom monitoring metric name should look like e.g. if prefix is set to tester
then your metric name will be custom.googleapis.com/opencensus/tester/sys_mem_used_percent.
Default is "custom" so your metric name will be visible as
custom.googleapis.com/opencensus/custom/sys_mem_used_percent in stackdriver monitoring Console.
Run "sys_mem_used_percent -h" command for how to run this application.
You can run this application through systemd unit as well. No cronjob required.
This is application should run inside GCP Virtual Machines for accurate Results.
The Same metrics can be used to autoscale MIG(stateless) using autoscaler custom monitoring metrics option
which will autoscale GCP VMs on the basis of memory used percent.