Need help

2 posts / 0 new
Last post
#1 Sun, 2015-03-08 20:54
ParaDir
  • ParaDir's picture
  • Offline
  • Last seen: 3 years 2 weeks ago
  • Joined: 2015-03-05

Hello guys,

first of all, i want to say a big thanks to developers who are maintaing alpine!!!

But back to my problem. I'm trying to install alpine to my custom partitions, usually i'm doing those tasks with centos6-7 visual tools, when i'm installing centos. I want to have 3 partitions:

Number Start End Size Type File system Flags
1 512B 105MB 105MB primary ext4 boot
2 105MB 4400MB 4295MB primary linux-swap(v1)
3 4400MB 30000MB 25096MB primary btrfs

So with "parted" i can generate this, but i don't know what would be the next step? Can somebody help me?

I know, there is a article:
http://wiki.alpinelinux.org/wiki/Setting_up_disks_manually#Custom_partitioning

but i don't understand it, i have to mount all partitions on /mnt? and than run "setup-disk /mnt"?

I would appreciate your help.

Sat, 2015-03-14 20:23
Tiger
  • Tiger's picture
  • Offline
  • Last seen: 3 years 2 weeks ago
  • Joined: 2013-08-18

Custom setup of Alpine Linux is conveniently done from a running Alpine Live CD. Download the most recent Live CD from http://alpinelinux.org/ burn it to CD, boot the CD on your target system and login as root (no password required).

After partitioning the disk, you need to format each partition using

mkfs.ext4 {block_device}
mkswap {block_device}
mkfs.btrfs {block_device}

where block_device is the special file pointing to the partition, e.g. /dev/sda1. In order to create and use BTRFS partitions, you need to install the btrfs package with
apk add btrfs-progs

Then, create sub-folders in /mnt and mount the partitions

mkdir /mnt/root
mount {block_device_root} /mnt/root
mkdir  /mnt/root/boot
mount {block_device_boot} /mnt/root/boot

Install Alpine Linux using the standard disk installation script

setup-disk -v /mnt/root

In order to enable BTRFS support for the root partition during boot, you may have to add the corresponding kernel module btrfs to the kernel config line in /mnt/root/boot/extlinux.conf and, for the option to survive the next kernel update, to the key modules= in /mnt/root/etc/update-extlinux.conf.

Enjoy!

Log in or register to post comments