playground:playground
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
playground:playground [2015/05/11 11:57] – jona | playground:playground [2024/02/12 13:09] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ===AKSW Cloud=== | + | ====== |
- | + | ||
- | Fabian has reminded us that we are only supposed to use the address range 192.168.35.96..127. | + | |
- | Owners of the instances should change the IPv4 and IPv6 in %%(sql)/ | + | |
- | Fabian: ich sehe nur auf der Switch, welche IPs wo liegen. | + | |
- | Das sind auf Port 17: 75, 77, 78, 123, 124, 161, 201 | + | |
- | Port 18: 110, 128, 139, 141, 143, 145, 146, 147, 162, 163, 180, 190 | + | |
- | Port 16: 110, 138, 140, 191 | + | |
- | (ohne die älteren IPs) | + | |
- | + | ||
- | The AKSW cloud consists of 3 physical servers: | + | |
- | #|| | + | |
- | || **IP** | **Domain name** | **Description** || | + | |
- | || 139.18.2.226 2001: | + | |
- | || 139.18.2.227 2001: | + | |
- | || 139.18.2.228 2001: | + | |
- | ||# | + | |
- | + | ||
- | Add these to your ~~/ | + | |
- | %%(sql) | + | |
- | Host akswcc | + | |
- | Hostname 139.18.2.226 | + | |
- | User uecadmin | + | |
- | + | ||
- | Host akswnc1 | + | |
- | Hostname 139.18.2.227 | + | |
- | User uecadmin | + | |
- | + | ||
- | Host akswnc2 | + | |
- | Hostname 139.18.2.228 | + | |
- | User uecadmin | + | |
- | + | ||
- | Host ubuntu-template | + | |
- | Hostname 2001: | + | |
- | User akswadmin | + | |
- | + | ||
- | %% | + | |
- | + | ||
- | Known Instances (sorted by IPv6): | + | |
- | #|| | + | |
- | || **IPv6 (IPv4)** | **Host** | **Host name** | **Owner** | **Description** | **new akswadmin pw**|| | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 100-103 reserved for host machines! | | | | || | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 139.18.2.134 (was 2001: | + | |
- | || 2001: | + | |
- | || 139.18.2.152 | akswnc2 | | Seebi | LOD2 FAO | AKSW LOD2 Publink 2012 || | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || outdated: 139.18.2.152, | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | || 2001: | + | |
- | ||# | + | |
- | + | ||
- | + | ||
- | ====Instance Creation==== | + | |
- | * Log in to e.g. akswnc2 | + | |
- | * %%(sql)ssh -X akswnc2%% | + | |
- | * -X does X11 forwarding, which means you can transfer some of the user interfaces | + | |
- | * LC_ALL=C virt-manager | + | |
- | * For some reason some Ubuntu update messed up locale settings and virt-manager won't start with the invalid locale config | + | |
- | * Clone the ubuntu-server-template - IMPORTENT: Adjust both the instance AND the storage name | + | |
- | * Log In to the freshly cloned instance | + | |
- | * %%(sql)ssh -X ubuntu-template%% | + | |
- | * Change hostname and IP | + | |
- | * cd cloud-tools | + | |
- | * ./ | + | |
- | * ./ | + | |
- | * Update your .ssh/config file ;) | + | |
- | + | ||
- | + | ||
- | ====Important Notes==== | + | |
- | For each virtual instance there is an XML config files under %%(sql)/ | + | |
- | The virtual hard drives are located under %%(sql)/ | + | |
- | !! Make sure that the bridge setting matches those of the other instances (br0 or br1)!! | + | |
- | + | ||
- | ====Email Notification==== | + | |
- | Hi Instance Owner, | + | |
- | + | ||
- | You can access your instance by adding the following entry to your ~/ | + | |
- | + | ||
- | Host {name-of-your-choice} | + | |
- | HostName 2001: | + | |
- | User akswadmin | + | |
- | + | ||
- | Default password is: akswcloud, please change this ASAP. | + | |
- | + | ||
- | You can then connect with | + | |
- | ssh {name-of-your-choice} | + | |
- | + | ||
- | + | ||
- | Because of IPv6, you may need to do | + | |
- | sudo apt-get install miredo | + | |
- | sudo service miredo restart | + | |
- | + | ||
- | Cheers, | + | |
- | The AKSW cloud management team | + | |
- | + | ||
- | + | ||
- | + | ||
- | ====Graphical Virt-manager==== | + | |
- | %%(sql) | + | |
- | ssh -X uecadmin@139.18.2.226 -s virt-manager | + | |
- | %% | + | |
- | + | ||
- | + | ||
- | If your ssh key has been added to akswcc, you can connect with: | + | |
- | %%(sql)ssh uecadmin@akswcc.informatik.uni-leipzig.de%% | + | |
- | When logged in, there is a README file containing further passwords. | + | |
- | + | ||
- | The webadmin interface is available at: | + | |
- | %%(sql) | + | |
- | https:// | + | |
- | https:// | + | |
- | %% | + | |
- | You can apply for an account there, which then has to be approved by an administrator (usually Claus). | + | |
- | + | ||
- | Basically all administrative task concerning the instances are performed on the akswcc. | + | |
- | + | ||
- | ====Tutorials, | + | |
- | https:// | + | |
- | + | ||
- | ====Instance Management via HybridFox===== | + | |
- | Once you applied for an account at https:// | + | |
- | * install the latest ((http:// | + | |
- | * go to Extras/ | + | |
- | * click " | + | |
- | * in a seperate window, go to the ((https:// | + | |
- | * click " | + | |
- | + | ||
- | ====Creating Instances==== | + | |
- | Beforehand, please note that instances are **transient**. This means, as soon as they terminate they disappear (and with them, all data). | + | |
- | However, it is possible to create virtual hard drives (called volumes) whose existence is independent of that of the instances. | + | |
- | Volumes can then be attached to instances where they appear as ordinary devices (e.g. as / | + | |
- | Read here for way of achieving persistence in the ((http:// | + | |
- | + | ||
- | + | ||
- | For now, once you logged in as uecadmin to the cc, you will find scripts for | + | |
- | running instances and connecting to them. | + | |
- | There is also a script (taken from a tutorial) for creating the keypairs. | + | |
- | + | ||
- | + | ||
- | + | ||
- | ====Change Resources (RAM, CPU, HDD) for Existing Instances==== | + | |
- | Eucalyptus Cloud itself comes with 5 profiles, that can be assigned user definde values for the amount of CPUs, RAM and Disk Space. | + | |
- | + | ||
- | TODO I could' | + | |
- | TODO Make a table with resource limits. | + | |
- | m1.small | + | |
- | m1.large | + | |
- | c1.small | + | |
- | c1.medium | + | |
- | c1.xlarge | + | |
- | + | ||
- | + | ||
- | + | ||
- | ====Change Resources (RAM, CPU, HDD) for Existing Instances with virt-manager==== | + | |
- | + | ||
- | **RAM:** | + | |
- | Open the existing instance and change the value under " | + | |
- | **DISK:** | + | |
- | Appending to an existing disk is very complicated. Adding another disk is relatively easy: | + | |
- | -Open the existing instance -> Add Hardware | + | |
- | -Select " | + | |
- | -Change the value under " | + | |
- | -The disk will be added to the instance. | + | |
- | -To mount it on the computer follow these steps **after point 6.**, default device will be /dev/sda: ((https:// | + | |
- | + | ||
- | + | ||
- | ====FAQ==== | + | |
- | * How can I set the range of public ip addresses? | + | |
- | %%(sql) | + | |
- | vim / | + | |
- | Add the line: | + | |
- | VNET_PUBLICIPS=" | + | |
- | %% | + | |
- | + | ||
- | + | ||
- | ====Virt-Manager==== | + | |
- | A simple way to create (persistent) virtual instances similar to the ones we have with Hyper-V can be achieved with the following instructions. Note that this solution is not meant to replace the cloud, as it lacks features such as automatically allocating instances on node-controllers with free resources. | + | |
- | Instead, the following procedure has to be performed on every single computer that should host such virtual instances. | + | |
- | (except for maybe virt-manager, | + | |
- | + | ||
- | + | ||
- | %%(sql) | + | |
- | sudo apt-get install virt-manager libvirt-bin qemu kvm | + | |
- | %% | + | |
- | + | ||
- | Add us to the kvm-group | + | |
- | %%(sql) | + | |
- | sudo adduser $USER kvm | + | |
- | %% | + | |
- | + | ||
- | Uncomment the lines in / | + | |
- | %%(sql) | + | |
- | # The user ID for QEMU processes run by the system instance | + | |
- | user = " | + | |
- | + | ||
- | # The group ID for QEMU processes run by the system instance | + | |
- | group = " | + | |
- | %% | + | |
- | + | ||
- | Restart the service | + | |
- | %%(sql) | + | |
- | sudo service qemu-kvm restart | + | |
- | %% | + | |
- | + | ||
- | Now you can do | + | |
- | %%(sql) | + | |
- | ssh -X < | + | |
- | virt-manager | + | |
- | %% | + | |
- | + | ||
- | This will open a window, where you can configure connections and instances. | + | |
- | If no connection yet exists, create one: | + | |
- | %%(sql) | + | |
- | File-> | + | |
- | + | ||
- | Hypervisor: QEMU/KVM | + | |
- | Connection: Local (Note: The window we see is actually running on the host we ssh'd into and is forwarded to us). | + | |
- | + | ||
- | Autoconnect: | + | |
- | + | ||
- | Connect | + | |
- | %% | + | |
- | + | ||
- | Done :) | + | |
- | + | ||
- | =====Troubleshooting Virt-Manager===== | + | |
- | Interestingly, | + | |
- | It worked on akswcc and akswnc2, but failed on akswnc1. | + | |
- | * " | + | |
- | + | ||
- | Reinstalling dbus and gconf2 and rebooting solved the problem at least for us. | + | |
- | %%(sql) | + | |
- | sudo apt-get install --reinstall dbus gconf2 | + | |
- | sudo reboot | + | |
- | %% | + | |
- | + | ||
- | + | ||
- | =====IPv6 Host Configuration ===== | + | |
- | Make sure / | + | |
- | %%(sql) | + | |
- | net.ipv6.conf.eth0.accept_ra = 0 | + | |
- | net.ipv6.conf.eth0.autoconf = 0 | + | |
- | + | ||
- | net.ipv6.conf.eth1.accept_ra = 0 | + | |
- | net.ipv6.conf.eth1.autoconf = 0 | + | |
- | + | ||
- | net.ipv6.conf.br0.accept_ra = 0 | + | |
- | net.ipv6.conf.br0.autoconf = 0 | + | |
- | %% | + | |
- | Apply the changes using %%(sql)sysctl -p / | + | |
- | + | ||
- | + | ||
- | Example configuration for / | + | |
- | %%(sql) | + | |
- | auto eth0 | + | |
- | iface eth0 inet static | + | |
- | address < | + | |
- | netmask 255.255.255.0 | + | |
- | network 139.18.2.0 | + | |
- | broadcast 139.18.2.255 | + | |
- | gateway 139.18.2.254 | + | |
- | dns-nameservers 139.18.1.2 | + | |
- | dns-search informatik.uni-leipzig.de | + | |
- | # dns-* options are implemented by the resolvconf package, if installed | + | |
- | + | ||
- | auto eth1 | + | |
- | iface eth1 inet manual | + | |
- | + | ||
- | # Configure the brigde for both IPv4 and IPv6 | + | |
- | # Note the the brigde itself also needs an address | + | |
- | auto br0 | + | |
- | iface br0 inet static | + | |
- | address < | + | |
- | netmask 255.255.254.0 | + | |
- | bridge_ports eth1 | + | |
- | bridge_fd 9 | + | |
- | bridge_hello 2 | + | |
- | bridge_maxage 12 | + | |
- | bridge_stp off | + | |
- | + | ||
- | iface br0 inet6 static | + | |
- | address < | + | |
- | netmask 64 | + | |
- | gateway 2001: | + | |
- | bridge_ports eth1 | + | |
- | bridge_fd 9 | + | |
- | bridge_hello 2 | + | |
- | bridge_maxage 12 | + | |
- | bridge_stp off | + | |
- | %% | + | |
- | Apply the changes using %%(sql)/ | + | |
- | + | ||
- | + | ||
- | Route output should be | + | |
- | %%(sql) | + | |
- | Kernel IP routing table | + | |
- | Destination | + | |
- | localnet | + | |
- | 192.168.122.0 | + | |
- | 192.168.34.0 | + | |
- | default | + | |
- | %% | + | |
- | + | ||
- | =====IPv6 Instance Configuration===== | + | |
- | Example configuration for / | + | |
- | %%(sql) | + | |
- | auto lo | + | |
- | iface lo inet loopback | + | |
- | + | ||
- | auto eth0 | + | |
- | iface eth0 inet6 static | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | %% | + | |
- | Apply the changes using %%(sql)/ | + | |
- | + | ||
- | + | ||
- | Don't forget to edit / | + | |
- | %%(sql) | + | |
- | nameserver 2001: | + | |
- | %% | + | |
- | + | ||
- | + | ||
- | =====IPv6 and ssh' | + | |
- | If ssh < | + | |
- | %%(sql) | + | |
- | sudo apt-get install miredo | + | |
- | %% | + | |
- | + | ||
- | ====Exposing your cloud instance to the WWW==== | + | |
- | You can use HTTP reverse prxies to expose http endpoints like webinterfaces to the braod public. | + | |
- | Lets assume you have a running cloud instance with the following services: | + | |
- | + | ||
- | %%(sql) | + | |
- | 192.168.35.123: | + | |
- | 192.168.35.123: | + | |
- | %% | + | |
- | + | ||
- | The goal is to expose them under a subdomain of aksw.org, for example | + | |
- | + | ||
- | %%(sql) | + | |
- | http:// | + | |
- | http:// | + | |
- | %% | + | |
- | + | ||
- | You can expose them using a cascade of reverse proxies. | + | |
- | + | ||
- | The first reverse proxy needs to be configured on prod0. This reverse proxy will do the name resolving and delegation to your server. Add therefore the an new file to sites-available | + | |
- | with containing the following information: | + | |
- | + | ||
- | %% | + | |
- | < | + | |
- | ServerName mysuperservice.aksw.org | + | |
- | ServerAlias www.mysuperservice.aksw.org | + | |
- | ServerAdmin webmaster@aksw.org | + | |
- | + | ||
- | ProxyRequests Off | + | |
- | ProxyPreserveHost On | + | |
- | + | ||
- | # don't lose time with IP address lookups | + | |
- | HostnameLookups Off | + | |
- | + | ||
- | # needed for named virtual hosts | + | |
- | UseCanonicalName Off | + | |
- | + | ||
- | <Proxy *> | + | |
- | Order allow, | + | |
- | Allow from all | + | |
- | </ | + | |
- | + | ||
- | + | ||
- | ProxyPass / http:// | + | |
- | ProxyPassReverse / http:// | + | |
- | < | + | |
- | Order allow, | + | |
- | Allow from all | + | |
- | </ | + | |
- | + | ||
- | + | ||
- | LogLevel warn | + | |
- | + | ||
- | CustomLog / | + | |
- | ErrorLog | + | |
- | + | ||
- | + | ||
- | </ | + | |
- | %% | + | |
- | Restart the apache service. | + | |
- | IMPORTANT: do not forget to create the directory for the logfiles. | + | |
- | MORE IMPORTANT: do not mess around with this web server! | + | |
- | The second step is enable the rewriting on your machine. Here you can mess around. | + | |
- | Make sure that apache with mod_proxy and mod_proxy_html is installed and the mods are enabled. | + | |
- | Add a new virtual host to your machine, again by adding an file into sites-available and sites-enabled. | + | |
- | This file would contain in our case: | + | |
- | + | ||
- | %% | + | |
- | + | ||
- | < | + | |
- | | + | |
- | + | ||
- | #### For Virtuoso | + | |
- | ProxyRequests off | + | |
- | ProxyPass /virt/ http:// | + | |
- | ProxyPassReverse /virt/ http:// | + | |
- | ProxyHTMLURLMap http:// | + | |
- | < | + | |
- | ProxyPassReverse / | + | |
- | # uncomment next line for version of mod_proxy_html => 3.1 | + | |
- | # | + | |
- | # use next line for version of mod_proxy_html < 3.1 | + | |
- | SetOutputFilter proxy-html | + | |
- | ProxyHTMLURLMap | + | |
- | RequestHeader | + | |
- | </ | + | |
- | + | ||
- | ####### For Tomcat | + | |
- | ProxyRequests off | + | |
- | ProxyPass /tomcat/ http:// | + | |
- | ProxyPassReverse /tomcat/ http:// | + | |
- | ProxyHTMLURLMap http:// | + | |
- | < | + | |
- | ProxyPassReverse / | + | |
- | # uncomment next line for version of mod_proxy_html => 3.1 | + | |
- | # | + | |
- | # use next line for version of mod_proxy_html < 3.1 | + | |
- | SetOutputFilter proxy-html | + | |
- | ProxyHTMLURLMap | + | |
- | RequestHeader | + | |
- | </ | + | |
- | </ | + | |
- | + | ||
- | %% | + | |
- | Restart the apache service. | + | |
- | Now your virtuoso is reachable under | + | |
- | %%(sql) | + | |
- | http:// | + | |
- | %% | + | |
- | and your Tomcat under | + | |
- | %%(sql) | + | |
- | http:// | + | |
- | %% | + | |
- | + | ||
- | Be advised that http:// | + | |
playground/playground.1431338263.txt.gz · Last modified: 2015/09/15 13:58 (external edit)