Q1. Service Agreements (SAs)
The agreement has two parts:
Service Agreement
Service Level Agreement (SLA)
A Service Level Agreement (SLA) is the service contract component between a
service provider and customer. A SLA provides specific and measurable aspects related
to service offerings. For example, SLAs are often included in signed agreements between
Internet service providers (ISP) and customers.
The followingpromisesare made toconsumerbythe provides:
Availability:
Usually99.5% to 100% availabilityisassured.
The assurance is fora time intervalsof abillingcycle e.g.,15minute,1hour,1 Year etc. forwhichthe
service statuswill be “up”forsure.
But thishas to be clarifiedthatforexample time periodof assurance is15 minutesandevenif the
service is“down”for14 minutes,thenitlegallymeansthatthe service wasnot“down”forthe whole
interval.
Typically,several failuresinsubsystemsare requiredtocompletely“down”aservice forthe whole
periodof billing.
The providermayadjustthe availabilitypromisesoncase to case basis.
RemediesforFailure to Perform:
In case of violationof the promise of availability (duringatime period) bythe provider,the customer
will be compensatedintermsof service creditfor future use of Cloudservice.
A refundisusuallynotgiven.
Consumerisresponsible tomonitorthe availabilityof service andclaimforcompensation.
RemediesforFailure to Data Preservation:
The followingsituationsresultinterminationof CloudITresourcesusage foraconsumer:
Voluntarilybyconsumer
The providersusuallytake noresponsibilityforpreservingthe datainlatercase.While informercase,
the preservationisdone forfewdays.
Terminatedbythe providerforviolatingthe provider’srule of service and/orfornon-payment.
Legal Care ofConsumer Information:
The providerassuresfornot disclosing/viewing/using/sharingthe consumer’sdataexceptincase of
legal requirement.
On the otherhand the providerretainsthe rightof monitoringthe consumerdataas well asmay
demanda copyof consumer’ssoftware formonitoringassistance.
Q2. Draw CloudHosting Data center Design and Explain
Keyterms:
CRAC:ComputerRoomAirConditioning
Hot aisle
Coldaisle
Servercabinets(Racks)
Hollow floor
Perforatedtiles
Cloudhostingdatacenterhas a layeredarchitecture forthe Internetaccess.
The serversare physicallyconnectedtolayer2 switches.There isatopof rack (TOR) in eachrack. One
serverisconnectedtoonlyone TOR switch.
The TORs are connectedtoaggregate switches(AGS).
Data centersconsume huge amountsof electricity.Asmuchas a small towninUSA.
A large data centercan host hundredsof thousandsphysical servers.
Internet
Rack Rack Rack
TOR TOR TOR
AGS AGS
AR AR
BR BR
It ismore costlytosetupand run a small data centerintermsof unitcosts(perserver,perMB of
storage,perGHz, Networkbandwidth)andoperational costsascomparedtolargerdata centers.
The networkdesignmustsupportthe followingfeatures:
Must satisfybothpoint-to-pointandcollectivecommunicationpatternsamongall servernodes.
ApplicationTrafficSupport:The datacenterinterconnectionnetworkmustsupportthe MPI
communication andhighbandwidth.
Example:Distributedfile access,MapandReduce functionsetc.
Some serverscanbe configuredtobe masterandothersbe slaves.
NetworkExpandability:The interconnectionnetworkmustbe expandable.
Shouldsupportloadbalancinganddata movement.
No bottlenecks
Can be expandedinthe unitof datacentercontainerwhichcontainshundredsof serversandisa
buildingblockof large datacenters.
FaultTolerance andGraceful Degradation:Canbe implementedthrough:
Replicationinsoftware andhardware resources
Redundantlinksamonganytwoservers
No single pointof failure orcritical links
FaultTolerance andGraceful Degradation:Canbe implementedthrough:
Two layereddesignshouldbe used(anetworklayerclose toserversandthe upperlayerorbackbone) to
supportmodular(container) basedexpandabledesign.
Q3. Zero Downtime Architecture
The failure of the physical serverresultsinthe unavailabilityofVMshostedonthatserver.
The servicesdeployedoverthe unavailable VMsare obviouslydisrupted.
The Zero downtime architectureimplementsafailoversystemthroughwhichthe VMs(fromthe failed
physical server) are dynamicallyshiftedtoanotherphysical serverwithoutanyinterruption.
The VMs are requiredtobe storedon a sharedstorage.
The additional modulesrequiredmayinclude:
Cloudusage monitor
Logical networkperimeter
Resource clustergroup(containingactive-active clusterstoassure highavailabilityof IT-resourcesfor
VM) Resource replication
Q4. Fundamental CloudArchitectures
Resource PoolingArchitecture:
It isbaseduponusingone or more resource pool inwhichidenticalITresourcesare groupedand
maintainedautomaticallybyasystemwhichalsoensuresthatthe resource poolsremainsynchronized.
Physical serverpoolsconsistingof (readytouse) networkedserverswithinstalledOSandothertools.
CPU poolsare readyto be allocatedtoVMs bythe multipleof single core.
Dedicatedpoolscanbe createdfor eachtype of IT resources.
Individual resource poolscanbecome sub-groupsintolargerpool.
A resource pool canbe dividedintosiblingpoolsaswell asnestedpools.
Siblingpoolsare independentandisolatedfromeachother.Mayhave differenttypesof ITresources.
Resource poolscreatedfordifferentconsumersare isolatedfromeachother.
Resource PoolingArchitecture:
CloudUsage Monitor
Hypervisor
Logical NetworkPerimeter
Pay-Per-Use Monitor
Remote AdministrationSystem
Resource ManagementSystem
Resource Replication
Dynamic Scalability Architecture
Dynamicscalabilityisprovidedthrough dynamicallocationof availableresourcesfromthe resource
pool.
Scalingcan be horizontal &vertical andcan alsobe throughdynamicrelocation.
To implementthisarchitecture,the automatedscalinglistener(ASL) andResource Replication
Mechanismare utilized.
Cloudusage monitorandpay-per-use monitorcancomplementthisarchitecture formonitoringand
billingpurposes.
WorkloadDistribution Architecture
The workloaddistributionisrequiredtopreventthe followingscenarios:
The workloaddistributionisrequiredtopreventthe followingscenarios:
Over-utilizationof ITresourcestopreventthe lossinperformance.
Under-utilizationof ITresourcestopreventthe overexpenditure.
The workloadisdistributedonthe basisof a loadbalancingalgorithmwiththe scope/sof VMs,Cloud
storage devicesandcloudservices.
Auditmonitor
Cloudusage monitor
Logical networkperimeter
Resource cluster
Resource replication
Service Load Balancing Architecture
Thisarchitecture specificallyisusedforworkloaddistributionforCloudservices.
Multiple instancesof the Cloudservicesare deployedwithloadbalancingsystem.
Alternativelythe loadbalancercanbe integratedintothe Cloudservice
The load balancercan be eitherdeployedasanexternal module.
The followingmodules are additionally required:
Cloudusage monitor
Resource cluster(withactive-active failoversystemconfiguration)
Resource replication
Elastic Disk ProvisioningArchitecture
Cloudcostingmodel fordiskstorage maycharge onthe basisof total volume of allocatedstorage space
insteadof total space used.
The elasticdiskprovisioningarchitecture implementsadynamicstorage provisioningbasedbilling.
The user ischargedonlyfor the consumed storage.
The technique of thin-provisioningof storage isused.
Thin-provisioningallocatesthe storage space dynamicallyforthe VM’sstorage.
Requiressome extraoverheadwhenmore storage space istobe allocated.
The thin-provisioningsoftware isrequiredtobe installedonVMsto coordinate the thin-provisioning
processwiththe hypervisor.
Redundant Storage Architecture
In orderto avoiddata lossandservice unavailabilitydue todiskfailure,redundantstorage isapplied.
Additionally,incase of networkfailure,the disruptionsinCloudservicescanbe avoidedthrough
redundantstorage incident.
Thisis part of failoversystem(active-passive).
The primaryand secondarystorage are synchronizedsothatincase of a disaster,the secondary storage
can be activated.
A storage device gateway(partof failoversystem) divertsthe Cloudconsumers’requeststosecondary
storage device wheneverthe primarystorage device fails.
The primaryand secondarystorage locationsmaybe geographicallyapart(fordisasterrecovery) witha
(possiblyleased) networkconnectionamongthe twosites
Q5. CloudSecurity Threats
VirtualizationAttack
Baseduponthe administrative privilegesprovidedtothe Cloudconsumersandmulti-tenancy,itis
possible tocompromise the underlyingphysical hardware.
It isalso possible thatthe securityflawsbe arisingdue to VMsprawl(alack of securitypatchesonOS
installedonVM).Anotherpossibilityisthe installationof VM-aware malware toexploitthe security
flawsof hypervisor.
OverlappingTrust Boundaries
Movingof consumerdatato Cloudmeansthat the providernow shares(withthe consumer) the
responsibilitiesof availability,confidentialityandintegrityof data.
OverlappingTrust Boundaries
The consumerthusextendsthe trustboundarytoinclude the cloudprovider.Thisisprone to
vulnerabilities.
Whenmultiple consumersof acloudshare an IT resource,the trustboundariesoverlap.
The providermaynot be able to providerthe securityfeaturesthatcan satisfythe securityrequirement
of all the consumersof sharedIT resource ona Cloud.
More complex scenariosarise whenthe consumerdataisreplicatedandstoredonmultiple sites.
FlawedImplementation
The implementationof Cloud servicesmayhave some flawsrelatedtoconfigurationresultingintothe
occurringof unexpectedevents.
Particularlythe securityandoperationalweaknessesinCloudprovider’ssoftware/hardware canbe
targetedbythe attackers to putthe integrity,confidentialityand/oravailabilityof ITresourcesof the
provideratstake.
Disparity of ComputerSecurity Policy
A computersecuritypolicydefinesthe setof rulesandmechanismstoensure the securityof the
computersof the organization.The computersecuritypoliciesof the consumerandprovidermaynot
match.
The lack of administrative privilegesprovidedtothe consumermakesthe implementationof the
consumerchosencomputersecuritypolicyverydifficult.
Contracts
As an additional consideration,the SLA offeredbythe providershouldbe carefullyexaminedtoclarify
the liabilitiestakenbythe providerandthe securitypolicyimplementedbythe provider.Thishelpsin
determiningthe following:
If the consumercan applyitsownsecuritypolicieswhile the cloudproviderkeepsthe administrative
rightsto the IT infrastructure.Thenhowthisdisparitywillbe overcome.
Risk Management:
The cloud consumersshouldperformacyclicprocessof riskmanagementtoaccessthe potential threats
and challengesrelatedtoCloudadoption.Thisshouldbe apart of riskmanagementstrategy.Itisa
three stage process.
Identifythe vulnerabilitiesof the (tobe adopted) Cloudenvironment.
Identify,quantifyandqualifythe risksrelatedtohow the consumerisplanningtouse the cloud.
Create the securitypolicy/iestoavoidand/orlowerthe impactof the risksidentifiedinthe previous
step.
Reviewthe risksoccurredduringareview periodandhow effectivewere the policies(made inprevious
step).Identifyanypolicyupdatesrequired.
Q6. Desktopvirtualization
Desktopvirtualization,oftencalledclientvirtualization,isavirtualizationtechnologyusedtoseparate a
computerdesktopenvironmentfromthe physical computer.Desktopvirtualizationisconsideredatype
of client-servercomputingmodel becausethe "virtualized"desktopisstoredonacentralized,or
remote,serverandnotthe physical machine beingvirtualized.
Desktopvirtualization"virtualizes desktopcomputers"andthese virtualdesktopenvironmentsare
"served"touserson the network.Youinteractwitha virtual desktopinthe same wayyouwoulduse a
physical desktop.Anotherbenefitof desktopvirtualizationisthatisletsyouremotelylog intoaccess
your desktopfromanylocation.
ServerVirtualization
Servervirtualizationisavirtualizationtechniquethatinvolvespartitioningaphysical serverintoa
numberof small,virtual serverswiththe helpof virtualizationsoftware.In servervirtualization,each
virtual serverrunsmultipleoperatingsysteminstancesatthe same time.
The concept of servervirtualizationiswidelyappliedinITinfrastructure asa wayof minimizingcostsby
increasingthe utilizationof existingresources.Virtualizingserversisoftenagoodsolutionforsmall- to
medium-scale applications.Thistechnologyiswidelyusedforprovidingcost-effective webhosting
services.
Q7. CloudArchitectural DesignChallenges
Service availabilityand Data Lock-in Problem
Dependinguponasingle providerforservice deploymentresultsinasingle pointof failure orlock-in.
Requiresthe interoperability/standardizationof APIcallsondifferentPaaSplatforms.
Data Privacy and SecurityConcerns:
Due to publicaccessof Clouds,multitenancyandsophisticatedattacks/malware,the implementation
and assurance of privacyand securityof consumers’dataisa bigchallenge.
Unpredictable Performance andBottlenecks:
The unpredictabilityof processinganddataloadover Cloudservicesintroduce I/Obottleneckssuchas
concurrentread/write accessrequirementstosharedstorage forlarge data volumesbymultiple VMs.
The providershave tocarefullyanalyze the deploymentdecisionsaccordingtosurge incomputing/data
loadsand shouldtune the bottlenecks.
DistributedStorage and WidespreadSoftware Bugs:
Ensuringdata consistency,durabilityandhighavailabilityisachallenge whenthe dataisdistributed.
Debuggingof datato remove inconsistenciesanderrorsis importantbutchallenging.
CloudScalability,Interoperabilityand Standardization
Scalabilityisone of the basicfeaturesof Cloudcomputingandthusrequires(forexample) dynamic
availabilityof ITresources(hardware) forscalingup.
The heterogeneityinhardware and/orhypervisormakesitchallengingtodynamicallyinclude more
hardware/virtualizedITresources.
The openvirtualizationformat(OVF) describesandopen,secure,efficient,portableandextensible
formatfor packagingand distributionof VMsandthe software tobe deployedoverVMs.
Software Licensingand ReputationSharing:
The fact that the license model of commercial software isnotsuitableforutilitycomputing,the
providershave torelyuponopensource software and/orbulkusage license.
If the reputationof aproviderisaffected(due toconsumers’maliciousbehavior),thenthere isno
service tosafe-guardthe provider’sreputation.
Q8. VirtualizationSupport and Disaster Recovery
The IT resourcesanddata are prone to disasters (natural and/orhumanmade) whichdamage them
partiallyorfullyandthusmay crash the whole computingsystemof anorganization.
Failover:Itisprocessthroughwhicha systemtransferscontrol (usuallyautomatedly)toanalternate
deploymentuponfailureof primarydeployment.
Failback:The processof restoringof the systemfromalternative toprimarydeploymentandrestoration
of original state.
The use of virtualizationcanimplementthe failoverandbringsreductioninfailbacktime.
As comparedto (forexample) adatadisasterfordata storedon magnetictapes,daysare require for
restoration/recovery.
The redundantdeploymentof software solutions,dataandIT resourcesisquite easybyusing
virtualization.
One deploymentisconsideredasprimary,whileotherdeployment/sare keptasbackup.
The primarydeploymentisthenrestoredfromthe mostrecentsnapshot.
Virtualizationhasbecome the core partof disasterrecoveryplansof majororganizationssince last
decade.
Virtualizationevenallowsthe testingof disasterrecoveryplanthroughemulationandwithout
disturbingthe production/primarydeployment.
Q9. StudentMarks:
print("Enter'x'forexit.");
print("Entermarksobtainedin5subjects:");
mark1 = input();
if mark1 == 'x':
exit();
else:
mark1 = int(mark1);
mark2 = int(input());
mark3 = int(input());
mark4 = int(input());
mark5 = int(input());
sum = mark1 + mark2 + mark3 + mark4 + mark5;
average = sum/5;
if(average>=91andaverage<=100):
print("YourGrade isA+");
elif(average>=81andaverage<=90):
print("YourGrade isA");
elif(average>=71andaverage<=80):
print("YourGrade isB+");
elif(average>=61andaverage<=70):
print("YourGrade isB");
elif(average>=51andaverage<=60):
print("YourGrade isC+");
elif(average>=41andaverage<=50):
print("YourGrade isC");
elif(average>=0andaverage<=40):
print("YourGrade isF");
else:
print("Strange Grade..!!");
Q10. Octagonal Area
importmath
# Utilityfunction
def areaOctagon(side):
return(2 * (1 + (math.sqrt(2))) *side *side)
# Driverfunction
side = 4
print("Areaof RegularOctagon=",
round(areaOctagon(side),4))
Q11. FACTORIAL
num= 7
# uncommentto take inputfromthe user
#num = int(input("Enteranumber:"))
factorial = 1
# checkif the numberisnegative,positive orzero
if num < 0:
print("Sorry,factorial doesnotexistfornegative numbers")
elif num== 0:
print("The factorial of 0is 1")
else:
for i in range(1,num+1):
factorial = factorial*i
print("The factorial of",num,"is",factorial)
Q12. Bubble Sort
def bubbleSort(arr):
n = len(arr)
# Traverse throughall array elements
for i in range(n):
# Last i elementsare alreadyinplace
for j in range(0,n-i-1):
# traverse the array from0 to n-i-1
# Swapif the elementfoundisgreater
# thanthe nextelement
if arr[j] > arr[j+1] :
arr[j],arr[j+1] = arr[j+1], arr[j]
# Drivercode to testabove
arr = [64, 34, 25, 12, 22, 11, 90]
bubbleSort(arr)
print("Sortedarray is:")
for i in range(len(arr)):
print("%d"%arr[i]),

