Below is the config i use for checking if router flash memory has certain amount of free space and then copy IOS image to it if it has.
Now i need to do the same thing for stacked switch. But iam wondering if below config will be sufficient for checking free space in EVERY member switch flash of a stacked switch or will it only check master switch flash free space? (as i haven't had an opportunity to test on prod yet) Or do you suggest some other way to check free space of every member switch flash memory and then copy ios image to every member switch only if sufficient space exists? - name: Gather IOS Facts ios_facts: - debug: msg: - "Free space is {{ ansible_net_memfree_mb }}" - name: DISPLAY IF SUFFICIENT SPACE IS THERE OR NOT assert: that: - ansible_net_memfree_mb >= 513 fail_msg: "THERE IS not SUFFICIENT SPACE TO COPY IMAGE. FREE UP SPACE FIRST" success_msg: "THERE IS SUFFICIENT SPACE TO COPY IMAGE" -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/807b2bf7-01d1-4346-bb9f-116c1f6daceen%40googlegroups.com.