diff options
author | Silvino <silvino@bk.ru> | 2019-06-16 05:04:09 +0100 |
---|---|---|
committer | Silvino <silvino@bk.ru> | 2019-06-16 05:04:44 +0100 |
commit | 296be79a3b724db67a37244a67cfb3e4ef6b652f (patch) | |
tree | 6136b7fbe2082b018a6a06f897b7012177cce630 /core/install.html | |
parent | fdc231661647d4ca15ddf312e85b210eabd23e50 (diff) | |
parent | 951a8a84411da6b71cee11d8c9feb993b984acf5 (diff) | |
download | doc-296be79a3b724db67a37244a67cfb3e4ef6b652f.tar.gz |
doc release 0.5.3
Diffstat (limited to 'core/install.html')
-rw-r--r-- | core/install.html | 108 |
1 files changed, 69 insertions, 39 deletions
diff --git a/core/install.html b/core/install.html index 69a82cf..1526c12 100644 --- a/core/install.html +++ b/core/install.html @@ -43,13 +43,14 @@ <h2 id="step2">1.1.2. Prepare target</h2> <p>Prepare disk or target location where new system will - be installed. Follow steps describe how to create efi and - separate partitions such as; - bios grub, EFI, boot, root, var, usr, swap and home. + be installed. Follow steps describe how to create efi system, + for bios_boot systems is only needed the boot partition in + the beginning of the disk and can use ext4 file system for example. For more information about gpt partitions table read - <a href="http://devil-detail.blogspot.com/2013/07/install-grub2-on-gpt-disk-dedicated-partition.html">devil-detail grub2 on gpt</a>. - Script <a href="scripts/setup-target.sh">setup-target.sh</a> - creates follow partitions;</p> + <a href="http://devil-detail.blogspot.com/2013/07/install-grub2-on-gpt-disk-dedicated-partition.html">devil-detail grub2 on gpt</a>. Script <a href="scripts/setup-target.sh">setup-target.sh</a> help to create partitions + scripts.</p> + + </p> <p>Create gpt label and set unit size to use;</p> @@ -93,14 +94,40 @@ <h3>/</h3> + <p>There are different ways to achieve disk encryption, + the method described uses cryptosetup to create cryptodevice + with <a href="../tools/lvm.html">lvm</a> inside containing + root and other partitions such as; + var, usr, swap and home. + + <pre> + (parted) mkpart primary 1132 100% + (parted) set 4 lvm on + </pre> + + <p>Create encrypted block for lvm;</p> + + <pre> + # modprobe dm-crypt + # cryptsetup luksFormat /dev/sda4 + # cryptsetup luksOpen /dev/sda4 cryptlvm + </pre> + + <p>Create physical group and volume group;</p> + + <pre> + # pvcreate /dev/mapper/cryptlvm + # vgcreate vg_system /dev/mapper/cryptlvm + </pre> + <p>Core collection installation on root partition uses approximately 2G. Partition with 8G-20G is recommended for a server or desktop with dedicated ports partition or using only compiled packages. Partition size 20G;</p> + <pre> - (parted) mkpart primary ext4 1132 21132 - (parted) name 4 root + # lvcreate -L 20G -n lv_root vg_system </pre> <h3>/var</h3> @@ -109,8 +136,7 @@ system is configured. Partition size 2G;</p> <pre> - (parted) mkpart primary ext4 21132 23132 - (parted) name 5 var + # lvcreate -L 2G -n lv_var vg_system </pre> <h3>Swap (ram)</h3> @@ -119,27 +145,19 @@ memory ram, ports system will be configured to build on ram. To build firefox is necessary at least 34G. Partition size 4G;</p> - <p>Is better to create swap partition later using - <a href="../tools/lvm.html">lvm</a>.</p> - <pre> - (parted) mkpart primary linux-swap 23132 27132 - (parted) name 6 swap + # lvcreate -L 4G -n lv_swap vg_system </pre> <h3>/home</h3> - <p>Home partition on desktop fill the rest of disk - space while on server this partition can be unnecessary. + <p>On desktop fill the rest of disk space while on server + this partition can be replaced with /srv. Fill the rest of disk space;</p> - <p>Is better to create home partition later using - <a href="../tools/lvm.html">lvm</a>.</p> - <pre> - (parted) mkpart primary ext4 27132 100% - (parted) name 7 home + # lvcreate -L 120G -n lv_home vg_system </pre> <h3>Create filesystems</h3> @@ -147,32 +165,33 @@ <pre> $ sudo mkfs.fat -F 32 /dev/sda2 $ sudo mkfs.ext4 /dev/sda3 - $ sudo mkfs.ext4 /dev/sda4 - $ sudo mkfs.ext4 /dev/sda5 - $ sudo mkswap /dev/sda6 - $ sudo mkfs.ext4 /dev/sda7 + $ sudo mkfs.ext4 /dev/vg_system/lv_root + $ sudo mkfs.ext4 /dev/vg_system/lv_var + $ sudo mkswap /dev/vg_system/lv_swap + $ sudo mkfs.ext4 /dev/vg_system/lv_home </pre> <h2 id="step3">1.1.3. Prepare Install</h2> <p>From now on script - <a href="scripts/setup-install.sh">setup-install.sh</a> - create file systems, install packages, configure host - metadata and setup ports;</p> + <a href="scripts/setup-target.sh">setup-target.sh</a> + create file systems, <a href="scripts/install-core.sh">install-core.sh</a> install core packages and + <a href="scripts/setup-core.sh">setup-core.sh</a> + configure host metadata and setup ports;</p> - <p>Export target root partition;</p> + <p>Export target root partition;</p> - <pre> - $ export BLK_ROOT=/dev/sda - </pre> + <pre> + $ export BLK_ROOT=/dev/vg_system/lv_root + </pre> - <p>Export target root directory you want to install;</p> + <p>Export target root directory you want to install;</p> <pre> $ export CHROOT=/mnt </pre> - <p>If you are installing to a directory and not partitions you don't need to mount;</p> + <p>If you are installing to a directory and not partitions you don't need to mount;</p> <pre> $ sudo mount $BLK_ROOT $CHROOT @@ -191,11 +210,11 @@ $ sudo mkdir -p $CHROOT/tmp $ sudo mkdir -p $CHROOT/proc $ sudo mkdir -p $CHROOT/sys - </pre> + </pre> - <p>If partition layout is different or target is a directory is not necessary to mount, create only the directories;</p> + <p>If partition layout is different or target is a directory is not necessary to mount, create only the directories;</p> - <pre> + <pre> $ sudo mount $BLK_BOOT $CHROOT/boot $ sudo mkdir -p $CHROOT/boot/efi $ sudo mount $BLK_EFI $CHROOT/boot/efi @@ -296,6 +315,17 @@ pkgadd /usr/ports/packages/efivar#* pkgadd /usr/ports/packages/efibootmgr#* pkgadd /usr/ports/packages/dosfstools#* + pkgadd /usr/ports/packages/ported#* + pkgadd /usr/ports/packages/libgcrypt#* + pkgadd /usr/ports/packages/cryptsetup#* + pkgadd /usr/ports/packages/popt#* + pkgadd /usr/ports/packages/libgpg-error#* + pkgadd /usr/ports/packages/libevent#* + pkgadd /usr/ports/packages/libtirpc#* + pkgadd /usr/ports/packages/git#* + pkgadd /usr/ports/packages/tmux#* + pkgadd /usr/ports/packages/prt-utils#* + pkgadd /usr/ports/packages/elfutils#* </pre> <pre> @@ -343,7 +373,7 @@ <a href="index.html">Core OS Index</a> <p>This is part of the Hive System Documentation. - Copyright (C) 2018 + Copyright (C) 2019 Hive Team. See the file <a href="../fdl-1.3-standalone.html">Gnu Free Documentation License</a> for copying conditions.</p> |