Wednesday, December 1, 2021

AWS SysOps certification story

 My AWS SysOps certification story:

10/10/21 AWS Certified Solutions Architect - Associate (SAA-C02) - cleared thru PSI
Last time I did this certification was way back in march 2017

10/12/21 AWS Certified Cloud Practitioner (CLF-C01), cleared thru PSI
Actually wanted to appear for SysOps-Associate.
Requested a voucher for PSI and then figure out the PSI doesn't offer SysOps-Associate test.
I believe that's the only test PSI doesn't offer.

10/18/21 AWS Certified SysOps Administrator - Associate (SOA-C02) - failed thru Pearson Vue
This was very interesting. I got 55 questions, I was done with all the questions and I had more 70 mins left. I was thinking may be this is the easiest exam comparatively. I took my own time to revise all the questions twice. I had about 40mins and decided to submit/close it. Once I submitted it said you have 3 labs for 20mins each and you cannot go back to the lab once submitted. I was not prepared for these labs and had not idea that this test had labs.
I somehow started with the lab, couldn't able to follow all the steps in the first lab. I had only 20mins left for the next two labs
Luckily the 2nd and 3rd labs were easy enough and still had 9 mins left but couldn't go back to the first to fix it.

So, there goes my first failed attempt and now I have wait for 2 weeks before I can attempt this test again. Apparently this is the only test that has labs as of now

Exam labs make up 20% of your total score. A passing score is 720 out of 1,000.

Another thing about this test, or rather not good and frustrating about this test is - it doesn't tell you if you passed or failed right away. It takes couple of days, as per the official statement, it may take upto 5 business days. Most likely because of labs, someone has to review the labs steps and sanctity.

11/18/21 AWS Certified SysOps Administrator - Associate (SOA-C02) - no show thru Pearson Vue
I had to reschedule my test multiple times due to conflict with other meetings and things to do.
It was a 8am test, I login to start the test and find out there is nothing for me to start. I panicked, started calling the Pearson support number (866-207-9983)
They told me, this test was scheduled for 11/12/21 and I didn't show up :-)
I however reschedule my 11/12/21 test to 11/18/21 but it didn't go thru or not sure if I never clicked submit to finalize.
Luckily I had captured the snapshot of the last page of exam time. 
I created a ticket with Pearson Vue Case: 07312581, and after few email exchange they cancelled that exam and sent me the refund and restored my voucher.
Please always make sure you have the confirmation email of the exam and also login once before the exam and check the schedule is updated.


11/19/21 AWS Certified SysOps Administrator - Associate (SOA-C02) - failed/void thru Pearson Vue
This test went well, unless I reached lab2.
In Lab2 I couldn't able to edit values in the template, was not able to select the words properly to edit.
Couldn't able type numbers in the notepad and many other issues.
Created a support case with AWS CASE 9232500091, they asked me to create a case with Pearson Vue.
Created a case with Pearson Case ID: 07321951

The response from Pearson after few days of review.
"First and foremost, we want to sincerely apologize for any inconvenience you may have faced during your exam.
A case has been submitted on your behalf to AWS, and you can expect to receive an update from AWS shortly.
Our team would like to fix this by offering you a customer service voucher code that can be used to schedule
your next exam at no additional charge to you. "

Once they make the exam void and 2 weeks wait period doesn't apply.


11/30/21
- AWS Certified SysOps Administrator - Associate (SOA-C02) - cleared thru Pearson Vue
Finally I was able re-schedule my 12/3/21 to 11/30/21 to finish it

Bottomline, it creates a huge bump in planning ahead if you fail the test or do not pay enough attention to scheduling or test pattern details. And other thing is this can be a very difficult exam if you are NOT hands-on. The labs are not very difficult but it has its own performance and layout challenges when you are working thru the restricted browser.  And finally I would recommend tutorialsdojo.com for labs

Hope you will not make these mistakes I made

Tuesday, April 27, 2021

ansible error with python boto3

 Ansible Error:

