JavaScript must be enabled in order for you to see "WP Copy Data Protect" effect. However, it seems JavaScript is either disabled or not supported by your browser. To see full result of "WP Copy Data Protector", enable JavaScript by changing your browser options, then try again.

Setup a MAAS Server on the Ubuntu Desktop 14.04.2

為了不要打破一周一費文慣例,因此我現在來分享這禮拜碰到的新事物;湊巧在Survey Ubuntu Hardware Certification的時候,裡面有提到需要額外Setup一台MAAS(Metal as a Service)ServerAuto Deploy測試機台的一種Service,換句話說,只要Install完Relative的Package後,即可透過Web的方式部屬測試機台(它們稱為Master和Node)的服務,免去要架設與設定一些較瑣碎Config(Like dhcpd, tftpd或httpd等),非常的方便實用;那該如何架設呢,讓我們來看看,如下:

1) Install Ubuntu Desktop 14.04.2 and change the passwd of root(需建一個Sudo帳號,這邊以ubuntu為例)
#sudo -s
#passwd root

2) Install the package of openssh-server and setup(更改Parameter的Vaule)
#apt-get update
#apt-get install openssh-server
#vi /etc/ssh/ssh_config
StrictHostKeyChecking no
#service openssh-server restart

3) Modify the network setting with the following topology

#vi /etc/network/interfaces(可以透過#ifconfig -a去Check Dev Name)
auto eth0
iface eth0 inet static
auto eth1
iface eth1 inet dhcp
#ifdown eth0 && ifup eth1
#ifup eth0 && ifup eth1

4) Upgrade the latest package and install iperf and bzr(Bazaar:next-generation distributed version control)
#apt-get update
#apt-get dist-upgrade
#apt-get install iperf
#iperf -v -> Check the version about the iperf
#apt-get install bzr
#bzr branch lp:maas-cert-server
#apt-get install apt-mirror -> Can omit
#cp -a /var/spool/apt-mirror/* /srv -> Same as above
#cp ~/maas-cert-server/* /usr/local/bin -> Could be in /home/ubuntu, Same as above
#apt-get install simplestreams ubuntu-cloudimage-keyring -> Same as above
#sstream-mirror --keyring /usr/share/keyring/ubuntu-cloudimage-keyring.gpg --max=1 -v

5) Install the package about the maas and amtterm(Amtterm:Intel AMT serial-over-lan client)
#apt-get install apache2
#add-apt-repository ppa:maas-maintainers/stable
#apt-get update
#apt-get install maas amtterm maas-dhcp maas-dns
#dpkg -p maas | grep Version -> Check the version of maas that is 1.7?
#dpkg-reconfigure maas-region-controller -> Setup the ip of eth0 that is
#dpkg-reconfigure maas-cluster-controller -> Setup with
#maas-region-admin createsuperuser -> Setup with root and his password
#ssh-keygen -> Echo all with space
#vi /etc/hosts maas
#cat /root/.ssh/

6) Setup the network and node and download the pxe image through the GUI of MAAS(先將eth0設為DHCP&DNS Manage與相關設定以及測試機器設為PXE開機外,紀錄BMC的IP)
#cd /usr/local/bin && ./

7) Install hardware certification packages automatically via MAAS
#cd /etc/maas/preseeds
#cp generic generic-orig
#cp ~/maas-cert-server/preseed/stable-preseed-generic ./generic -> Could be in /home/ubuntu/
#cp curtin_userdata curtin_userdata-orig
#cp curtin_userdata_custom curtin_userdata_custom-orig
#cp ~/maas-cert-server/preseed/curtin_userdata ./ -> Could be in /home/ubuntu/
#cp ~/maas-cert-server/preseed/curtin_userdata ./curtin_userdata_custom -> Could be in /home/ubuntu/
Repeat the actions like above that include Commission, Accuire node and Start node.

8) SSH to the server under test, and change the password and run test
#ssh ubuntu@<SUT's IP> -> 預設為空密碼

◎、以上就是Setup一個MAAS Server搭配Ubuntu Desktop 14.04.2簡易介紹,至於上述的過程均參照MANIACGuideOperate,還有關於HW Cert的PolicyRequirement與Proceduce可以參照這份Guide除此之外這邊有提到直接透過安裝的方式把MAAS做導入,另外還有搭配Juju一整套自動部署的系統留給有興趣的看倌囉(On openstack),先到這吧,收工囉!

Leave a Comment

NOTE - You can use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

This site is protected by WP-CopyRightPro