2016年10月31日 星期一

CORD-in-a-Box Quick Start Guide: Target Server on CloudLab

ClouldLab, OnePC-Ubuntu14.04.4
https://github.com/opencord/cord/blob/master/docs/quickstart.md
https://github.com/opencord/cord.git  b5796fb8a34b779885abc9e8809e361d3463cde9
https://github.com/opencord/platform-install.git   b5796fb8a34b779885abc9e8809e361d3463cde9
bash ~/cord-in-a-box.sh -t | tee ~/install.out
Host Ubuntu 14.04
20161031
(Why so detail? because there's no guarantee it always work with the same environment)

mkl Note: CORD: LC_ALL not configured cause postgresql default cluster not created
http://mkl-note.blogspot.com/2016/10/cord-lcall-not-configured-cause.html

With the new script, I only encounter the above issue. Then I can finally see the holy X "BUILD SUCCESSFUL".

  1. Ensure no password sudo:
    sudo visudo -f /etc/sudoers.d/90-clouding-ubuntu
    Add the following line:
    user_name ALL=(ALL) NOPASSWD:ALL
  2. On your HOST, do not forward your locale to remote server by editing /etc/ssh/ssh_config and comment out SendEnv LANG LC_* line.
    sudo sed -e '/SendEnv/ s/^#*/#/' -i /etc/ssh/ssh_config
    Set the locale, then log out.
    sudo update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8
    exit
    Log in again and try printing the LC_ALL
    printenv | grep LC
    => LC_ALL=en_US.UTF-8

  3. Install the required package (curl I understand, but juju....)
    sudo apt-get update
    sudo apt-get install -y build-essential curl juju git vim tmux
  4. Download the installation script and run. No sudo running the script.
    curl -o ~/cord-in-a-box.sh https://raw.githubusercontent.com/opencord/cord/master/scripts/cord-in-a-box.sh
    mv  -v --backup=numbered ~/install.out ~/install.out.bak; time bash ~/cord-in-a-box.sh -t 2>&1 | tee ~/install.out

The last part of the log:
test-exampleservice : Install curl in testclient ----------------------- 29.69s
maas-test-client-install : Install software ---------------------------- 27.43s
test-vsg : Create a sample CORD subscriber ------------------------------ 3.58s
maas-test-client-install : Install PIP packages ------------------------- 3.16s
test-vsg : Re-run 'make vtn' (work around bug in synchronizer) ---------- 3.07s
test-vsg : Test external connectivity in test client -------------------- 3.04s
test-exampleservice : Re-run 'make vtn' (work around bug in synchronizer) --- 3.02s
setup ------------------------------------------------------------------- 2.49s
setup ------------------------------------------------------------------- 2.14s
test-exampleservice : Get mgmt IP of VM --------------------------------- 2.02s
test-exampleservice : Get public IP of VM ------------------------------- 1.93s
test-vsg : Get mgmt IP of VM -------------------------------------------- 1.81s
test-vsg : Wait for vSG VM to come up ----------------------------------- 1.81s

BUILD SUCCESSFUL

Total time: 29 mins 7.094 secs
Connection to 192.168.121.252 closed.
+ [[ 0 -eq 1 ]]
+ exit 0

real    204m41.956s
user    2m18.897s
sys    0m34.802s
Yes, it's almost 3.5hr, with CloudLab's server.....

CORD: LC_ALL not configured cause postgresql default cluster not created

ClouldLab, OnePC-Ubuntu14.04.4
bash ~/cord-in-a-box.sh -t | tee ~/install.out
When installing maas, the script failed. Running "sudo apt-get install maas" manually get the following error:

psql: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?

It says there's no sql server listening at port 5432. "sudo apt-get install postgresql" shows the postgresql is already installed, but no default sql clusters created:
# pg_lsclusters
Ver Cluster Port Status Owner    Data directory    Log file
FIX1:
Setting a custom data directory for a new PostreSQL installation on Linux | Open Geospatial Technologies
http://geospatial.commons.gc.cuny.edu/2016/10/10/setting-a-custom-data-directory-for-a-new-postresql-installation-on-linux/

Let's create one:
sudo mkdir /data/sql-cluster -p
sudo pg_createcluster -d /data/sql-cluster --start 9.3 main
And you should see:
# pg_lsclusters
Ver Cluster Port Status Owner    Data directory    Log file
9.3 main    5432 online postgres /data/sql-cluster /var/log/postgresql/postgresql-9.3-main.log
Then install maas again:
sudo apt-get install maas

FIX2:
The default sql cluster is not created because the LC_ALL not configured.
command line - How do I fix my locale issue? - Ask Ubuntu
http://askubuntu.com/questions/162391/how-do-i-fix-my-locale-issue

  1. At you ssh client, do not forward your locale to remote server by editing /etc/ssh/ssh_config and comment out SendEnv LANG LC_* line. Or run the following:
    sed -e '/SendEnv/ s/^#*/#/' -i /etc/ssh/ssh_config
  2. Connect to remote server, and:
    sudo update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8
  3. Then log-out and log-in again, LC_ALL should be there.
    # printenv | grep LC
    LC_ALL=en_US.UTF-8
Then if you do "sudo apt-get install postgresql", you should see the default cluster is created.
(........................)

Creating config file /etc/logrotate.d/postgresql-common with new version
Building PostgreSQL dictionaries from installed myspell/hunspell packages...
Removing obsolete dictionary files:
 * No PostgreSQL clusters exist; see "man pg_createcluster"
Processing triggers for ureadahead (0.100.0-16) ...
Setting up postgresql-9.3 (9.3.14-0ubuntu0.14.04) ...
Creating new cluster 9.3/main ...
  config /etc/postgresql/9.3/main
  data   /var/lib/postgresql/9.3/main
  locale en_US.UTF-8
  port   5432
update-alternatives: using /usr/share/postgresql/9.3/man/man1/postmaster.1.gz to provide /usr/share/man/man1/postmaster.1.gz (postmaster.1.gz) in auto mode
 * Starting PostgreSQL 9.3 database server                               [ OK ]
Setting up postgresql (9.3+154ubuntu1) ...
Processing triggers for libc-bin (2.19-0ubuntu6.7) ...

$ pg_lsclusters
Ver Cluster Port Status Owner    Data directory               Log file
9.3 main    5432 online postgres /var/lib/postgresql/9.3/main /var/log/postgresql/postgresql-9.3-main.log
Thus cord-in-a-box.sh won't failed here.



2016年10月27日 星期四

PXE boot

PXE boot will download images as well as their configs, while tftp boot only download assigned image.

Preboot Execution Environment - Wikipedia
https://en.wikipedia.org/wiki/Preboot_Execution_Environment

After parsing a PXE enabled DHCP server DHCPOFFER, the client will be able to set its own network IP address, IP Mask, etc., and to point to the network located booting resources, based on the received TFTP Server IP address and the name of the NBP. The client next transfers the NBP into its own random-access memory (RAM) using TFTP, possibly verifies it (i.e. UEFI Secure Boot), and finally boots from it. NBPs are just the first link in the boot chain process and they generally request via TFTP a small set of complementary files in order to get running a minimalistic OS executive (i.e. WindowsPE, or a basic Linux kernel+initrd). The small OS executive loads its own network drivers and TCP/IP stack. At this point, the remaining instructions required to boot or install a full OS are provided not over TFTP, but using a robust transfer protocol (such as HTTP, CIFS, or NFS).
Ubuntu Netboot Images
http://cdimage.ubuntu.com/netboot/

Installation/Netboot - Community Help Wiki
https://help.ubuntu.com/community/Installation/Netboot#Set_Up_DHCP-BOOT
(Use DNSMASQ)

Ubuntu 14.04 LTS (Trusty Tahr) Netboot
http://cdimage.ubuntu.com/netboot/14.04/

Installation Guide for Ubuntu 14.04
https://help.ubuntu.com/14.04/installation-guide/

Ubuntu Installation Guide
https://help.ubuntu.com/14.04/installation-guide/amd64/install.en.txt

PXEInstallServer - Community Help Wiki
https://help.ubuntu.com/community/PXEInstallServer
(Use isc-dhcp-server)

tftpd-hpa + isc-dhcp-server + netboot.tar.gz
Dell PowerEdge R430, Ubuntu 14.04, 4.4, AMD64,
Cavium ThunderX, Ubuntu14.04, 4.2, ARM64

  1. Install the required services. Download and decompress the netboot.tgz to TFTP server directory.
    apt-get install tftpd-hpa isc-dhcp-server
    cd /var/lib/tftpboot
    tar xf netboot.tar.gz
  2. tftpd-hpa doesn't support symbolic link, but AMD64 netboot.tar.gz contains some links.
    ./ubuntu-installer/amd64/pxelinux.cfg/default -> ../boot-screens/syslinux.cfg
    ./pxelinux.0 -> ubuntu-installer/amd64/pxelinux.0
    ./pxelinux.cfg -> ubuntu-installer/amd64/pxelinux.cfg
    This result in "could not find image...". So I have the DHCP next file parameter to be the "ubuntu-installer/amd64/pxelinux.0" instead of "pxelinux.0", and make ./ubuntu-installer/amd64/pxelinux.cfg/default a real file by copy(or hard link) the linked file.
  3. (Only on R430, not on ThundeX)
    During booting, the screen shows:
    TFTP prefix: ubuntu-installer/amd64
    All the path in the config files should be changed to relative to ubuntu-installer/amd64/, or the bootloader will not be able to boot the installation procedure.
    $ sudo sed -e 's/ubuntu-installer\/amd64\///g' * -i
  4. /etc/dhcp/dhcpd.conf
    subnet 192.168.1.0 netmask 255.255.255.0 {
      range 192.168.1.10 192.168.1.15;
      option broadcast-address 192.168.1.255;
      option routers 192.168.1.1;             # our router
      option domain-name-servers 168.95.1.1;
      option domain-name-servers 168.95.192.1;
      filename "ubuntu-installer/arm64/bootnetaa64.efi"; # (this we will provide later)
    }

    group {
      next-server 192.168.1.204;                # our Server
      host tftpclient {
        filename "ubuntu-installer/arm64/bootnetaa64.efi"; # (this we will provide later)
      }
    }
  5. Restart the service.
    sudo service tftpd-hpa restart; sudo service isc-dhcp-server restart;

 





2016年10月26日 星期三

ANSIBLE: "ansible_processor_count" and "ansible_processor_vcpus" reported as 0

Ubuntu14.04, Linux kernel 4.2.0-19.20-generic, ThunderX 48 cores
ansible-2.1.2.0-1ppa~trusty
Installing MCORD by single-node-pod.sh
master, e003c8989e2

Error:
TASK [prereqs-common : CPU quantity Check] *************************************
Wednesday 26 October 2016  14:46:20 -0700 (0:00:00.335)       0:00:21.442 *****
fatal: [localhost]: FAILED! => {"assertion": "ansible_processor_vcpus >= 12", "changed": false, "evaluated_to": false, "failed": true}


FIX:
"ansible_processor_count" and "ansible_processor_vcpus" reported as 0 · Issue #16533 · ansible/ansible
https://github.com/ansible/ansible/issues/16533

This indicate the cause, but not the fix. This is my fix:

 facts.py | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/facts.py b/facts.py
index e93757b..89b66bf 100644
--- a/facts.py
+++ b/facts.py
@@ -1005,13 +1005,12 @@ class LinuxHardware(Hardware):

             # model name is for Intel arch, Processor (mind the uppercase P)
             # works for some ARM devices, like the Sheevaplug.
-            if key in ['model name', 'Processor', 'vendor_id', 'cpu', 'Vendor']:
+            if key in ['model name', 'Processor', 'vendor_id', 'cpu', 'Vendor','processor']:
                 if 'processor' not in self.facts:
                     self.facts['processor'] = []
                 self.facts['processor'].append(data[1].strip())
-                if key == 'vendor_id':
+                if key == 'processor':
                     vendor_id_occurrence += 1
-                if key == 'model name':
                     model_name_occurrence += 1
                 i += 1
             elif key == 'physical id':
--
1.9.1

cpuinfo
processor    : 0
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 1
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 2
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 3
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 4
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 5
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 6
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 7
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 8
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 9
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 10
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 11
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 12
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 13
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 14
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 15
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 16
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 17
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 18
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 19
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 20
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 21
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 22
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 23
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 24
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 25
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 26
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 27
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 28
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 29
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 30
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 31
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 32
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 33
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 34
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 35
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 36
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 37
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 38
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 39
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 40
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 41
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 42
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 43
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 44
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 45
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 46
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0

processor    : 47
Features    : fp asimd aes pmull sha1 sha2 crc32
CPU implementer    : 0x43
CPU architecture: 8
CPU variant    : 0x0
CPU part    : 0x0a1
CPU revision    : 0
 


Error: server certificate verification failed.


My newly installed ARM64 Ubuntu complaint about certificate verification fail, on apt-get update, wget,..., e.g.

Err https://private-ppa.launchpad.net trusty/main arm64 Packages
  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
WFetched 3853 kB in 21s (180 kB/s)
: Failed to fetch https://private-ppa.launchpad.net/yarmouth-team/15.11/ubuntu/dists/trusty/main/binary-arm64/Packages  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
There are lots of info there that I think is useful:
/etc/ssl/certs/
/etc/ssl/certs/ca-certificates.crt

echo -n | openssl s_client -showcerts -connect private-ppa.launchpad.net:443 2>/dev/null  | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p'

curl-config --ca
sudo update-ca-certificates
But what really fix the issue is the time. Yes, I know certificates has valid started date and expiration date, but I just didn't check it!!!
root@ubuntu:~/prj/opencord# date
Thu Jan  1 16:53:04 PST 1970
server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none - Stack Overflow
http://stackoverflow.com/questions/21181231/server-certificate-verification-failed-cafile-etc-ssl-certs-ca-certificates-c

How to install certificates for command line - Ask Ubuntu
http://askubuntu.com/questions/645818/how-to-install-certificates-for-command-line

2016年10月21日 星期五

M-CORD

CORD: Central Office Re-architected as a Datacenter - ONOS - Wiki
https://wiki.onosproject.org/display/ONOS/CORD%3A+Central+Office+Re-architected+as+a+Datacenter

CORD started as an ONOS use case, but has since been spun off into its own open source project.
Central Office Re-architected as a Datacenter (CORD) - CORD - CORD Wiki
https://wiki.opencord.org/pages/viewpage.action?pageId=1278047
Software Building Blocks
  1. OpenStack [3] is the cluster management suite that provides the core IaaS capability, and is responsible for creating and provisioning virtual machines (VMs) and virtual networks (VNs).
  2. Docker [4] provides a container-based means to deploy and interconnect services. It also plays a key role in configuring and deploying CORD itself (e.g., the other elements—XOS, OpenStack, and ONOS—are instantiated in Docker containers on the POD head nodes.
  3. ONOS [5] is the network operating system that manages the underlying white-box switching fabric. It both hosts a collection of control applications that implement services on behalf of Telco subscribers and is responsible for embedding virtual networks in the underlying fabric, which is in turn accessed via OpenStack’s Neutron API.
  4. XOS [6] is a framework for assembling and composing services. It unifies infrastructure services (provided by OpenStack), control plane services (provided by ONOS), and any data plane or cloud services (running in OpenStack-provided virtual machines and Docker-provided containers).
the reference implementation supports services running in virtual machines (KVM), in containers running directly on bare metal (Docker), and in containers nested inside virtual machines (Docker in KVM).


Mobile CORD
https://wiki.opencord.org/display/CORD/Mobile+CORD

M-CORD
http://opencord.org/wp-content/uploads/2016/03/M-CORD-March-2016.pdf
Mobile CORD - Google Groups
https://groups.google.com/a/opencord.org/forum/#!forum/mobile

opencord invitation bot
https://slackin.opencord.org/

OpenStack Releases: OpenStack Releases
https://releases.openstack.org/

VTN (Virtual Tenant Network)

OpenDaylight Virtual Tenant Network (VTN):Overview - OpenDaylight Project
https://wiki.opendaylight.org/view/OpenDaylight_Virtual_Tenant_Network_%28VTN%29:Overview

OASIS TOSCA (Topology and Orchestration Specification for Cloud Application)
Version 1.0
http://docs.oasis-open.org/tosca/TOSCA/v1.0/os/TOSCA-v1.0-os.html

ONIE (Open Network Install Environment) for switch
http://onie.opencompute.org/

2016年10月20日 星期四

locale.Error: unsupported locale setting

# openstack service create --name keystone --description "OpenStack Identity" identity

Traceback (most recent call last):
  File "/usr/bin/openstack", line 10, in <module>
    sys.exit(main())
  File "/usr/lib/python2.7/dist-packages/openstackclient/shell.py", line 342, in main
    return OpenStackShell().run(argv)
  File "/usr/lib/python2.7/dist-packages/openstackclient/shell.py", line 79, in __init__
    command_manager=commandmanager.CommandManager('openstack.cli'))
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 74, in __init__
    self._set_streams(stdin, stdout, stderr)
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 82, in _set_streams
    locale.setlocale(locale.LC_ALL, '')
  File "/usr/lib/python2.7/locale.py", line 579, in setlocale
    return _setlocale(category, locale)
locale.Error: unsupported locale setting


List locale supported (installed) by current system:
locale -a
Or install the locale by:
sudo apt-get install language-pack-id
Re-generate the locale:
sudo dpkg-reconfigure locales
If I set LC_ALL to something not installed, I got
warning: setlocale: LC_ALL: cannot change locale (zh_TW.UTF-8)
If the LC_ALL is empty:
# sudo dpkg-reconfigure locales
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
        LANGUAGE = "",
        LC_ALL = "",
        LC_PAPER = "zh_TW.UTF-8",
        LC_ADDRESS = "zh_TW.UTF-8",
        LC_MONETARY = "zh_TW.UTF-8",
        LC_NUMERIC = "zh_TW.UTF-8",
        LC_TELEPHONE = "zh_TW.UTF-8",
        LC_IDENTIFICATION = "zh_TW.UTF-8",
        LC_MEASUREMENT = "zh_TW.UTF-8",
        LC_TIME = "zh_TW.UTF-8",
        LC_NAME = "zh_TW.UTF-8",
        LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_ALL to default locale: No such file or directory
Generating locales...
  en_AG.UTF-8... up-to-date
  en_AU.UTF-8... up-to-date
  en_BW.UTF-8... up-to-date
  en_CA.UTF-8... up-to-date
  en_DK.UTF-8... up-to-date
  en_GB.UTF-8... up-to-date
  en_HK.UTF-8... up-to-date
  en_IE.UTF-8... up-to-date
  en_IN.UTF-8... up-to-date
  en_NG.UTF-8... up-to-date
  en_NZ.UTF-8... up-to-date
  en_PH.UTF-8... up-to-date
  en_SG.UTF-8... up-to-date
  en_US.UTF-8... up-to-date
  en_ZA.UTF-8... up-to-date
  en_ZM.UTF-8... up-to-date
  en_ZW.UTF-8... up-to-date
Generation complete.
In my case, my LC_ALL is empty. Setting it to something installed fix the issue:
export LC_ALL=en_US.UTF-8
export LC_ALL='C'


export LC_ALL='zh_TW.UTF-8'
export LC_ALL=''

2016年10月6日 星期四

Paracord Survival Bracelet傘繩求生手環

我以前就會想帶些繩子以防不時之需。但是童軍繩太粗了,很難用。後來看到這些傘繩手環就很心動,但是戶外用品店賣的都貴的誇張了,於是上網查了編法,想要自己編一個。

Youtube上有超多教學影片,可是我不是要裝飾用的漂亮帥氣或者很炫的結,而是要能方便使用,使用時要方便拆解,下面這個就是。

How To Make the "True Survival" Paracord Bracelet (Tutorial) by The Cord Kid - YouTube
https://youtu.be/hiWqLbA6apY


酷酷坊 求生手環 3秒快拆 傘繩手環 kukufun paracord - YouTube
https://youtu.be/V2GGUBzgK_k

§酷酷手作§ DIY傘繩手環組件 新款 四合一 傘繩專用插扣 打火石 求生哨 指北針 鑰匙圈 | 露天拍賣-台灣 NO.1 拍賣網站
http://goods.ruten.com.tw/item/show?21602631882896
買了些零件試作和插扣試作,但是買到了才發現使用 塑膠插扣 不能作到快拆!! 因為當你要拆開時,尾端的零件要能拆掉或者是直接用繩結解開。若是直接打在塑膠扣上,除非剪繩或破壞塑膠扣,不然就只能一條一條慢慢解開了。

打火石+求生哨+指北針實在是很吸引我。但是哨子很難吹,而塑膠扣不能快拆對我來說是個大問題。



所以最後我用D卸扣+調整扣做頭。看起來真的不錯,但是卸扣解開比較不方便。
傘繩全長532cm, 產出25.5cm的手環
大約 手環長=傘繩長/21.69
不過我編的算緊了,再緊應該也緊不到哪去,所以參數大約抓20~22應該沒問題。