Ubuntu certified

Modified: 02 Sep 2015 22:49 UTC

The Ubuntu Certified Images are designed by Canonical to be optimized for various cloud infrastructures, including the Joyent Cloud.

The Certified Images support cloud-init to provide a uniform boot-time setup. Joyent Cloud boot script user-script metadata is also available to do per-boot scripting.

You can use Juju to deploy your web applications on Joyent-hosted Ubuntu instances. To learn how to configure Juju to work with the Joyent Cloud, see Configuring for Joyent Cloud in the Juju documentation

Joyent-supplied Ubuntu images prior to these Certified Images have some basic differences. The summary of differences section summarizes those differences.

About the certified images

The goal of the Ubuntu Certified Images is to work the same way regardless of the cloud infrastructure hosting them. This section describes some basic differences between the Certified Images and the legacy Joyent-supplied Ubuntu images.

Default user

In certified images, the default user is ubuntu. You cannot log in as root. However, the ubuntu user is authorized to use sudo to do things as root.

Default disk layout

In certified images, the ephemeral device (data disk) is mounted at /mnt. In Joyent-supplied images, the ephemeral device is mounted at /data. The following output of the df command shows the default file system in a Certified Image.

$ df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/vda1       7.5G  745M  6.4G  11% /
none            4.0K     0  4.0K   0% /sys/fs/cgroup
udev            493M  4.0K  493M   1% /dev
tmpfs           100M  360K  100M   1% /run
none            5.0M     0  5.0M   0% /run/lock
none            498M     0  498M   0% /run/shm
none            100M     0  100M   0% /run/user
/dev/vdb         33G  177M   31G   1% /mnt

Boot-time setup

The certified images can use both cloud-init and Joyent boot-time setup.

Initialization data (like cloud-init) is provided as metadata when the instance is created. You can provide this metadata CLI command option --metadata-file (or —script for Joyent images).

Cloud-init data is provided as metadata with the cloud-init:user-data key. Joyent boot-time data is supplied as metadata with the user-data and user-script keys.

Keep in mind that you may be able to log in to your instance before cloud-init is finished. Complex cloud-init or user-script scripts could take several minutes to complete. Please plan accordingly.

cloud-init examples

cloud-init is the Ubuntu package that handles first-boot initialization of a cloud instance. You can learn more information about cloud-init here and in the cloud-int documentation.

These examples use the [CloudAPI command-line interface](Working with CloudAPI.html). To run these examples, make sure that you are using at least version 7.2.0 of the CloudAPI tools.

cloud-init with a shell script

Anything in the cloud-init:user-data, runs once per instance on the first boot. In this example, the shell script ubuntu.cloud.sh will run on first boot.

ubuntu.cloud.sh does nothing more than to write a message with the current time in /root/output.txt. It should be in the same directory that you run the sdc-createmachine in.

#! /usr/bin/env bash
echo "Hello World.  The time is now $(date -R)!" | tee /root/output.txt

To provision an Ubuntu instance, you would use the sdc-createmachine command like this. 46407334-9096-40ef-bb72-6f9a094f0507 is the UUID of the the Ubuntu 13.10 image.

$ sdc-createmachine --dataset 46407334-9096-40ef-bb72-6f9a094f0507 \
                    --package g3-standard-1-kvm \
                    --metadata-file cloud-init:user-data=./ubuntu.cloud.sh

After the instance is provisioned, you can log in to it and verify that the script ran:

$ sudo cat /root/output.txt
Hello World.  The time is now Fri, 14 Feb 2014 23:15:13 +0000!
cloud-init with a cloud-config command

cloud-init can also take a YAML file that describes how to configure the instance. In this example, cloud.init is a cloud-init config file that:

#cloud-config

apt_update: true
apt_upgrade: true
packages:
  - apache2

To provision an Ubuntu instance, you would use the sdc-createmachine command like this, using the name of the config file.

  sdc-createmachine --dataset 46407334-9096-40ef-bb72-6f9a094f0507 \
                    --package g3-standard-1-kvm \
                    --metadata-file cloud-init:user-data=./cloud.init

After provisioning, you can check that the apache2 packages were installed:

$ dpkg -l | grep apache
ii  apache2       2.4.6-2ubuntu2.1  amd64  Apache HTTP Server
ii  apache2-bin   2.4.6-2ubuntu2.1  amd64  Apache HTTP Server (binary files and modules)
ii  apache2-data  2.4.6-2ubuntu2.1  all    Apache HTTP Server (common files)
Joyent user-script example

