0% found this document useful (0 votes)
36 views52 pages

Cloud Computing

Notes
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views52 pages

Cloud Computing

Notes
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 52

 NAME – VINAY SHARAD BHUWAD

 SMT.K.G. MITTAL COLLEGE OF ARTS &


COMMERECE
 CLASS – TYBSC.CS
 SUB – CLOUD COMPUTING
 SEAT NO –
PRACTICAL -1
Aim – Define a simple services like Converting Rs into Dollar and Call it from different
platform like JAVA and .NET Framework.

A] Convert Rupees into Dollar and Dollar into Rupees using Java.

1. Open Netbins and create new project.


2. Java webweb applicationProject nameNextFinish

3. Right click on projectnewweb service

4. Now delete this block of code


5. Right clickinsert codeAdd web service operations

6. Give nameAdd
7. Right click on web service fileTest web service

OUTPUT:
8. Right click on Web pagesnewJSP

9. Follow the same steps.


10. Write click on projectNewWeb Service clientbrowseok

11. Drag the button in body tang of output.jsp file.


12. Right click on projectbuildRight click on input.jspRun file

OUTPUT:
B] Convert Rupees into Dollar and Dollar into Rupees using .NET Framework.
1. create new projectsearch MVC and select it.

2. Give the project NameNextcreate

3. After successful creation of projectopen solution explorer


4. ViewsHomeIndex.cshtml and write the following code
5. After that open ControllerHomeController.cs

OUTPUT:
PRACTICAL NO – 2
Aim – Create a simple SOAP Service.

1. Create the new project in netbence software


2. FileNew ProjectJava webweb ApplicationNext

3. Now right click on your project and AddNewWeb Service.

4. Give the web service name and package Name.


5. Now open Web services folder Right click on your web webserviceAdd operation
6. After that give operation namegive return typeclick on add buttongive the name of two
numbersok.

7. Now you can the method of Addition will generate automatically. You have to edit it according your
function.
8. Now follow the same steps to create the methods for Subtraction, Multiplication and Division.

9. Right click on projectDeploy


10. Write click on webserviceTest Web Service
OUTPUT:
11. Now we can perform any Addition, Subtraction, Multiplication and Division.
PRACTICAL NO – 3
Aim – Create simple REST service.

1. Create a java web application.


2. Right click on projectnewothersweb services RESTful web services from patterns.
3. Change the code and create methods as following…

4. Right click on project and clean the project and after deploy it.
5. Right click on RESTful web servicesTest Restful web serviceok
OUTPUT:
PRACTICAL NO – 4
Aim – Develop application to consume Google’s search / Google map RESTful Web service.

1. write a following code for index.html

2. create index.jsp file


Index.jsp file
Now go to the chrome and search Google cloud console.

API’s and services libraryMap JavaScript API and place API Enable

API’s and services Credentials


create credentialAPI keyclose

Now click on API key


Scroll down.

Now select Restrict key and select dropdown and select both checkboxes.
Now click on show key and copy it.
After placing the key Right click on projectcleanbuildRun
OUTPUT:
PRACTICAL NO – 5
Aim – Installation and configuration of virtualization using a KVM.

1. Open the VMWere.

1. Click Power on this virtual machine.


2. Now select the Ubuntu 64-bit and enter the password.

3. Now open terminal in ubuntu and type the following command


 Sudo apt-get update
4. Now type the following commands.
 Sudo grep -c “svm\|vmx”/proc/cpuinfo
 Cat /proc/cpuinfo

5. Now type the following command


 Sudo apt-get install qemu-kvm libvirt-daemon-system libvirt-clients bridge-utils virt-
manager
 Sudo virt-manager
OUTPUT:
PRACTICAL NO – 6
Aim – Download image from server.
1. Open Visual studio and create new project
2. Select ASP.NET Application (.NET Framework)

3. Give the project name.


4. After that open solution explorerRight click on projectAddNew Itemweb
service(ASMX) and give the nameAdd
DownloadImageWS.asmx.cs file
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Web;
using System.Web.Services;

namespace VinayDownloadImgFromWS
{
/// <summary>
/// Summary description for DownloadImageWS
/// </summary>
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
[System.ComponentModel.ToolboxItem(false)]
// To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the
following line.
// [System.Web.Script.Services.ScriptService]
public class DownloadImageWS : System.Web.Services.WebService
{

[WebMethod]
public string HelloWorld()
{
return "Hello World";
}

[WebMethod, Description("Get Image Content")]


public byte[] GetImageFile(String filename)
{
if (System.IO.File.Exists(Server.MapPath("~/Images/") + filename))
{
return System.IO.File.ReadAllBytes(Server.MapPath("~/Images") + filename);
}
else
{
return new byte[] { 0 };
}
}
}
}