TASK [provision-ai-vpc : Create VPC] ************************************* task path: /Users/pankajgautam/infra/ansible/roles/provision-ai-vpc/tasks/main.yml:14 redirecting (type: modules) ansible.builtin.ec2_vpc_net to amazon.aws.ec2_vpc_net fatal: [localhost]: FAILED! => {"changed": false, "msg": "Failed to import the required Python library (botocore or boto3) on Veevas-MacBook-Pro.local's Python /System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python. Please read the module documentation and install it in the appropriate location. If the required library is installed, but Ansible is using the wrong Python interpreter, please consult the documentation on ansible_python_interpreter"} PLAY RECAP ********************************************************************* localhost : ok=1 changed=0 unreachable=0 failed=1 skipped=3 rescued=0 ignored=0 


It seems like Mac comes with python2.7 and cannot be touched/removed

pankajgautam@Veevas-MBP ~ % /usr/bin/python --version

Python 2.7.16


If you install awscli it comes with its own python

pankajgautam@Veevas-MBP ~ % /usr/local/aws-cli/aws --version

aws-cli/2.1.37 Python/3.8.8 Darwin/20.4.0 exe/x86_64 prompt/off


You can install python with pip or pip3 that generally installs under /Library

pankajgautam@Veevas-MBP ~ % ls  /Library/Python/ 

2.7 3.8


Then you can also install python using brew that gets installed under /usr/local/Cellar

pankajgautam@Veevas-MBP ~ % ls -l /usr/local/Cellar/ | grep python

drwxr-xr-x  3 pankajgautam  admin  96 Apr 21 12:58 python@3.9




You can specify which python to be used with ansible using ansible_python_interpreter

and also make sure you have boto3 module imported in that python version

 

AWS_PROFILE=aiprod ansible-playbook -e "aws_region=us-east-1 release_type=gr ansible_python_interpreter=/usr/local/Cellar/python@3.9/3.9.4/bin/python3" -i ansible/inventory/prod ansible/provision-ai-vpc-pb.yml -vv 2>&1 | tee provision.log 


pankajgautam@Veevas-MBP % sudo pip3 install boto3 

WARNING: The directory '/Users/pankajgautam/Library/Caches/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag. Collecting boto3 Downloading boto3-1.17.54-py2.py3-none-any.whl (131 kB) |████████████████████████████████| 131 kB 640 kB/s 

Requirement already satisfied: jmespath<1.0.0,>=0.7.1 in /usr/local/lib/python3.9/site-packages (from boto3) (0.10.0) 

Collecting botocore<1.21.0,>=1.20.54 

Downloading botocore-1.20.55-py2.py3-none-any.whl (7.4 MB) |████████████████████████████████| 7.4 MB 545 kB/s Collecting s3transfer<0.5.0,>=0.4.0 Downloading s3transfer-0.4.1-py2.py3-none-any.whl (79 kB) |████████████████████████████████| 79 kB 16.1 MB/s Collecting urllib3<1.27,>=1.25.4 Downloading urllib3-1.26.4-py2.py3-none-any.whl (153 kB) |████████████████████████████████| 153 kB 18.2 MB/s Collecting python-dateutil<3.0.0,>=2.1 Downloading python_dateutil-2.8.1-py2.py3-none-any.whl (227 kB) |████████████████████████████████| 227 kB 16.1 MB/s Collecting six>=1.5 

Downloading six-1.15.0-py2.py3-none-any.whl (10 kB) Installing collected packages: six, urllib3, python-dateutil, botocore, s3transfer, boto3 Successfully installed boto3-1.17.54 botocore-1.20.55 python-dateutil-2.8.1 s3transfer-0.4.1 six-1.15.0 urllib3-1.26.4 


pankajgautam@Veevas-MBP infra % /usr/local/Cellar/python@3.9/3.9.4/bin/python3

Python 3.9.4 (default, Apr 5 2021, 01:49:30) [Clang 12.0.0 (clang-1200.0.32.29)] on darwin Type "help", "copyright", "credits" or "license" for more information. 

>>> import boto3 >>>