Any script provided as a user script, will run every time the instance boots. The user script can be provided as the name of a file to the —script option to sdc-createmachine, or as the value of the user-script metadata key.

In this example, the script userscript.sh will run when the instance is provisioned as well as on every reboot.

#! /usr/bin/env bash
echo "Hello World.  The time is now $(date -R)!" | tee /root/joyoutput.txt

Provision the instance:

sdc-createmachine --dataset 46407334-9096-40ef-bb72-6f9a094f0507 \
                  --package g3-standard-1-kvm \
                  --script ./userscript.sh

After provisioning, check the output:

ubuntu@eeac1ea5-0c7f-e445-febc-9ba2883dfe7b:~$ sudo cat /root/joyoutput.txt
Hello World.  The time is now Fri, 14 Feb 2014 22:46:50 +0000!

If you were to reboot the instance a few days later, you would see this:

ubuntu@eeac1ea5-0c7f-e445-febc-9ba2883dfe7b:~$ sudo cat /root/joyoutput.txt
Hello World.  The time is now Tue, 18 Feb 2014 17:12:17 +0000!
Summary of differences

This table summarizes the difference between the Canonical Certified images and the Joyent-supplied images.

Joyent-supplied Canonical-supplied
Default user root ubuntu
Disk layout /tmp on separate partition, /data is the mount point for the ephemeral device, statically configured fstab /tmp on rootfs, /mnt is the mount point for the ephemeral device, dynamic mounts
Boot-time setup user-script metadata cloud-init
Kernel Locked Uses stock Ubuntu virtual kernel

15.04 (Vivid) Images

15.04 20150807

