Difference between revisions of "EBC azure"

From eLinux.org
Jump to: navigation, search
(Connecting to Your Instance: Added details)
m (Connecting to Your Instance: Added azureuser)
Line 22: Line 22:
  
 
== Connecting to Your Instance ==
 
== Connecting to Your Instance ==
Connecting to your machine is as easy as ssh, just substitute your machine's name for mine.
+
Connecting to your machine is as easy as ssh, just substitute your machine's name for mine. Note, the default account is '''azureuser'''.
  
  $ '''ssh -XC ''test-yoder''.cloudapp.net'''
+
  $ '''ssh -XC azureuser''test-yoder''.cloudapp.net'''
 
  Warning: Permanently added 'test-yoder.cloudapp.net,138.91.113.249' (ECDSA) to the list of known hosts.
 
  Warning: Permanently added 'test-yoder.cloudapp.net,138.91.113.249' (ECDSA) to the list of known hosts.
 
  Welcome to Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-36-generic x86_64)
 
  Welcome to Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-36-generic x86_64)
Line 43: Line 43:
 
   
 
   
 
  Last login: Mon Oct  6 18:05:12 2014 from 137.112.44.233
 
  Last login: Mon Oct  6 18:05:12 2014 from 137.112.44.233
 +
azureuser@test-yoder:~$
  
 
You can now use the machine as you would your host.
 
You can now use the machine as you would your host.

Revision as of 15:50, 6 October 2014

thumb‎ Embedded Linux Class by Mark A. Yoder


Here's how to set a virtual machine in Microsoft's azure cloud to compile a kernel.

Selecting and Starting a New Instance

AzureManager.png

  • Click on NEW on the bottom left of the page.

AzureVM.png

  • Select VIRTUAL MACHINE, QUICK CREATE and fill in the fields. The best machine you can get is 2 cores.
  • Click CREATE A VIRTUAL MACHINE on the bottom right.
  • Once you machine is running (it will take a few minutes), click on it.

AzureCreated.png

  • Click on DASHBOARD on the upper left above the cloud.

AzureIP.png

  • Scroll to the bottom until you see DNS NAME. Remember this name.

Connecting to Your Instance

Connecting to your machine is as easy as ssh, just substitute your machine's name for mine. Note, the default account is azureuser.

$ ssh -XC azureusertest-yoder.cloudapp.net
Warning: Permanently added 'test-yoder.cloudapp.net,138.91.113.249' (ECDSA) to the list of known hosts.
Welcome to Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-36-generic x86_64)

 * Documentation:  https://help.ubuntu.com/

  System information as of Mon Oct  6 22:01:12 UTC 2014

  System load: 0.79               Memory usage: 2%   Processes:       208
  Usage of /:  16.4% of 28.80GB   Swap usage:   0%   Users logged in: 0

  Graph this data and manage this system at:
    https://landscape.canonical.com/

  Get cloud support with Ubuntu Advantage Cloud Guest:
    http://www.ubuntu.com/business/services/cloud


Last login: Mon Oct  6 18:05:12 2014 from 137.112.44.233
azureuser@test-yoder:~$ 

You can now use the machine as you would your host.

Connecting More Easily

You have to type a lot to do a simple ssh. Here's how to save some typing.

$ sudo vi /etc/hosts

Add a line like:

54.165.3.13   ec2

where the number is your ec2 machine's IP address.

$ vi ~/.ssh/config

and add

Host ec2
  User ubuntu
  UserKnownHostsFile /dev/null
  StrictHostKeyChecking no
  IdentityFile ~/.ssh/KeyPair.pem

Now you can login with

$ ssh ec2

You can even copy to and from with

$ scp local_file ec2:remote_file


thumb‎ Embedded Linux Class by Mark A. Yoder