Before this video Ansible was scary for me, now after watching this I can say I feel at home, Thanks ROger! Subscribed.
@RogerPerkin2 жыл бұрын
Excellent, plenty more to come - any topics you would like covered?
@MrEDGE19842 жыл бұрын
@@RogerPerkin Few more ansible videos would really help along!
@RogerPerkin2 жыл бұрын
@@MrEDGE1984 Sure, pretty wide topic area though - any vendors or tasks you are working on?
@uche89614 жыл бұрын
Great video. Very practical. Just what I need as a beginner in ansible. You really won me over. Please do more of these practical stuffs.
@RogerPerkin4 жыл бұрын
More to come!
@RohitPatil-qx9tf2 жыл бұрын
Hi Roger, I want to skip the upgrade if the current version and upgrade image are same.. But looks like it skip the debug message but start running other tasks.. ? Any inputs?
@MahmoudTaha922 жыл бұрын
Thank you for sharing this useful demo, it is awesome!
@martinbuffleo3 жыл бұрын
Great playbook. Worth adding and MD5 verify task, before reloading the router?
@bantacad2 жыл бұрын
Awesome video! In my opinion you can use command " write memory", which no require "Yes" for answer and for the network switch you can use console connection instead SSH. Cheers.
@kenmurphy42594 жыл бұрын
Great video Roger and like the Ansible cap! :)
@afara20003 жыл бұрын
For reloading a Cisco IOS device, you'll need to hit "enter" or return key i.e., " " instead of 'y' in Ansible script. Although, 'y' may work but it's good to use proper commands.
@edsonrocks4 жыл бұрын
Thank you Roger, it's been a really useful demo. For a firmware upgrade routine like that I'd suggest checking the new firmware file md5 checksum before reloading the device just to prevent it turning into a brick that fails to reboot due to a corrupted file. Thank you for the video series, very cool, keep it up.
@RogerPerkin4 жыл бұрын
Edson, this was just me getting to grips with the basics of the operation. I am aware there are more checks that can be done like check space in flash before pushing and MD5 checksum checks. Glad you enjoyed it.
@edsonrocks4 жыл бұрын
@@RogerPerkin I'm learning a lot with your videos. Thank you very much.
@Aldrin034 жыл бұрын
excellent work - i'm starting to study ansible to automate daily tasks! appreciate your videos!
@RogerPerkin4 жыл бұрын
Great to hear! - I have more tutorials on my website www.rogerperkin.co.uk/network-automation/ansible/
@garyauer80703 жыл бұрын
Absolutely excellent thanks
@RogerPerkin3 жыл бұрын
Great, glad it helped!
@RohitPatil-qx9tf2 жыл бұрын
Thanks for the video.. A very good script.. Please upload new videos for upgrade of the fortigate and palo alto devices
@RogerPerkin2 жыл бұрын
Ok thanks for the idea, I will look into that
@umakantjena51544 жыл бұрын
thanks Roger for this video. why I am getting this error . fatal: [R1]: FAILED! => {"changed": false, "msg": "path specified in src not found"} I tried ~ or / , file path correct but it just cant get it.
@veerabsc2 ай бұрын
Fantastic work
@sameerthorappa33564 жыл бұрын
Excellent video...we appreciate your time 👍👍👍.
@RogerPerkin4 жыл бұрын
Thank you! Cheers!
@DarkSideDiving4 жыл бұрын
Very cool !!!
@adonf3 жыл бұрын
Hello, was the advertised "next video" where you automate all this stuff ever released ? Or is it part of the pay course ? Anyway, thanks for this very informative video.
@SadhamHussainsree3 жыл бұрын
Great video.Thank you for sharing your knowledge.
@chrisdotbrown14 жыл бұрын
Great video - more network ansible please, especially the impact of ansible changes on routing tables
@RogerPerkin4 жыл бұрын
Hi Chris, can you expand on that requirement a bit more? Ansible changes on routing tables are basically somebody making changes. Are you looking to compare routing tables before and after a specific change?
@chrisdotbrown14 жыл бұрын
@@RogerPerkin the scenario would be if you wanted to change a route would you use the config module or command. Just trying to understand how smart the config module is.
@RogerPerkin4 жыл бұрын
I don’t think the Ansible config module is smart - it literally just performs the same command you would type on the CLI Are you looking for more of a predictive / changing routes based on certain network conditions?
@chrisdotbrown14 жыл бұрын
@@RogerPerkin Not really just trying to get me head around good operational practice and maintenance and which modules are best for what. I am thinking, facts and command to perform incremental change and test success and then config to ensure it hasn't been changed. I get that config can also best use for initial setup. I think one of my observations with Ansible is that there is a lot of content on how to do change but less on best practice. Great video - make really clear some key technics.
@RogerPerkin4 жыл бұрын
@@chrisdotbrown1 Think of Ansible as a tool to make changes and config push / pulls in a predictive easy way. It's a great tool but if you want to get it to do clever stuff, you need to put clever config into it. Maybe you should look at Python and PYATS for something that will monitor your network for change and config drift. There is not one right tool for anything and there are so many ways of doing everything.
@gouravrelhan73725 ай бұрын
Thank for this video. Much appreciated Roger !! :)
@peterly73814 жыл бұрын
Awesome and very intuitive video instruction. However, this is a router by router. If we we 10 routers at once, what's the best method? 10 separate session currently? or how would you do it in parallel? Thanks.
@RogerPerkin4 жыл бұрын
Hi Peter, this playbook was just to explain the basic process. If you have 10 devices to upgrade it's up to you how you want to tackle it. If you added all your devices into the hosts file they would all upgrade at once, you may want to just do 10 at a time or if you wanted to do 1 at at time just wind the forks value back in ansible.cfg. The next device would not start until the previous play had finished. For production devices this playbook is really to take all the manual steps out of the process and some customers prefer to take things slowly over a day others are happy to fire all at once.
@hygri4 жыл бұрын
Sweet tutorial Roger, much appreciated. Just a thought; could you sneak in a check to see if there is actually flash space available for the upgrade? I've been hit by that many a time :)
@RogerPerkin4 жыл бұрын
Great suggestion! I can add that in a later video - Make sure you subscribe to be alerted when it goes live
@hygri4 жыл бұрын
@@RogerPerkin Nice! Most definitely - I have, as they say , "got the bell on" :)
@RogerPerkin4 жыл бұрын
@Mr.b I have not deleted any videos, this is the only one I have on Jinja Templates - kzbin.info/www/bejne/pmGmamOwfseYa9U - all my other Ansible videos are in this playlist - kzbin.info/www/bejne/nn3LeY2Vqs-oaLM
@deepak70574 жыл бұрын
cisco WS-C4948 not upgrade so plz help me
@jonathantx8 ай бұрын
Is it possible to gather facts based on a wildcard? for example only on a given switch model?
@mihaigrigore21364 жыл бұрын
Excellent video, Roger! Thank you for sharing.
@RogerPerkin4 жыл бұрын
Thanks, glad it helped.
@JoshepGomez1234 жыл бұрын
Ansible can be used to upgrade other Cisco OS (IOS-XR, IOS-XE, NXOS)? or is limited to IOS
@RogerPerkin4 жыл бұрын
Yes, you can use it to upgrade other Cisco OS, it's just IOS is easiest. If you understand the manual process to upgrade NXOS then using Ansible is just taking the steps and translating them.
@AJ-jm6zp3 жыл бұрын
awesome and very helpful :) subscribed for your great work. could you please share that ansible script please
@RogerPerkin3 жыл бұрын
Sure, you can find it here - github.com/rogerperkin/network-programmability/blob/master/SCRIPTS/Ansible/ios-upgrade.yml
@packetsbulliespb34412 жыл бұрын
Does Ansible copy the image to all members if we have a stack switch, or how does Ansible manage this?
@suelee93464 жыл бұрын
Thanks for the Video! Roger. Positives: This is good for Network Engineers who enjoys breathing through one nostril due to Corona Virus. This is good for someone who does not want to write Python codes. Not so positive: Using Ansible is like running on only 4 cylinders on a V8 car. Python might byte you back later. Why not use both nostrils (Python) or fire up all 8 cylinders (Python)?
@RogerPerkin4 жыл бұрын
I agree, Ansible is not the fastest way to do things but for IOS upgrades I have found it to be very reliable - which is more important for me!
@neogeoh14 жыл бұрын
Sir... I Mount a python program to do this. I need this code to try it out. I will check your website otherwise please let me know where I can get it. I am new to Ansible and this will serve me as a great experiment. Thank you for sharing.
@RogerPerkin4 жыл бұрын
Hi, I am working on this and will be putting a new video out soon performing the task using Python
@koye2909043 жыл бұрын
Great video Roger! How long would you say the entire upgrade process took from running the yml file in ansible to the completion of the upgrade? I intend to run this in a prod environment on over 30 network devices.
@dhanasekar-uj2ch4 жыл бұрын
Excellent video, one query can we pass the enable password and hoow to do that
@afara20003 жыл бұрын
You need to have "become: yes" and "become_method: enable" variables set in playbook or "ansible_become=yes" and "ansible_become_method=enable" in 'hosts' file and set "ansible_become_password=xyz" in your 'hosts' or inventory file. You can also use "-K" in CLI when you run playbook, it'll prompt you to manually enter enable password.
@ankukumar-hi2jt11 ай бұрын
Thanks @Roger Perkin for your video so lets suppose i have 100 devices to upgrade and i did them at once so how ansible knows which all devices are coming up and then do post validation as few devices can take more time then other
@RogerPerkin10 ай бұрын
You would put a delay on the playbook before you run the validation, you would just have to put a sensible figure in i.e wait 10 minutes?
@rochdiferjani677810 ай бұрын
dear Roger could you please make a training video about aruba switch ! 🥰
@sbahb13964 жыл бұрын
Awesome video! Thank you Roger. A small question, do you covert this kind of upgrade for wireless controller and ASA in your course on your website? If yes I am really interested. I am currently working on upgrading our infrastructure devices (switches, WLC, ASA) it would be nice if you could share how to perform this kind of tasks with Ansible. Please let me know. Thank you again for the great video!
@RogerPerkin4 жыл бұрын
Hi sbah B, thank you for the comment. My course really covers from zero knowledge to running some basic playbooks. Once you get up and running there are so many use cases it would be impossible to cover them all. The process is the same you just need to tweak the playbook for your specific hardware. It all depends on how many deivces you have. For me the switch playbook was really worth writing as you can easily upgrade 100's or 1000's of switches with ease. For ASA or WLC it just depends how many you have and how often you want to upgrade them
@jclm1rt4 жыл бұрын
Very good video! Is it possible to do the same upgrade simultaneously on multiple switches?
@dhanasekar-uj2ch4 жыл бұрын
Yes it is possible
@RogerPerkin4 жыл бұрын
Yes, this is the power of Ansible, you can limit the number of connections with forks in the ansible.cfg file I normally have it at 5 connections at a time, however it can be more. It's just up to you how many you want to have going at the same time. For switch upgrades I would normally have them going at a manageable number so you can monitor them. Some customers want all at once, others prefer one at a time.
@feargalledwidge8064 жыл бұрын
Great video - but every time I try to replicate it - I get a failure in the net_put module. I get "An exception occurred during task execution. To see the full traceback, use -vvv. The error was: UnboundLocalError: local variable 'changed' referenced before assignment fatal: [TEST]: FAILED! => {"msg": "Unexpected failure during module execution.", "stdout": ""}. Ansible version is 2.9.19.
@aydinkocak32704 жыл бұрын
Hi I receive same error with centos but same playbook run without any error on ubuntu 20.04 LTS.
@jhonvinod89884 жыл бұрын
Please upload iOS upgrade using python. Thank you
@RogerPerkin4 жыл бұрын
Sure, that was going to be my next video, performing the same operation using Python! Hit subscribe and you will be notified as soon as it goes live!
@marcosdxdydz10 ай бұрын
lousy explanation
@ershadramezani67162 жыл бұрын
Does anyone know why I'm getting this error with scp ?: fatal: [sw1-access]: FAILED! => {"changed": false, "destination": "flash:/test.txt", "msg": "Exception received: Error transferring file to flash:/test.txt: Initializing SCP session of remote file [flash:/test.txt] for write failed with error [b'Socket error: No such file or directory']"} Thanks in advance