Name ubuntu-certified-15.04
Description Ubuntu 15.04 (20150807 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID b33d4dec-db27-4337-93b5-1f5e7c5b47ce
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 15.04
Release:    15.04
Codename:   vivid

What's New in This Image

Packages Installed in This Image

apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

15.04 20150709

Name ubuntu-certified-15.04
Description Ubuntu 15.04 (20150709 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 5603e222-02fa-49f2-8dc9-bc0add4bee50
    $  lsb_release -a
    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 15.04
    Release:    15.04
    Codename:   vivid

What's new in this image

Packages Installed in This Image

   apt
    aptitude
    bash
    bzip2
    curl
    dpkg
    gzip
    openssl
    perl
    python
    sudo
    wget

15.04 20150422

Name ubuntu-certified-15.04
Description Ubuntu 15.04 (20150422 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 38db1c10-2345-448c-875f-f38f36c111b2
    $  lsb_release -a
    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 15.04
    Release:    15.04
    Codename:   vivid
What's new in this image
Packages installed in this image
    apt
    aptitude
    bash
    bzip2
    curl
    dpkg
    gzip
    openssl
    perl
    python
    sudo
    wget

14.10 (Utopic) images

14.10 20150708

Name ubuntu-certified-14.10
Description Ubuntu 14.10 (20150708 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID a41ffcbc-464a-44c0-bf2d-126a269700ba
    $  lsb_release -a
    No LSB modules are available.
    Distributor ID: Ubuntu
    Description:    Ubuntu 14.10
    Release:    14.10
    Codename:   utopic
What's new in this image
Packages Installed in This Image
    apt
    aptitude
    bash
    bzip2
    curl
    dpkg
    gzip
    openssl
    perl
    python
    sudo
    wget

14.10 20141022.3

Name ubuntu-certified-14.10
Description Ubuntu 14.10 (20141022.3 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 47c62485-9803-4d81-9023-c987f5100aff
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.10
Release:    14.10
Codename:   utopic
What's new in this image
Packages Installed in This Image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

14.04 (trusty) images

14.04 20150225.2

Name ubuntu-certified-14.04
Description Ubuntu 14.04.2 LTS (20150225.2 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID c864f104-624c-43d2-835e-b49a39709b6b
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.2 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

14.04 20150708

Name ubuntu-certified-14.04
Description Ubuntu 14.04.2 LTS (20150708 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 143e254a-b185-4d0c-9785-d924f4dc0a0d
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.2 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

14.04 20140929

Name ubuntu-certified-14.04
Description Ubuntu 14.04.1 LTS (20140929 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 5f67e820-1489-4db7-9df2-1d8e3ec5cd90
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.1 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

14.04 20140926

Name ubuntu-certified-14.04
Description Ubuntu 14.04.1 LTS (20140926 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 202d0d26-1d57-4f2e-bf2c-489025845267
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.1 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

14.04 20140729

Name ubuntu-certified-14.04
Description Ubuntu 14.04.1 LTS (20140729 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 202d0d26-1d57-4f2e-bf2c-489025845267
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.1 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

14.04 20140519

Name ubuntu-certified-14.04
Description Ubuntu 14.04 LTS (20140416 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 7735fbba-3706-49f0-8020-9e69e11f8ea1
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget

14.04 20140416

Name ubuntu-certified-14.04
Description Ubuntu 14.04 LTS (20140416 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID df165dad-0a5d-4eb7-8646-50507ff1c136
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04 LTS
Release:    14.04
Codename:   trusty
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget

13.10 (saucy) images

13.10 20140519

Please note: The 13.10 image is now end-of-life and has been disabled. For Virtual Machines based on a 13.10 image, you will need to update your archive mirrors to use old-releases.ubuntu.com in /etc/apt/sources.list. For example:

deb http://old-releases.ubuntu.com/ubuntu/ saucy main
deb-src http://old-releases.ubuntu.com/ubuntu/ saucy main
Name ubuntu-certified-13.10
Description Ubuntu 13.10 (20140519 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 6ae6cc4e-2885-4144-8da2-2fe822e0c84c
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 13.10
Release:    13.10
Codename:   saucy
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget

13.10 20140410

Name ubuntu-certified-13.10
Description Ubuntu 13.10 (20140410 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 96aae6e5-c130-44aa-a4e3-d2394591eee5
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 13.10
Release:    13.10
Codename:   saucy
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget

13.10 20140227

Name ubuntu-certified-13.10
Description Ubuntu 13.10 (20140227 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 049dfe64-6c37-4b88-8e89-4b8aa0f129f2
$  lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 13.10
Release:    13.10
Codename:   saucy
What's new in this image
Packages installed in this image
apt                     install
aptitude                    install
bzip2                       install
curl                        install
dpkg                        install
gzip                        install
login-duo                   install
openssl                     install
perl                        install
python                      install
python2.7                   install
python3                     install
python3.3                   install
sudo                        install
wget                        install

12.04 (Precise) Images

12.04 20150709

Name ubuntu-certified-12.04
Description Ubuntu 12.04.5 LTS (20150709 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 506bd05d-5804-4088-9606-d26568ad0499
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in This Image
    apt
    aptitude
    bash
    bzip2
    curl
    dpkg
    gzip
    openssl
    perl
    python
    sudo
    wget

12.04 20150225

Name ubuntu-certified-12.04
Description Ubuntu 12.04.5 LTS (20150225 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 70abdd85-f257-4b2d-91b7-b7baa0e604a3
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

12.04 20150127

Name ubuntu-certified-12.04
Description Ubuntu 12.04.5 LTS (20150127 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID be16f02b-900d-40ab-b40e-c90033989adf
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

12.04 20140929

Name ubuntu-certified-12.04
Description Ubuntu 12.04.5 LTS (20140929 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 01a24b88-f957-4f9d-9946-fbd21b0612bf
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

12.04 20140926

Name ubuntu-certified-12.04
Description Ubuntu 12.04.5 LTS (20140926 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID d0fb3c79-24b6-4e49-89c8-4e94aaa09099
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

12.04 20140806

Name ubuntu-certified-12.04
Description Ubuntu 12.04.5 LTS (20140806 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 6c970fa8-20ad-48e4-a694-0f68fa1f08fe
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.5 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
openssl
perl
python
sudo
wget

12.04 20140519

Name ubuntu-certified-12.04
Description Ubuntu 12.04.4 LTS (20140519 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID 0fd57f23-bc80-4bde-8ab2-64acf8a14fe9
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.4 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget

12.04 20140408

Name ubuntu-certified-12.04
Description Ubuntu 12.04.4 LTS (20140408 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID fe5aa6c0-0f09-4b1f-9bad-83e453bb74f3
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.4 LTS
Release:    12.04
Codename:   precise
What's new in this release
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget

12.04 20140227

Name ubuntu-certified-12.04
Description Ubuntu 12.04.4 LTS (20140227 64-bit). Certified Ubuntu Server Cloud Image from Canonical.
UUID e28711b3-7f9c-47a7-be7f-ce07e9a99394
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.4 LTS
Release:    12.04
Codename:   precise
What's new in this image
Packages installed in this image
apt
aptitude
bash
bzip2
curl
dpkg
gzip
login-duo
openssl
perl
python
sudo
wget