Cloud quiz question answer

  • 1.
    Q1. Service Agreements(SAs) The agreement has two parts: Service Agreement Service Level Agreement (SLA) A Service Level Agreement (SLA) is the service contract component between a service provider and customer. A SLA provides specific and measurable aspects related to service offerings. For example, SLAs are often included in signed agreements between Internet service providers (ISP) and customers. The followingpromisesare made toconsumerbythe provides: Availability: Usually99.5% to 100% availabilityisassured. The assurance is fora time intervalsof abillingcycle e.g.,15minute,1hour,1 Year etc. forwhichthe service statuswill be “up”forsure. But thishas to be clarifiedthatforexample time periodof assurance is15 minutesandevenif the service is“down”for14 minutes,thenitlegallymeansthatthe service wasnot“down”forthe whole interval. Typically,several failuresinsubsystemsare requiredtocompletely“down”aservice forthe whole periodof billing. The providermayadjustthe availabilitypromisesoncase to case basis. RemediesforFailure to Perform: In case of violationof the promise of availability (duringatime period) bythe provider,the customer will be compensatedintermsof service creditfor future use of Cloudservice. A refundisusuallynotgiven. Consumerisresponsible tomonitorthe availabilityof service andclaimforcompensation. RemediesforFailure to Data Preservation: The followingsituationsresultinterminationof CloudITresourcesusage foraconsumer: Voluntarilybyconsumer The providersusuallytake noresponsibilityforpreservingthe datainlatercase.While informercase, the preservationisdone forfewdays. Terminatedbythe providerforviolatingthe provider’srule of service and/orfornon-payment. Legal Care ofConsumer Information:
  • 2.
    The providerassuresfornot disclosing/viewing/using/sharingtheconsumer’sdataexceptincase of legal requirement. On the otherhand the providerretainsthe rightof monitoringthe consumerdataas well asmay demanda copyof consumer’ssoftware formonitoringassistance. Q2. Draw CloudHosting Data center Design and Explain Keyterms: CRAC:ComputerRoomAirConditioning Hot aisle Coldaisle Servercabinets(Racks) Hollow floor Perforatedtiles Cloudhostingdatacenterhas a layeredarchitecture forthe Internetaccess. The serversare physicallyconnectedtolayer2 switches.There isatopof rack (TOR) in eachrack. One serverisconnectedtoonlyone TOR switch. The TORs are connectedtoaggregate switches(AGS). Data centersconsume huge amountsof electricity.Asmuchas a small towninUSA. A large data centercan host hundredsof thousandsphysical servers. Internet Rack Rack Rack TOR TOR TOR AGS AGS AR AR BR BR
  • 3.
    It ismore costlytosetupandrun a small data centerintermsof unitcosts(perserver,perMB of storage,perGHz, Networkbandwidth)andoperational costsascomparedtolargerdata centers. The networkdesignmustsupportthe followingfeatures: Must satisfybothpoint-to-pointandcollectivecommunicationpatternsamongall servernodes. ApplicationTrafficSupport:The datacenterinterconnectionnetworkmustsupportthe MPI communication andhighbandwidth. Example:Distributedfile access,MapandReduce functionsetc. Some serverscanbe configuredtobe masterandothersbe slaves. NetworkExpandability:The interconnectionnetworkmustbe expandable. Shouldsupportloadbalancinganddata movement. No bottlenecks Can be expandedinthe unitof datacentercontainerwhichcontainshundredsof serversandisa buildingblockof large datacenters. FaultTolerance andGraceful Degradation:Canbe implementedthrough: Replicationinsoftware andhardware resources Redundantlinksamonganytwoservers No single pointof failure orcritical links FaultTolerance andGraceful Degradation:Canbe implementedthrough: Two layereddesignshouldbe used(anetworklayerclose toserversandthe upperlayerorbackbone) to supportmodular(container) basedexpandabledesign. Q3. Zero Downtime Architecture The failure of the physical serverresultsinthe unavailabilityofVMshostedonthatserver. The servicesdeployedoverthe unavailable VMsare obviouslydisrupted. The Zero downtime architectureimplementsafailoversystemthroughwhichthe VMs(fromthe failed physical server) are dynamicallyshiftedtoanotherphysical serverwithoutanyinterruption. The VMs are requiredtobe storedon a sharedstorage. The additional modulesrequiredmayinclude: Cloudusage monitor Logical networkperimeter Resource clustergroup(containingactive-active clusterstoassure highavailabilityof IT-resourcesfor VM) Resource replication
  • 4.
    Q4. Fundamental CloudArchitectures ResourcePoolingArchitecture: It isbaseduponusingone or more resource pool inwhichidenticalITresourcesare groupedand maintainedautomaticallybyasystemwhichalsoensuresthatthe resource poolsremainsynchronized. Physical serverpoolsconsistingof (readytouse) networkedserverswithinstalledOSandothertools. CPU poolsare readyto be allocatedtoVMs bythe multipleof single core. Dedicatedpoolscanbe createdfor eachtype of IT resources. Individual resource poolscanbecome sub-groupsintolargerpool. A resource pool canbe dividedintosiblingpoolsaswell asnestedpools. Siblingpoolsare independentandisolatedfromeachother.Mayhave differenttypesof ITresources. Resource poolscreatedfordifferentconsumersare isolatedfromeachother. Resource PoolingArchitecture: CloudUsage Monitor Hypervisor Logical NetworkPerimeter Pay-Per-Use Monitor Remote AdministrationSystem Resource ManagementSystem Resource Replication Dynamic Scalability Architecture Dynamicscalabilityisprovidedthrough dynamicallocationof availableresourcesfromthe resource pool. Scalingcan be horizontal &vertical andcan alsobe throughdynamicrelocation. To implementthisarchitecture,the automatedscalinglistener(ASL) andResource Replication Mechanismare utilized. Cloudusage monitorandpay-per-use monitorcancomplementthisarchitecture formonitoringand billingpurposes. WorkloadDistribution Architecture The workloaddistributionisrequiredtopreventthe followingscenarios:
  • 5.
    The workloaddistributionisrequiredtopreventthe followingscenarios: Over-utilizationofITresourcestopreventthe lossinperformance. Under-utilizationof ITresourcestopreventthe overexpenditure. The workloadisdistributedonthe basisof a loadbalancingalgorithmwiththe scope/sof VMs,Cloud storage devicesandcloudservices. Auditmonitor Cloudusage monitor Logical networkperimeter Resource cluster Resource replication Service Load Balancing Architecture Thisarchitecture specificallyisusedforworkloaddistributionforCloudservices. Multiple instancesof the Cloudservicesare deployedwithloadbalancingsystem. Alternativelythe loadbalancercanbe integratedintothe Cloudservice The load balancercan be eitherdeployedasanexternal module. The followingmodules are additionally required: Cloudusage monitor Resource cluster(withactive-active failoversystemconfiguration) Resource replication Elastic Disk ProvisioningArchitecture Cloudcostingmodel fordiskstorage maycharge onthe basisof total volume of allocatedstorage space insteadof total space used. The elasticdiskprovisioningarchitecture implementsadynamicstorage provisioningbasedbilling. The user ischargedonlyfor the consumed storage. The technique of thin-provisioningof storage isused. Thin-provisioningallocatesthe storage space dynamicallyforthe VM’sstorage. Requiressome extraoverheadwhenmore storage space istobe allocated. The thin-provisioningsoftware isrequiredtobe installedonVMsto coordinate the thin-provisioning processwiththe hypervisor.
  • 6.
    Redundant Storage Architecture Inorderto avoiddata lossandservice unavailabilitydue todiskfailure,redundantstorage isapplied. Additionally,incase of networkfailure,the disruptionsinCloudservicescanbe avoidedthrough redundantstorage incident. Thisis part of failoversystem(active-passive). The primaryand secondarystorage are synchronizedsothatincase of a disaster,the secondary storage can be activated. A storage device gateway(partof failoversystem) divertsthe Cloudconsumers’requeststosecondary storage device wheneverthe primarystorage device fails. The primaryand secondarystorage locationsmaybe geographicallyapart(fordisasterrecovery) witha (possiblyleased) networkconnectionamongthe twosites Q5. CloudSecurity Threats VirtualizationAttack Baseduponthe administrative privilegesprovidedtothe Cloudconsumersandmulti-tenancy,itis possible tocompromise the underlyingphysical hardware. It isalso possible thatthe securityflawsbe arisingdue to VMsprawl(alack of securitypatchesonOS installedonVM).Anotherpossibilityisthe installationof VM-aware malware toexploitthe security flawsof hypervisor. OverlappingTrust Boundaries Movingof consumerdatato Cloudmeansthat the providernow shares(withthe consumer) the responsibilitiesof availability,confidentialityandintegrityof data. OverlappingTrust Boundaries The consumerthusextendsthe trustboundarytoinclude the cloudprovider.Thisisprone to vulnerabilities. Whenmultiple consumersof acloudshare an IT resource,the trustboundariesoverlap. The providermaynot be able to providerthe securityfeaturesthatcan satisfythe securityrequirement of all the consumersof sharedIT resource ona Cloud. More complex scenariosarise whenthe consumerdataisreplicatedandstoredonmultiple sites.
  • 7.
    FlawedImplementation The implementationof Cloudservicesmayhave some flawsrelatedtoconfigurationresultingintothe occurringof unexpectedevents. Particularlythe securityandoperationalweaknessesinCloudprovider’ssoftware/hardware canbe targetedbythe attackers to putthe integrity,confidentialityand/oravailabilityof ITresourcesof the provideratstake. Disparity of ComputerSecurity Policy A computersecuritypolicydefinesthe setof rulesandmechanismstoensure the securityof the computersof the organization.The computersecuritypoliciesof the consumerandprovidermaynot match. The lack of administrative privilegesprovidedtothe consumermakesthe implementationof the consumerchosencomputersecuritypolicyverydifficult. Contracts As an additional consideration,the SLA offeredbythe providershouldbe carefullyexaminedtoclarify the liabilitiestakenbythe providerandthe securitypolicyimplementedbythe provider.Thishelpsin determiningthe following: If the consumercan applyitsownsecuritypolicieswhile the cloudproviderkeepsthe administrative rightsto the IT infrastructure.Thenhowthisdisparitywillbe overcome. Risk Management: The cloud consumersshouldperformacyclicprocessof riskmanagementtoaccessthe potential threats and challengesrelatedtoCloudadoption.Thisshouldbe apart of riskmanagementstrategy.Itisa three stage process. Identifythe vulnerabilitiesof the (tobe adopted) Cloudenvironment. Identify,quantifyandqualifythe risksrelatedtohow the consumerisplanningtouse the cloud. Create the securitypolicy/iestoavoidand/orlowerthe impactof the risksidentifiedinthe previous step. Reviewthe risksoccurredduringareview periodandhow effectivewere the policies(made inprevious step).Identifyanypolicyupdatesrequired.
  • 8.
    Q6. Desktopvirtualization Desktopvirtualization,oftencalledclientvirtualization,isavirtualizationtechnologyusedtoseparate a computerdesktopenvironmentfromthephysical computer.Desktopvirtualizationisconsideredatype of client-servercomputingmodel becausethe "virtualized"desktopisstoredonacentralized,or remote,serverandnotthe physical machine beingvirtualized. Desktopvirtualization"virtualizes desktopcomputers"andthese virtualdesktopenvironmentsare "served"touserson the network.Youinteractwitha virtual desktopinthe same wayyouwoulduse a physical desktop.Anotherbenefitof desktopvirtualizationisthatisletsyouremotelylog intoaccess your desktopfromanylocation. ServerVirtualization Servervirtualizationisavirtualizationtechniquethatinvolvespartitioningaphysical serverintoa numberof small,virtual serverswiththe helpof virtualizationsoftware.In servervirtualization,each virtual serverrunsmultipleoperatingsysteminstancesatthe same time. The concept of servervirtualizationiswidelyappliedinITinfrastructure asa wayof minimizingcostsby increasingthe utilizationof existingresources.Virtualizingserversisoftenagoodsolutionforsmall- to medium-scale applications.Thistechnologyiswidelyusedforprovidingcost-effective webhosting services. Q7. CloudArchitectural DesignChallenges Service availabilityand Data Lock-in Problem Dependinguponasingle providerforservice deploymentresultsinasingle pointof failure orlock-in. Requiresthe interoperability/standardizationof APIcallsondifferentPaaSplatforms. Data Privacy and SecurityConcerns: Due to publicaccessof Clouds,multitenancyandsophisticatedattacks/malware,the implementation and assurance of privacyand securityof consumers’dataisa bigchallenge. Unpredictable Performance andBottlenecks: The unpredictabilityof processinganddataloadover Cloudservicesintroduce I/Obottleneckssuchas concurrentread/write accessrequirementstosharedstorage forlarge data volumesbymultiple VMs.
  • 9.
    The providershave tocarefullyanalyzethe deploymentdecisionsaccordingtosurge incomputing/data loadsand shouldtune the bottlenecks. DistributedStorage and WidespreadSoftware Bugs: Ensuringdata consistency,durabilityandhighavailabilityisachallenge whenthe dataisdistributed. Debuggingof datato remove inconsistenciesanderrorsis importantbutchallenging. CloudScalability,Interoperabilityand Standardization Scalabilityisone of the basicfeaturesof Cloudcomputingandthusrequires(forexample) dynamic availabilityof ITresources(hardware) forscalingup. The heterogeneityinhardware and/orhypervisormakesitchallengingtodynamicallyinclude more hardware/virtualizedITresources. The openvirtualizationformat(OVF) describesandopen,secure,efficient,portableandextensible formatfor packagingand distributionof VMsandthe software tobe deployedoverVMs. Software Licensingand ReputationSharing: The fact that the license model of commercial software isnotsuitableforutilitycomputing,the providershave torelyuponopensource software and/orbulkusage license. If the reputationof aproviderisaffected(due toconsumers’maliciousbehavior),thenthere isno service tosafe-guardthe provider’sreputation. Q8. VirtualizationSupport and Disaster Recovery The IT resourcesanddata are prone to disasters (natural and/orhumanmade) whichdamage them partiallyorfullyandthusmay crash the whole computingsystemof anorganization. Failover:Itisprocessthroughwhicha systemtransferscontrol (usuallyautomatedly)toanalternate deploymentuponfailureof primarydeployment. Failback:The processof restoringof the systemfromalternative toprimarydeploymentandrestoration of original state. The use of virtualizationcanimplementthe failoverandbringsreductioninfailbacktime. As comparedto (forexample) adatadisasterfordata storedon magnetictapes,daysare require for restoration/recovery. The redundantdeploymentof software solutions,dataandIT resourcesisquite easybyusing virtualization. One deploymentisconsideredasprimary,whileotherdeployment/sare keptasbackup. The primarydeploymentisthenrestoredfromthe mostrecentsnapshot. Virtualizationhasbecome the core partof disasterrecoveryplansof majororganizationssince last decade.
  • 10.
    Virtualizationevenallowsthe testingof disasterrecoveryplanthroughemulationandwithout disturbingtheproduction/primarydeployment. Q9. StudentMarks: print("Enter'x'forexit."); print("Entermarksobtainedin5subjects:"); mark1 = input(); if mark1 == 'x': exit(); else: mark1 = int(mark1); mark2 = int(input()); mark3 = int(input()); mark4 = int(input()); mark5 = int(input()); sum = mark1 + mark2 + mark3 + mark4 + mark5; average = sum/5; if(average>=91andaverage<=100): print("YourGrade isA+"); elif(average>=81andaverage<=90): print("YourGrade isA"); elif(average>=71andaverage<=80): print("YourGrade isB+"); elif(average>=61andaverage<=70): print("YourGrade isB"); elif(average>=51andaverage<=60): print("YourGrade isC+"); elif(average>=41andaverage<=50): print("YourGrade isC"); elif(average>=0andaverage<=40):
  • 11.
    print("YourGrade isF"); else: print("Strange Grade..!!"); Q10.Octagonal Area importmath # Utilityfunction def areaOctagon(side): return(2 * (1 + (math.sqrt(2))) *side *side) # Driverfunction side = 4 print("Areaof RegularOctagon=", round(areaOctagon(side),4)) Q11. FACTORIAL num= 7 # uncommentto take inputfromthe user #num = int(input("Enteranumber:")) factorial = 1 # checkif the numberisnegative,positive orzero if num < 0: print("Sorry,factorial doesnotexistfornegative numbers") elif num== 0: print("The factorial of 0is 1") else: for i in range(1,num+1): factorial = factorial*i print("The factorial of",num,"is",factorial)
  • 12.
    Q12. Bubble Sort defbubbleSort(arr): n = len(arr) # Traverse throughall array elements for i in range(n): # Last i elementsare alreadyinplace for j in range(0,n-i-1): # traverse the array from0 to n-i-1 # Swapif the elementfoundisgreater # thanthe nextelement if arr[j] > arr[j+1] : arr[j],arr[j+1] = arr[j+1], arr[j] # Drivercode to testabove arr = [64, 34, 25, 12, 22, 11, 90] bubbleSort(arr) print("Sortedarray is:") for i in range(len(arr)): print("%d"%arr[i]),