CHAPTER CLOUD: diving into AWS & Linux

AWS, or Amazon Web Services, very popular these days for providing.. anything, really, created by comrade (?) Bezos and every1 is very excited. Can’t make a step without seeing it in every job description. It’s the latest thing (alright, maybe not any more). But still, let’s nit miss out and jump aboard.

STEP 1 – go to aws.amazon.com. On the top right look for “Create an AWS account”. See it? Press it. In the next window specify “root user email address” and “AWS account name”. Click on “verify email address”/ you don’t need a business email here, thank you Jeff.

STEP 2 – A) Check your inbox and type in the code.
B) Tell a little bit about yourself. Maybe not in so many words. The main thing is at the top specify PERSONAL, at least for now.
C) Then your momma’s CC info.
D) Of course, they would like to “confirm your identity” this is done. Type in a number with a country code.
NOTE: number provided from MySudo app works, but specify to call for verification. I’ve waited for the text longer than should have. You’ll be needing to enter the PIN appeared on the screen with a keypad on the phone.
E) Select “Basic Support”, since we’re just cool about it and clik on “complete sign up” and have a shot.

STEP 3 INSTALLING EC2 Linux Instance
1) click on “go to the management console”. It’s not a console, really, it’s where people play. We’ll play too.
2) On the screen you should see in “Recently visited” (??) section EC2, S3, RD5 and Lambda. We’re interested in EC2.
3) EC stands for Elastic Computing, meaning exactly what Cloud Computing is about – if you need, you can expand. Scalability. Click on “Launch Instance” on the right.
4) Specify name, e.g. “Taco Tocs” and we’re going to go with Amazon’s Linux 2023 AMI
5) For the “Instance type ” we’ll put t2.micro, if you click on to comapre the plans you’ll all the other encilata they offer, but we don’t need much. 1 vCPU, 32 and 64 bit architectures support and 1 GB of RAM is good enough.
6) Kreating Key pair – they’ll be used to securely connect to the instance. The two ways are through PuTTY and OpenSSH. WE ARE GOING TO USE BOTH, but not at once. Create one of each, remember the names and download the files. Select “.pem”
7) Network Settings unchanged, in fact, hide the darn thing, it’s tempting.
8) Configure Storage – 8 GB is good.
9) Click on “Launch instance” and have a shot, but after you see “SUCCESS. Successfully initiated launch of instance” message ina green bar.

STEP 4 – WE’RE ROLLING (THEY HATING..)
1) To actually get into the CLI of your new virtual machine you hav to clikc on “Connect to Instance”. That’s in the second section under “Next Steps”
2) Connect using EC2 Instance Connect – selected. NOTE the public IP (leave as IPv4)
3) Changing the username might not be a good idea. Trying that leads to a red banner page saying “Failed to connect: Unable to connect to the instance because the instance is not in a valid state.. bla-bla.” This is nonsense, and we don’t want that, chaning the username to something else could be a premium feature.
Leave it as “ec2-user”
4) Click on “Connect”. What you need to be seeing is:

   ,     #_
   ~\_  ####_        Amazon Linux 2023
  ~~  \_#####\
  ~~     \###|
  ~~       \#/ ___   https://aws.amazon.com/linux/amazon-linux-2023
   ~~       V~' '->
    ~~~         /
      ~~._.   _/
         _/ _/
       _/m/'
Last login: Tue Feb 25 01:09:43 2025 from 3.16.146.3
[ec2-user@ip-172-31-10-96 ~]$ 

