Cloud Computing, Past Papers, UOS Main Campus

Cloud Computing Past Paper 2017 – BSCS 8th Term UOS (CS-4544)

ProgramBSCS
Term8th
Year2017
Course codeCS-4544
AnswersSolved ✓

University of Sargodha BS Computer Science 8th term Cloud Computing (CS-4544) paper, 2017 exam (80 marks, 2:30 hours). The paper is retyped below without the handwritten roll number and name, followed by solved answers for all 16 short questions and all five subjective questions: privileged instructions under a hypervisor, privacy and federation, cloud web services, x86 virtualization techniques, and the MSP model and data centres.

Solved answers

Q1 – Short answers (16 × 2)

1. Hosted vs hypervisor VM. A hosted (type 2) hypervisor runs as an application on top of a host OS (VirtualBox, VMware Workstation). A native/bare-metal (type 1) hypervisor runs directly on the hardware (VMware ESXi, Xen, Hyper-V) – faster and more secure, used in data centres.

2. Resilience. The ability of a system to keep providing service, or recover quickly, when failures, attacks or load spikes occur – through redundancy, replication, failover and backups.

3. “Lack of global clock”. In a distributed system each computer has its own clock and there is no single shared time, so the exact order of events on different machines cannot be known directly; logical clocks (Lamport, vector clocks) or clock synchronisation (NTP) are used.

4. FDI. In cloud/IT management courses FDI usually means Fault Detection and Isolation – detecting that a fault has occurred and locating the faulty component so it can be isolated and repaired. (In economics FDI is Foreign Direct Investment.)

5. DMTF. The Distributed Management Task Force creates open management standards (CIM, OVF, CIMI, Redfish, DASH) so tools from different vendors can manage servers, networks and clouds in a common way.

6. Open Virtualization Format. A DMTF standard for packaging and distributing virtual machines (disk images plus an XML descriptor) so they can be moved between different hypervisors and clouds.

7. Risk awareness. Knowledge and understanding among staff and management of the threats and risks to information systems (security, privacy, availability) and of the policies to reduce them, achieved by training and communication.

8. Fault-tolerant system. Continues operating correctly when components fail: redundancy, no single point of failure, fault detection and isolation, automatic failover and recovery, graceful degradation.

9. Monolithic computing. All processing done on a single computer (or a single application built as one indivisible unit), with no distribution of work over a network – the opposite of distributed computing.

10. Federated Identity Management. Allows a user to use one identity to access services of several organisations or clouds through trust relationships (single sign-on), using SAML, OAuth, OpenID Connect.

11. Characteristics of distributed systems. Resource sharing, concurrency, scalability, fault tolerance, transparency, no global clock, independent failures.

12. Replication vs failure transparency. Replication transparency hides from users that several copies of a resource exist. Failure transparency hides the failure and recovery of a component, so the user’s task still completes.

13. SMTP. Simple Mail Transfer Protocol – the standard protocol (TCP port 25, 587 for submission) for sending e-mail between mail servers and from clients to servers.

14. How the TLB helps the MMU. The Translation Lookaside Buffer is a small fast cache of recent virtual-to-physical page translations. The MMU checks it first; on a hit it avoids walking the page tables in memory, which makes address translation much faster.

15. Zimbra. An e-mail and collaboration suite (mail, calendar, contacts, tasks, file sharing) with a web client; available as open source and commercial editions and as cloud-hosted service.

16. Elastic IP address. A static public IPv4 address (AWS term) allocated to an account that can be remapped to any instance, so if an instance fails the address can be moved to another and the service keeps the same IP.

Q2 – Guest OS executing a privileged instruction

With full hardware-assisted virtualization (Intel VT-x / AMD-V), the guest OS runs in a special “guest” mode (VMX non-root). When the guest executes a privileged instruction – for example writing to CR3 to change the page-table base, or an I/O instruction such as OUT – the CPU does not execute it directly on the real hardware. Instead it causes a trap (VM exit) to the hypervisor (VMX root mode).

The hypervisor examines the cause, emulates the instruction on the virtual hardware state of that VM (e.g. updates the shadow/extended page tables or passes the I/O request to a virtual device), and then performs a VM entry to resume the guest at the next instruction. The guest OS believes it executed the instruction itself.

