Difference between revisions of "Ubuntu template"
m (How to use the Ubuntu Template moved to Ubuntu Template: Better suited at this page name.) |
(warn -> warning) |
||
(19 intermediate revisions by 8 users not shown) | |||
Line 1: | Line 1: | ||
− | The ubuntu template is | + | {{Warning|Dapper (i.e. 6.06) is no longer supported. Use newer Ubuntu templates.}} |
− | ''Please note, that this package really | + | |
+ | The ubuntu template is an OpenVZ [[OS template]] that allows you to run ubuntu dapper in your [[container]], as opposed to the normal Debian stable or Fedora. | ||
+ | ''Please note, that this package is really minimal, you must even install your own language pack!'' | ||
+ | |||
==Why would I want to use ubuntu template?== | ==Why would I want to use ubuntu template?== | ||
− | The ubuntu template includes more up-to-date software. For example, it allows you to install apache 2.0.55, php 5, mysql 5, apache mono and more. Also, if you are used to using ubuntu as a | + | The ubuntu template includes more up-to-date software. For example, it allows you to install apache 2.0.55, php 5, mysql 5, apache mono and more. Also, if you are used to using ubuntu as a Linux distribution for your desktop, you would be more familiar with it, as they use the same exact packages and repositories. Also, you can just follow the [http://wiki.ubuntu.com Ubuntu wiki] easily to install your software, as ubuntu has really good documentation. In addition, ubuntu dapper LTS has a 5 year time period of support. |
+ | |||
==How do I get it?== | ==How do I get it?== | ||
− | + | You may download it from one of the following places: | |
− | ==How do I create a | + | * [http://download.openvz.org/contrib/template/precreated/ubuntu-6.06-i386-minimal.tar.gz download.openvz.org] |
− | + | * One of the [[download mirrors]] | |
+ | |||
+ | You must place this file in <tt>/vz/template/cache/</tt> directory on your [[hardware node]]. | ||
+ | |||
+ | ==How do I create a container that uses this template?== | ||
+ | All you have to do is simply create a normal container but specify ubuntu-6.06-i386-minimal as the template. For example: | ||
<pre> vzctl create 1002 --ostemplate ubuntu-6.06-i386-minimal </pre> | <pre> vzctl create 1002 --ostemplate ubuntu-6.06-i386-minimal </pre> | ||
− | ==How do I set it up? | + | ''Please note that in order to get the correct network settings and more, you must copy the debian configuration file(debian.conf) to ubuntu.conf. This is because Openvz does not yet reconize that ubuntu is its own os, and falls back to another linux distribution. Usually this file is located in /etc/vz/dists but can very depending on your distribution. For CentOS/Fedora this will be located in /etc/sysconfig/vz-scripts/dists. See {{bug|190}}.'' |
− | + | ||
− | + | ==How do I set it up?== | |
− | + | You can either do those modifications on already existing container, or, if you want these changes to be incorporated into your template, create a temporary container, do these changes, stop the container and tar the result into the same template file. | |
− | + | ||
+ | Well, the first thing you *must* do is install a language pack. You can do this by typing in | ||
+ | <pre> apt-get install language-pack-en </pre> | ||
− | ==Packages | + | <pre> |
+ | Bug alert: I (Shane Hathaway) got the following error when I tried to install language-pack-en. | ||
+ | |||
+ | debconf: apt-extracttemplates failed: Bad file descriptordpkg: dpkg - error: PATH is not set. | ||
+ | |||
+ | I patched the problem by typing "export PATH". Even though the path is set, for some | ||
+ | reason it is not exported by default. I also added "export PATH" to /etc/profile . | ||
+ | </pre> | ||
+ | |||
+ | Then you should create another user. To do this, just type in <pre> adduser bob </pre> | ||
+ | You will probably want to install some other basic utilities: <pre>apt-get install man traceroute wget</pre> | ||
+ | Then all you have to do is follow the ubuntu tutorials [https://wiki.ubuntu.com/ApacheMySQLPHP here]. | ||
+ | |||
+ | ==Packages already installed== | ||
*Basic debootstrap system | *Basic debootstrap system | ||
*nano | *nano | ||
Line 23: | Line 47: | ||
==How was this template created?== | ==How was this template created?== | ||
This package was created using debootstrap, and using the ubuntu dapper repositories. There were some hacks that needed to be done to the enviorment to get it working correctly, mainly for networking. The system was bootstrapped on a real ubuntu dapper system with ovzkernel-2.6.8. I checked it with my own server and then my webhosts, and it works correctly. | This package was created using debootstrap, and using the ubuntu dapper repositories. There were some hacks that needed to be done to the enviorment to get it working correctly, mainly for networking. The system was bootstrapped on a real ubuntu dapper system with ovzkernel-2.6.8. I checked it with my own server and then my webhosts, and it works correctly. | ||
+ | |||
+ | ==Network issues== | ||
+ | If the template seems to have no working network it most probably needs more time to bring up the interfaces. The issue is, that | ||
+ | <pre> | ||
+ | /etc/network/if-up.d/ntpdate | ||
+ | </pre> | ||
+ | wants to set the clock during network start and runs into a very long timeout. Since ntpdate is not needed at all inside a container this script can simply be deleted. And Magic - the container starts up as fast as I would expect it to and all network interfaces are up and running at once. | ||
+ | |||
==Bugs== | ==Bugs== | ||
− | Any problems with this template? Post either on the discussion page or on the forums. Or post on my userpage [[User_talk:Dmb]] | + | Any problems with this template? Post either on the [[Talk: {{PAGENAME}}|discussion page]] or on the forums. Or post on my userpage [[User_talk:Dmb]]. |
+ | |||
+ | == See also == | ||
+ | * [[Debian template creation]] howto. | ||
+ | |||
+ | == External links == | ||
+ | * [http://ubuntu.com/ Ubuntu web site] | ||
+ | * [http://wiki.ubuntu.com/ Ubuntu wiki] | ||
[[Category: Templates]] | [[Category: Templates]] | ||
[[Category: HOWTO]] | [[Category: HOWTO]] | ||
+ | [[Category:Ubuntu]] |
Latest revision as of 12:36, 7 April 2009
Warning: Dapper (i.e. 6.06) is no longer supported. Use newer Ubuntu templates. |
The ubuntu template is an OpenVZ OS template that allows you to run ubuntu dapper in your container, as opposed to the normal Debian stable or Fedora. Please note, that this package is really minimal, you must even install your own language pack!
Contents
Why would I want to use ubuntu template?[edit]
The ubuntu template includes more up-to-date software. For example, it allows you to install apache 2.0.55, php 5, mysql 5, apache mono and more. Also, if you are used to using ubuntu as a Linux distribution for your desktop, you would be more familiar with it, as they use the same exact packages and repositories. Also, you can just follow the Ubuntu wiki easily to install your software, as ubuntu has really good documentation. In addition, ubuntu dapper LTS has a 5 year time period of support.
How do I get it?[edit]
You may download it from one of the following places:
- download.openvz.org
- One of the download mirrors
You must place this file in /vz/template/cache/ directory on your hardware node.
How do I create a container that uses this template?[edit]
All you have to do is simply create a normal container but specify ubuntu-6.06-i386-minimal as the template. For example:
vzctl create 1002 --ostemplate ubuntu-6.06-i386-minimal
Please note that in order to get the correct network settings and more, you must copy the debian configuration file(debian.conf) to ubuntu.conf. This is because Openvz does not yet reconize that ubuntu is its own os, and falls back to another linux distribution. Usually this file is located in /etc/vz/dists but can very depending on your distribution. For CentOS/Fedora this will be located in /etc/sysconfig/vz-scripts/dists. See OpenVZ Bug #190.
How do I set it up?[edit]
You can either do those modifications on already existing container, or, if you want these changes to be incorporated into your template, create a temporary container, do these changes, stop the container and tar the result into the same template file.
Well, the first thing you *must* do is install a language pack. You can do this by typing in
apt-get install language-pack-en
Bug alert: I (Shane Hathaway) got the following error when I tried to install language-pack-en. debconf: apt-extracttemplates failed: Bad file descriptordpkg: dpkg - error: PATH is not set. I patched the problem by typing "export PATH". Even though the path is set, for some reason it is not exported by default. I also added "export PATH" to /etc/profile .
Then you should create another user. To do this, just type in
adduser bob
You will probably want to install some other basic utilities:
apt-get install man traceroute wget
Then all you have to do is follow the ubuntu tutorials here.
Packages already installed[edit]
- Basic debootstrap system
- nano
- ssh/sshd
- quota
How was this template created?[edit]
This package was created using debootstrap, and using the ubuntu dapper repositories. There were some hacks that needed to be done to the enviorment to get it working correctly, mainly for networking. The system was bootstrapped on a real ubuntu dapper system with ovzkernel-2.6.8. I checked it with my own server and then my webhosts, and it works correctly.
Network issues[edit]
If the template seems to have no working network it most probably needs more time to bring up the interfaces. The issue is, that
/etc/network/if-up.d/ntpdate
wants to set the clock during network start and runs into a very long timeout. Since ntpdate is not needed at all inside a container this script can simply be deleted. And Magic - the container starts up as fast as I would expect it to and all network interfaces are up and running at once.
Bugs[edit]
Any problems with this template? Post either on the discussion page or on the forums. Or post on my userpage User_talk:Dmb.
See also[edit]
- Debian template creation howto.