Linux/Xen/Building Xen DomU images: Difference between revisions

From Guungle
Jump to navigation Jump to search
No edit summary
 
(17 intermediate revisions by the same user not shown)
Line 1: Line 1:
==Debian==
==CentOS==


==Ubuntu==
===[[Linux/Xen/DomU/CentOS/CentOS 7|CentOS 7]]===


===Ubuntu 13.10===
==Debian==


Start this process on a existing Ubuntu system. Does not have to be a 13.10 system. You will need to have debootstrap installed and may need to update debootstrap so it has the correct script for 13.10.
==Devuan==


Create a empty image file and format it with ext3.
===[[Linux/Xen/DomU/Devuan/Devuan Jessie|Devuan Jessie]]===
===[[Linux/Xen/DomU/Devuan/Devuan ASCII|Devuan ASCII]]===
===[[Linux/Xen/DomU/Devuan/Devuan Beowulf|Devuan Beowulf]]===


dd if=/dev/zero of=ubuntu_saucy.img bs=1M count=1 seek=1024
==Ubuntu==
mkfs.ext3 ubuntu_saucy.img
 
Create a directory to mount the image on. Using '/mnt/img' for this example.
 
mkdir /mnt/img
mount -oloop ubuntu_saucy.img /mnt/img
 
Start the debootstrap process.
 
debootstrap saucy /mnt/img/
 
Once that completes, copy your existing /etc/apt/sources.list to the new image so we can run updates.
 
cp /etc/apt/sources.list /mnt/img/etc/apt/
 
Mount the necessary system files so that we can enter the new root filesystem with chroot.
 
mount --bind /dev /mnt/img/dev
mount --bind /dev/pts /mnt/img/dev/pts
mount -t proc proc /mnt/img/proc
mount -t sysfs sys /mnt/img/sys
chroot /mnt/img
 
Run updates and install a language pack.
 
apt-get update
apt-get install language-pack-en-base
apt-get upgrade


Configure the system timezone.
===[[Linux/Xen/DomU/Ubuntu/Ubuntu 13.10|Ubuntu 13.10]]===


dpkg-reconfigure tzdata
===[[Linux/Xen/DomU/Ubuntu/Ubuntu 14.04 LTS|Ubuntu 14.04 LTS]]===


Install the kernel image and install SSH server.
===[[Linux/Xen/DomU/Ubuntu/Ubuntu 18.04 LTS|Ubuntu 18.04 LTS]]===
apt-get install linux-image
apt-get install openssh-server

Latest revision as of 13:15, 4 July 2020