Example: a guest Linux kernel loads a new page table for a process (MOV CR3). This traps to KVM; KVM updates its extended page tables (EPT) mapping guest-physical to host-physical memory, then resumes the guest. Similarly, a guest writing to a disk controller port traps, and the hypervisor forwards the request to a virtual disk file. This trap-and-emulate approach keeps VMs isolated and protects real hardware.

Q3 – Privacy in the cloud; encrypted vs trusted federation

Privacy in the cloud is about protecting personal and sensitive data from unauthorized collection, use and disclosure when it is stored and processed by a third-party provider. Concerns: loss of control over data, data location and cross-border laws, access by provider staff or governments, multi-tenancy leaks, data retention after deletion, secondary use of data. Measures: encryption at rest and in transit, access control and identity management, data minimisation and anonymisation, clear contracts/SLAs, compliance (GDPR, HIPAA), audits and transparency.

Federation links identity and messaging systems of different domains. In trusted federation the domains trust each other through verified identities (e.g. TLS certificates from a recognised CA and DNS checks), so servers can authenticate each other strongly. In encrypted federation the connection between servers is encrypted (TLS) but certificates may be self-signed and not fully verified, so communication is confidential but the identity of the other server is weakly assured (often combined with dialback). Trusted federation gives better protection against spoofing; encrypted federation is easier to set up. (Terms from XMPP/presence federation in cloud texts.)

Q4 – Web services delivered from the cloud

  • Infrastructure services (IaaS): Amazon EC2 virtual servers, S3 storage, Elastic Block Store.
  • Platform services (PaaS): Google App Engine, Azure App Service, Heroku – developers deploy web applications without managing servers.
  • Software services (SaaS): Gmail, Google Docs, Microsoft 365, Salesforce CRM, Zoho.
  • Communication and collaboration: Skype/Teams, Zoom, Slack.
  • Web APIs: payment (PayPal, Stripe), maps (Google Maps API), messaging (Twilio), AI services (speech, translation).
  • Monitoring, security and database services: Amazon RDS, CloudWatch, Cloudflare CDN.

They are reached over HTTP using SOAP or REST interfaces, billed per use, scale on demand and need no local installation.

Q5 – Virtualizing x86 privileged and sensitive instructions

The classic x86 was not virtualizable by simple trap-and-emulate because 17 sensitive instructions (e.g. POPF, SGDT, SMSW) do not trap when run in user mode. Techniques used:

  • Binary translation (VMware): the hypervisor scans guest kernel code and replaces sensitive instructions with safe sequences that call the VMM; user code runs directly.
  • Para-virtualization (Xen): the guest OS is modified to replace privileged operations with hypercalls to the hypervisor.
  • Hardware-assisted virtualization (Intel VT-x, AMD-V): new CPU modes (root/non-root) make sensitive instructions cause VM exits automatically; EPT/NPT accelerate memory virtualization.
  • Trap-and-emulate for privileged instructions, with ring deprivileging (guest kernel runs in ring 1 or non-root ring 0).

Q6 – MSP model, cloud data centres and open source

MSP model: a Managed Service Provider delivers IT services remotely for a subscription – monitoring, backup, security, help desk, managed hosting. Features: proactive 24/7 monitoring, predictable monthly cost, SLAs, expert staff, scalability; MSPs often deliver their services from the cloud.

Cloud data centres: large facilities with thousands of commodity servers, storage and network equipment; virtualization and automation; high-density racks, redundant power and cooling, geographic redundancy, energy efficiency (PUE), software-defined networking and storage, multi-tenancy.

Role of open source: most cloud data centres run on open source software – Linux, KVM/Xen hypervisors, OpenStack, Kubernetes, Docker, Apache/Nginx, MySQL/PostgreSQL, Hadoop. Benefits: no licence cost, flexibility to customise, avoiding vendor lock-in, large community support, rapid innovation and open standards.

Save this paper for offline studyDownload the question paper, or save the paper together with all solved answers as a PDF.
↓ Download Paper (JPG)

About Saif R

An educator and technology enthusiast passionate about empowering students through quality education and digital learning. Dedicated to making academic resources and opportunities accessible to everyone.