In this quick installation, we are going to show how to install OpenNebula on a CentOS 7.2.
However this will only be the installation part, for creating things like a host, a Template or a Virtual Machine you may wanna go for those articles.
First we have to add Opennebula to the repo list, always watch out for using the newest version.
In this case we're using CentOS 7.2 and the newest available version is 4.14.
Commands that should be run as root are marked by a #, however those marked with a $ should be run by the oneadmin.
First we add the epel, an additional repository needed.
#
Then we make sure to get the opennebula-repository. Always check for the newest version!
For more information you can visit this Page.
#
Install Opennebula + KVM + sunstone webinterface
#
Install system-utilities, we need them for later use!
#
Install redhat-related-stuff aswell as ruby-developer stuff and the MySQL-Server
#
To install the ruby gems do the following:
#
Enable, aswell start the mariaidb service
#
Start the MySQL Installation
#
Create a new user, configure the mariadb for opennebula usage
#
Head into the oneadmin user
#
Get an ssh-key, add the host to the trusted ones
$
Gice access to the ssh key, by setting the right permissions
$
Leave oneadmin
$
In this case we want to start opennbeula and opennebula and start opennebula by startup
#
Move over to the following directory
#
Download the GPG-Key for the openvswitch
#
Add the repo for openvswitch
#
Install openvswitch
#
We start openvswitch in the old-fashion way
#
This is our configuration for the openvswitch-bridge
#
Add firewall rules
#
You can login with the "oneadmin" and the password you get from
#
But dont forget to tell your server where to listen on:
#
However this will only be the installation part, for creating things like a host, a Template or a Virtual Machine you may wanna go for those articles.
First we have to add Opennebula to the repo list, always watch out for using the newest version.
In this case we're using CentOS 7.2 and the newest available version is 4.14.
Commands that should be run as root are marked by a #, however those marked with a $ should be run by the oneadmin.
First we add the epel, an additional repository needed.
#
yum install -y epel-release
Then we make sure to get the opennebula-repository. Always check for the newest version!
For more information you can visit this Page.
#
cat << EOT > /etc/yum.repos.d/opennebula.repo > [opennebula] > name=opennebula > baseurl=http://downloads.opennebula.org/repo/4.14/CentOS/7/x86_64/ > enabled=1 > gpgcheck=0 > EOT
Install Opennebula + KVM + sunstone webinterface
#
yum install -y opennebula-server opennebula-node-kvm opennebula-sunstone
Install system-utilities, we need them for later use!
#
yum install -y policycoreutils-python setroubleshoot-server firewalld wget
Install redhat-related-stuff aswell as ruby-developer stuff and the MySQL-Server
#
yum install -y redhat-lsb ruby-devel mariadb-server
To install the ruby gems do the following:
#
/usr/share/one/install_gemsThen you should come up with something like this:
Distribution "redhat" detected. About to install these dependencies: * gcc-c++ * gcc * sqlite-devel * curl-devel * mysql-devel * openssl-devel * ruby-devel * make Press enter to continue... yum install gcc-c++ gcc sqlite-devel curl-devel mysql-devel openssl-devel ruby-devel make
Enable, aswell start the mariaidb service
#
systemctl enable mariadb systemctl start mariadb
Start the MySQL Installation
#
mysql_secure_installation
Create a new user, configure the mariadb for opennebula usage
#
mysql -u oneadmin -p Your password CREATE DATABASE one; GRANT ALL PRIVILEGES ON one.* TO 'oneadmin'@'localhost' IDENTIFIED BY '1oneadm1n'; FLUSH PRIVILEGES;
Head into the oneadmin user
#
su oneadmin
Get an ssh-key, add the host to the trusted ones
$
cat << EOT > ~/.ssh/config Host * StrictHostKeyChecking no UserKnownHostsFile /dev/null EOT
Gice access to the ssh key, by setting the right permissions
$
chmod 600 ~/.ssh/config
Leave oneadmin
$
exit
In this case we want to start opennbeula and opennebula and start opennebula by startup
#
systemctl start opennebula systemctl start opennebula-sunstone systemctl enable opennebula
Move over to the following directory
#
cd /etc/pki/rpm-gpg
Download the GPG-Key for the openvswitch
#
wget http://artemit.com.es/repo/RPM-GPG-KEY-artemit
Add the repo for openvswitch
#
cat << EOT >/etc/yum.repos.d/artemit.repo [artemit] Name = artemit baseurl =http://artemit.com.es/repo Enabled = 1 dem Parameter gpgcheck deaktiviert = 1 gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-artemit EOT
Install openvswitch
#
yum install openvswitch -y
We start openvswitch in the old-fashion way
#
chkconfig openvswitch on systemctl start openvswitch ovs-vsctl show
This is our configuration for the openvswitch-bridge
#
cat << EOT > /etc/sysconfig/network-scripts/ifcfg-ovsbr0 DEVICE=ovsbr0 ONBOOT=yes DEVICETYPE=ovs TYPE=OVSBridge BOOTPROTO=static IPADDR=192.168.1.1 NETMASK=255.255.255.0 IPV6INIT=yes IPV6ADDR=2a01:4f8:191:12af::2/64 DNS1=213.133.100.100 DNS2=213.133.98.98 DNS3=213.133.99.99 DNS4=2a01:4f8:0:a102::add:9999 DNS5=2a01:4f8:0:a0a1::add:1010 DNS6=2a01:4f8:0:a111::add:9898 HOTPLUG=no EOT
Add firewall rules
#
echo net.ipv4.ip_forward=1 >> /usr/lib/sysctl.d/00-system.conf echo net.ipv6.conf.all.forwarding=1 >> /usr/lib/sysctl.d/00-system.conf firewall-cmd --zone=public --add-port=9869/tcp --permanent sysctl -p /usr/lib/sysctl.d/00-system.conf
You can login with the "oneadmin" and the password you get from
#
cat /var/lib/one/.one/one_auth
But dont forget to tell your server where to listen on:
#
nano /etc/one/sunstone-server.confThen search for somehing like this:
# Server Configuration # :host: 127.0.0.1 :port: 9869Change it to the desired port and IP, in our case this is:
# Server Configuration # :host: 0.0.0.0 :port: 9869
Ref : http://iaas.wikispaces.com/Installation+OpenNebula+14.4+CentOS+7.2
No comments:
Post a Comment