Cloud In Summary
Journey To The Cloud
DATA SYSTEM
- Database System = Db + Dbms DB = ordered collection of information stored and read electronically from a computing system.
HowToSearchIn DBMS & FlatFileSystem: need to know attribute of file i.e. name, location & metadata | request sent to server to access data.
-
Difference between DBMS (Database Management System) and FlatFIleSystem
-
-
Components of DBMS: hardware, software, data, procedures, dal(data access language i.e. sql).
-
Types of DBMS:
- Hierarchical Model - tree structure, 1-1
- Network Model - graph structure, 1-1, many-many
- Relational Model - 2-dimensional tables using rows/cols, sql (structured query language)
- Object-Oriented Model - objects, oop concepts (object oriented programming)
Main difference between hierarchical databases and relational databases is that hierarchical databases store data in the form of a tree with parent and child nodes, whereas relational databases store data in tables with rows and columns as entities and attributes. A hierarchical database contains duplicate data, but relational databases do not.
Relationships: One-one,one-many | One-one,one-many,many-many.
Data retrieval: The tree must be traversed from the root node to the required node | Using SQL.
-
Fields that use DBMS: Financial, Banking, University, Sales, Telecom, Airlines, Human Resource Management, Manufacturing/ Distribution.
-
Advantages of DBMS: Controls Database Redundancy, Privacy, Data Integrity, Backup and Recovery, Sharing Data, Data Consistency, Data Security.
-
Disadvantages of DBMS: Cost of Hardware & Software(high speed processor & huge memory) and is quite high, Huge size, Higher impact of failure(stored in a centralised place), Complex to use(training).
-
Popular DBMS software: mysql, sqlite, postgresql, microsoft sql server, oracle db, ibm
NETWORKING FUNDAMENTALS
-
Networks - simply put, connected stuff. Uses: public transportation, national power grid for electricity, meet & greet people, postal systems for sending stuff, connect two/more devices.
-
Internet - giant network(public) that consists of many small networks(private) within. First iteration of the internet -> ARPANET (US Defence Dept) 1960 actual -> WWW (Tim Berners-Lee) 1989.
-
Types: Private Network, Public Network.
-
Identify devices through -
-
IP Address(street address unique in the network/area) - ID host on a network. Divided into 4 parts(octets). IP Address standards are called protocols. IPv4: 2^32(4.29b) , IPv6: 2^128 (340tr+).
-
MAC (Media Access Control) Address (i.e. serial number) - Pyhsical network interface(microchip board) found on motherboard is given a unique address(hex16, split in twos by a colon -- 1st 6digits represents company that made the interface, last 6digits is a unique number) at the factory it was built in.
-
Spoofing - networked device identifies pretentiously as another using its MAC address which can break poorly implemented security. MAC address control can be used to manage attacks.
- Ping uses ICMP (Internet Control Message Protocol) to determine the perfomance of a connection between devices, i.e. if connection is reliable or exits. Time taken for ICMP packets travelling between devices is measured using echo packet and ICMP's echo reply from target device.
ping <ipaddr/web-url>
ping -c 4 8.8.8.8
= ends after 4 packets
OPERATING SYSTEMS (OS)
-
OS - manages hardware and running programs. It loads, manage processes, provides interfaces to hardware via system calls, provides a filesystem, and provides a basic UI(user interface).
-
Series of OS: Microsoft - Windows 8, Windows Server 2012 Unix - Linux, BSD, OS X.
-
Device driver - plug-in module that manages a particular io device (input/output).
-
Pre-emptive multitasking.
cpu receives interrupt > interrupt invokes handler > handler savesrest of state of CPU for the process > handler does its business > handler invokes scheduler > scheduler selects a process to run > scheduler restores state of the CPCU for that process > scheduler jumps execution to that process
-
System calls - processes initiate requests to OS. Process uses "syscall" to invoke a system call, where the process specifies a systemcall number. The process checks the system call table for the address routine to that number and jumps execution to that address.
-
How a process uses memory: call stack(store local vars), heap(everything else), text(the code){never modified for the duration of the process}
-
Memory leak - Failure to deallocate unneeded heap memory which is obviously taking up address space. To free valuable ram, OS may swap pages of a process to a storage(hard drive) and they are not connected to ram(random access memory).
created > waiting(to be selected by the scheduler) > running > (<<blocked<) > terminated
- File system (read, write information). File partioning - space division. In unix, / is refered to as root directory.
eg, /banana = root/banana. Partitions can be nested on root dir.
- IPC (Interprocess Communication) - any mechanism(files, pipes, sockets, signals, shared memory) that facilitates communication between processes.
SERVERS
-
Server - dedicated computer that provides services on behalf of clients. A server is a role that a pc(computer) takes. A desktop can be set up as a server but cannot handle large clients/workload because it can only handle a limited amount of concurrent connections.
-
Servers can vary in types:
- Web Server - host a website.
- Db Server - stores data at backend and retrieved at frontend.
- Email server - sending and receiving email.
A server can be set up to handle various services.
-
Servers need to be reliable, made with robust hardware that runs non-stop with little to no downtime.
-
Desktop server uses a processor designed for servers - intel core series. (AMD processors support ECC RAM) A server uses a processor designed for servers.
Xeon (
- supports multi processing env.
- ECC Ram i.e. Error Correcting Code memory- detects if data was correctly processed, protect against memory error.
- supports largr amt of RAM.
- larger cache memory.
- higher core count.
- hot swappable hard drive in RAID config. RAID copies data on multiple disks and restores on new inserts.
- server should have redundant power supplies, use server OS (linux, windows, macOS) cos they are robust and stable.
)
VIRTUALIZATION
Hardware - (cpu + ram + network ) + traditional storage
Virtual Server - (virtual cpu + virtual ram + virtual network + virtual storage) and each component can be scaled to needs.
-
Virtualization - process of creating a software based / virtual version of something.
-
Hyperversor (makes virtualization feasible) - software that runs above a server/ host. They pull resources from physical server and allocate to a virtual environment and manages them.
- Type 1/ Bare metal HV - stored directly on top of a physical server (takes the place of host OS). They are secure and lowers latency. Eg. Citrix/Xen Server, VMware ESXi and Microsoft Hyper-V, Opensource KVM
- Type 2/ Hosted HV is used for end-user virtualization. Eg. Microsoft Virtual PC, Oracle Virtual Box, VMware Workstation, Oracle Solaris Zones, VMware Fusion, Oracle VM Server for x86
You can build a virtual variant/ vm once you have hypervisor installed. You can have multiples vms on an HV. These vms are independent of each other and can have different OS. They are also portable to different HVs.
- Benefits
- cost savings
- agility and speed
CLOUD COMPUTING
-
Compare On-premise to Cloud
-
-
Cloud computing - ability to deliver on demand computing services over the internet on a pay as you go basis. Files are saved and managed in cloud (overtheinternet).
-
Types
-
Deployment model:
- Public: access to anyone (eg. bus transportation). It is made available to public over the internet and owned by a cloud provider. Eg. AWS, MS Azure, IBM's Blue Cloud, Sun Cloud
dedicated to two/more orgs = multitenancy
an org. can have multiple public clouds i.e. renting spaces from different landlords.- Hybrid: pay for use only when needed (eg. rent a taxi). Eg. some agencies might use private cloud for secure information and public to share datasets with the public.
an org. can have both by apportioning their services or all services on private and backup on public.
- Private: owned by single person (eg. car owner). It is exclusively operated by a single organisation and can be managed by the organisation / 3rd party, and may exist on / off premise. Eg. AWS, VMware
-
Service Model:
- IaaS (Infrastructure as a Service) - Infastructure if business needs vm (virtual machine). Users: IT Administrators.
building on a lease land
- PaaS (Platform as a Service) - Platform if business needs a platform for building software products. Users: Software Developers.
renting equipments to build
- SaaS (Software as a Service) - Software if business doesn't need to maintain any IT equipment(accessed with username & password). Users: End-Users.
- Serverless - Provide backend services on an as-used basis.
pay for a sevice only when needed = multitenancy
What you'll manage in a service model
- Applications - IaaS, PaaS
- Data - IaaS, PaaS
- Runtime - IaaS
- Middleware - IaaS
- OS - IaaS
- Virtualization
- Servers
- Storage
- Networking
-
-
Cloud Providers
- AWS - IaaS, PaaS, SaaS. Services can be used to create, deploy any type of app in the cloud -- uses pay-for-what-you-use subscription. | Amazon
- MS Azure - building, testing, deploying and managing app through servers throughout global networks MS offers. IaaS, PaaS, SaaS, supports various programming tools | MS (Microsoft Corporation)
- IBM Cloud - IaaS, SaaS, PaaS, Deployment Models | IBM (International Business Machines Corporation)
- VMWare - platform virtualization software and services | Dell Technologies | x86arch
- GCP - soup of cloud services run on same infastructure used internally for end-user products. Eg. Youtube, GSearch. Provides computing, data storage, data analytics and machine learning services | Google (Alphabet Inc.)
- Digital Ocean - data centers worldwide, provide cloud services that helps to deploy and scale apps to run simultanuously on multiple computers. | DigitalOcean Holdings
-
Lifecycle of a cloud computing solution
Define purpose -> Define hardware -> Define Storage -> Define Network -> Define Security -> Testing the process -> Analytics