Is this a Jailbird??.. NOTE: It’s not unusual to encounter a message (when clicking on “CloudShell” on the bottom left, saying “Unable to create the environment. Your account verification is in progress. This may take up to two days for new accounts.. contact support, yada-yada”. No biggie. We’llbe back.

CONGRATS!! Now you’re the owner (maybe for a short while) of your own personal Linux machine in the cloud. Again, don’t downplay it or sell yourself short. This is just the beginning of a beautiful.. DevOps career (if you want), or anything else for that matter.

STEP 5 (Optional) – It might be a good idea just to see what it is what’s inside. Check if there is a connection to the world too.. MOST important is to determine the flavour of it – run: cat /etc/os-release

   ,     #_
   ~\_  ####_        Amazon Linux 2023
  ~~  \_#####\
  ~~     \###|
  ~~       \#/ ___   https://aws.amazon.com/linux/amazon-linux-2023
   ~~       V~' '->
    ~~~         /
      ~~._.   _/
         _/ _/
       _/m/'
Last login: Tue Feb 25 01:15:46 2025 from 3.16.146.5
[ec2-user@ip-172-31-10-96 ~]$ uname --all
Linux ip-172-31-10-96.us-east-2.compute.internal 6.1.128-136.201.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Feb 10 16:18:01 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
[ec2-user@ip-172-31-10-96 ~]$ lscpu
Architecture:             x86_64
  CPU op-mode(s):         32-bit, 64-bit
  Address sizes:          46 bits physical, 48 bits virtual
  Byte Order:             Little Endian
CPU(s):                   1
  On-line CPU(s) list:    0
Vendor ID:                GenuineIntel
  Model name:             Intel(R) Xeon(R) CPU E5-2686 v4 @ 2.30GHz
    CPU family:           6
    Model:                79
    Thread(s) per core:   1
    Core(s) per socket:   1
    Socket(s):            1
    Stepping:             1
    BogoMIPS:             4599.99
    Flags:                fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx rdtscp lm co
                          nstant_tsc rep_good nopl xtopology cpuid tsc_known_freq pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt 
                          tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm invpcid_single pti fsgsbase bmi1 avx2 smep bmi2 erms inv
                          pcid xsaveopt
Virtualization features:  
  Hypervisor vendor:      Xen
  Virtualization type:    full
Caches (sum of all):      
  L1d:                    32 KiB (1 instance)
  L1i:                    32 KiB (1 instance)
  L2:                     256 KiB (1 instance)
  L3:                     45 MiB (1 instance)
NUMA:                     
  NUMA node(s):           1
  NUMA node0 CPU(s):      0
Vulnerabilities:          
  Gather data sampling:   Not affected
  Itlb multihit:          KVM: Mitigation: VMX unsupported
  L1tf:                   Mitigation; PTE Inversion
  Mds:                    Vulnerable: Clear CPU buffers attempted, no microcode; SMT Host state unknown
  Meltdown:               Mitigation; PTI
  Mmio stale data:        Vulnerable: Clear CPU buffers attempted, no microcode; SMT Host state unknown
  Reg file data sampling: Not affected
  Retbleed:               Not affected
  Spec rstack overflow:   Not affected
  Spec store bypass:      Vulnerable
  Spectre v1:             Mitigation; usercopy/swapgs barriers and __user pointer sanitization
  Spectre v2:             Mitigation; Retpolines; STIBP disabled; RSB filling; PBRSB-eIBRS Not affected; BHI Retpoline
  Srbds:                  Not affected
  Tsx async abort:        Not affected
[ec2-user@ip-172-31-10-96 ~]$ ping www.msn.ca
PING a-0003.a-msedge.net (204.79.197.203) 56(84) bytes of data.
64 bytes from a-0003.a-msedge.net (204.79.197.203): icmp_seq=1 ttl=119 time=8.72 ms
64 bytes from a-0003.a-msedge.net (204.79.197.203): icmp_seq=2 ttl=119 time=9.29 ms
64 bytes from a-0003.a-msedge.net (204.79.197.203): icmp_seq=3 ttl=119 time=9.14 ms
64 bytes from a-0003.a-msedge.net (204.79.197.203): icmp_seq=4 ttl=119 time=9.68 ms
64 bytes from a-0003.a-msedge.net (204.79.197.203): icmp_seq=5 ttl=119 time=8.82 ms
^C
--- a-0003.a-msedge.net ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4007ms
rtt min/avg/max/mdev = 8.715/9.129/9.676/0.343 ms

[ec2-user@ip-172-31-10-96 ~]$ cat /etc/os-release
NAME="Amazon Linux"
VERSION="2023"
ID="amzn"
ID_LIKE="fedora"
VERSION_ID="2023"
PLATFORM_ID="platform:al2023"
PRETTY_NAME="Amazon Linux 2023.6.20250218"
ANSI_COLOR="0;33"
CPE_NAME="cpe:2.3:o:amazon:amazon_linux:2023"
HOME_URL="https://aws.amazon.com/linux/amazon-linux-2023/"
DOCUMENTATION_URL="https://docs.aws.amazon.com/linux/"
SUPPORT_URL="https://aws.amazon.com/premiumsupport/"
BUG_REPORT_URL="https://github.com/amazonlinux/amazon-linux-2023"
VENDOR_NAME="AWS"
VENDOR_URL="https://aws.amazon.com/"
SUPPORT_END="2029-06-30"
[ec2-user@ip-172-31-10-96 ~]$ 

SKILLS TO SHOW OFF:
AWS; creating virtual instance, CLOUD, Linux

COMMANDS KNOWN:
uname –all, lscpu, ping [website], cat /etc/os-release




Comment