Please can you elaborate more about the meaning of inotifywait.
Google is your friend.
And how pgbackrest will solve the issue ?
PgBackRest does all the WAL archiving for you, keeps track of them, makes sure they are not overwritten, purges old ones when not needed etc. Even compresses and encrypts them if you want.
Please could you help me by sharing any redhat linux command through which I can count the no. of wal files and no. of ".ready" files generated in last 10 minutes.