I need help with the regex.
I have a file which has pods status including age

NAMESPACE      NAME               READY   STATUS             RESTARTS        AGE
util           tomcat-1           0/1     Running            0               38m
util           tomcat-2           0/1     Running            0               15m
util           tomcat-3           0/1     Running            0               7m
util           tomcat-4           0/1     Running            0               4m
util           tomcat-5           0/1     Running            0               125s
util           tomcat-6           0/1     Running            0               88s

Now I need to print the pods whose Age is greater than 6 minutes.
So in my output I should see the first 3 pods

I have been using this regex but its failing for any seconds and for minutes which has 0-6 digits like 15m

cat k8s_pods.txt | awk '$NF !~ /[0-6][ms]/ { print }'

1

Khám phá các thẻ bài đăng