How Do You Configure an External Monitor’s Placement with a Macbook Pro?

Problem scenario
You have a Mac laptop. You have connected a separate monitor. To get your mouse one the screen, you have to move the direction of the mouse in a different direction relative to the physical location of where you see this external monitor. You have to commit to memory where to move the mouse. You want the external monitor to be mouse-reachable in the direction that it is in front of you.

How Do You Create a Callable Function in Java outside of the “main” Section?

Problem scenario
You have a public static void main (String[] args) portion of your Java program. You want to have a subroutine such as a function outside of this section. How do you code this?

Solution
In Java methods are components of an object that perform an action on the object themselves. We therefore use the term “method” here and not “function”. Here is an example of a method inside a class that runs from the public static void main(String[] args) section of code:

public class ContClass {
static void contMethod() {
System.out.println(“I just got executed!”); …

How Do You Troubleshoot the Error “Could not find suitable distribution for Requirement.parse(‘botocore==2.0.0dev11’)”?

Problem scenario
You try to install the AWS CLI version 2.x

You run this command:

$ sudo python3 setup.py install

You get a message like this:

Processing dependencies for awscli==2.0.7
Searching for botocore==2.0.0dev11
Reading https://pypi.org/simple/botocore/
No local packages or working download links found for botocore==2.0.0dev11
error: Could not find suitable distribution for Requirement.parse(‘botocore==2.0.0dev11’)

What should you do?

How Do You Install Django on a CentOS/RHEL/Fedora server?

Problem scenario
You want to install Django and have it working for browsing from a desktop workstation. You do not want to leverage Django’s API functionality. How do you install and configure Django from scratch?

Prerequisite
pip3 is probably installed. If you are not sure, you could run this: sudo find / -name pip3

You must have pip or pip3 installed.

How Do You Troubleshoot “error occurred (AccessDeniedException) when calling the CreateCluster operation: User: … is not authorized to perform: iam:PassRole on resource:…”?

Problem scenario
You run this command:

aws eks create-cluster –name contint –role-arn arn:aws:iam::12345678910:role/contintrole –resources-vpc-config subnetIds=subnet-a123456,subnet-b77777777,securityGroupIds=sg-2e324234254

You get this error:

An error occurred (AccessDeniedException) when calling the CreateCluster operation: User: arn:aws:iam::12345678910:user/contintuser is not authorized to perform: iam:PassRole on resource: arn:aws:iam::12345678910:role/contintrole

What should you do?

Solution
1. Log into the AWS Console.
2. Go to IAM -Users
3.

How Do You Troubleshoot the AWS CLI Message “An error occurred (AccessDeniedException) when calling the ListClusters operation”?

Problem scenario
You run this command aws eks list-clusters, but you get this message:

“An error occurred (AccessDeniedException) when calling the ListClusters operation: User: arn:aws:iam::12345678910:user/jdoe is not authorized to perform: eks:ListClusters on resource: arn:aws:eks:us-west-1:12345678910:cluster/*”

What should you do?

Solution
1. Go to the AWS Console and log in.
2. Go to IAM -> Users
3. Click on the user’s account.

How Do You Troubleshoot the EKS Error “AccessDeniedException…Clusters operation: Account …is not authorized to use this service”?

Problem scenario
In one region, but not another, you get this error with an “aws eks list-clusters” command:

“An error occurred (AccessDeniedException) when calling the ListClusters operation: Account 12345678910 is not authorized to use this service”

You know that IAM does not require region selection. What is causing this eks error?

Solution
Is your AWS CLI configured to use a region that eks does not support?