5. Now again right click on projectAddnew itemsearch handlerselect generic handler and give
name

VinayHandler.ashx.cs file

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace VinayDownloadImgFromWS
{
/// <summary>
/// Summary description for VinayHandler
/// </summary>
public class VinayHandler : IHttpHandler
{

public void ProcessRequest(HttpContext context)


{
DownloadImageWS ws = new DownloadImageWS();
byte[] binImage = ws.GetImageFile(context.Request["filename"]);
if (binImage.Length == 1)
{
}
else
{
context.Response.ContentType = "image/jpeg";
context.Response.BinaryWrite(binImage);
}
}

public bool IsReusable


{
get
{
return false;
}
}
}
}
6. Again right click on projectAddnew itemselect web formGive the name

7. Click on Viewtoolboxtdesign the following form


8. Now double click on button and change code

9. Write click on Project and create folder images and paste the images.
10. After that execute the code and Enter the Image name in Textfield.
OUTPUT:
PRACTICAL NO – 7
Aim - Implement FOSS-Cloud Functionality VSI (Virtual Server
Infrastructure) Infrastructure as a Service (IaaS), Storage

1. Open the System where you have downloaded the FOSS- Cloud.
2. Enter user-root & Password-admin.

3. Now Right following


command
 fc-node-
configuration -n demo-
system –password admin

4. Now enter ifconfig command.


5. Now copy or save the IP Address (192.168.0.192)
6. Now open the browser of another device and type that IP address in new tab.
7. Username-admin & Password-admin
8. Now download Virtviewer software and Spice client software
9. Now open Registry editor
10. Computer\HKEY_CLASSES_ROOT\spice\shell\open\command

11. We have to edit the command.


12. Open the path of Remote viewer.
13. C:\Users\ A(find in hidden files and folders) \AppData\Local\virt-viewer\bin
14. Now open Registry editor andRight click on itModifyPaste the path and add \remote-viewer
%1 at the end.

15. Come back to browservirtual MachineUpload ISO filechoose file


16. Select the Ubuntu ISO file.
17. After successful upload you will get message Upload finished.
18. ProfilecreatewindowsdefaultX_86_64en-US
19. Now do following setup and click on create button.
20. Virtual MachineVM tampletecreate
21. Now click on Right arrow button under Run action.

22. Now you can see status is running.


23. Click on VM template bar button in Action
24. You will get alert box Click on open-remote viewer.

OUTPUT:

25.

PRACTICAL NO – 8
Aim - Implementation of Openstack with user and private network creation.

 WHAT IS OPENSTACK?
OpenStack is a cloud operating system that controls large pools of compute, storage, and
networking resources throughout a datacentre, all managed and provisioned through APIs with
common authentication mechanisms.
A dashboard is also available, giving administrators control while empowering their users to
provision resources through a web interface.
1. Open terminal and Type the following commands.
2. Before starting the installation you have to update or upgrade the system
 Sudo apt-get update

3. Create new user and give permissions to start the OpenStack.


 Sudo adduser stack
 Sudo -i
 Echo “stack ALL=(ALL) NOPASSWD:ALL”>>/etc/sudoers.

4. Download the Devstack from Github.com


 Sudo apt-get install git
 Git clone https://git .openstack.org/openstack-dev/dev/devstack

5. Run the following commands to avoid the Errors before installation


 Sudo rm /var/lib/dpkg/lock
 Sudo rm /var/lib/apt/lists/lock
 Sudo rm /var/cache/apt/archives/lock
 Sudo rm -rf/var/lib/apt/lists/*

6. Configure local.conf file


 cd devstack/
 cd samples
 cp local.conf ../
 cd..
 sudo nano local.conf

 ADMIN_PASSWORD=pass1
 DATABASE_ PASSWORD=pass1
 RABBIT_PASSWORD=pass1
 SERVICE_ PASSWORD=pass1

 HOST_IP=10.0.2.15(your ip address)
 FLOATING_RANGE=10.0.2.224/24
 ctrl+x ->y

7. Now you can start your installation process.


 ./stack.sh

You might also like