You are not logged in.

#1 2013-03-18 11:42:37

Bazzaah
Member
Registered: 2010-03-15
Posts: 69

[SOLVED] error with mkinitcpio during installation

Hi there

I am looking to install Arch after I broke a previous installation

I put this basic set of commands after reading the Installation Guide and I run it from in the live /root. 

#!/bin/bash
loadkeys uk
mkfs -t ext4 /dev/sda7
mkfs -t ext4 /dev/sda8
mkswap -f /dev/sda6
mkdir /mnt/root
mkdir /mnt/home
mount /dev/sda7 /mnt/root
mount /dev/sda8 /mnt/home
pacstrap /mnt/root base base-devel
genfstab -p /mnt >> /mnt/root/etc/fstab
arch-chroot /mnt
ln -s /usr/share/zoneinfo/Europe/London /etc/localtime
nano /etc/locale.conf
locale-gen
mkinitcpio -p linux 
passwd root

If I run this script, there's some kind of problem with mkinitcpio and /boot is empty. It worked a month or so ago - maybe it's content in the new .iso? A misplaced /mnt or /mnt/root?

Any ideas? I've never failed to install distro properly and am a bit confused!

Thanks in advance

EDIT

I changed the script to this

loadkeys uk
cfdisk
mkfs -t ext4 /dev/sda7
mkfs -t ext4 /dev/sda8
mkswap -f /dev/sda6
mkdir /mnt/root
mkdir /mnt/home
mkdir /mnt/storage
mount /dev/sda7 /mnt/root
mount /dev/sda8 /mnt/home
mount /dev/sdb1 /mnt/storage
pacstrap /mnt/root base base-devel
genfstab -p /mnt/root >> /mnt/root/etc/fstab
arch-chroot /mnt/root
ln -s /usr/share/zoneinfo/Europe/London /etc/localtime
nano /etc/locale.conf
locale-gen
mkinitcpio -p linux 
passwd root
exit

will see if that helps

Last edited by Bazzaah (2013-03-18 19:26:29)

Offline

#2 2013-03-18 12:05:37

s1ln7m4s7r
Member
Registered: 2013-02-22
Posts: 262

Re: [SOLVED] error with mkinitcpio during installation

The second script will work on creating a somewhat functional system.

Just one question, why are you placing your other mounts

mount /dev/sda8 /mnt/home
mount /dev/sdb1 /mnt/storage

outside your root mount-point.

These mount-points won't be included in your system, they should be

mount /dev/sda8 /mnt/root/home
mount /dev/sdb1 /mnt/root/storage

Last edited by s1ln7m4s7r (2013-03-18 12:12:35)

Offline

#3 2013-03-18 13:43:06

Bazzaah
Member
Registered: 2010-03-15
Posts: 69

Re: [SOLVED] error with mkinitcpio during installation

Great, thanks for your help, much appreciated.

I do indeed have a functional system (basic of course) but what concerns me is that I get a not found error after mkinitcpio - the system boots so the kernel and initrd must be there...still that error message worries me a bit.

Offline

#4 2013-03-18 13:50:05

s1ln7m4s7r
Member
Registered: 2013-02-22
Posts: 262

Re: [SOLVED] error with mkinitcpio during installation

Bazzaah wrote:

Great, thanks for your help, much appreciated.

I do indeed have a functional system (basic of course) but what concerns me is that I get a not found error after mkinitcpio - the system boots so the kernel and initrd must be there...still that error message worries me a bit.

About that error, you need to post it, if you want help!

Edit: If you are running those commands in a file, make it look like this:

loadkeys uk
cfdisk
mkfs.ext4 /dev/sda7
mkfs.ext4 /dev/sda8
mkswap -f /dev/sda6
mkdir /mnt/root
mkdir /mnt/root/home
mkdir /mnt/root/storage
mount /dev/sda7 /mnt/root
mount /dev/sda8 /mnt/root/home
mount /dev/sdb1 /mnt/root/storage
pacstrap /mnt/root base base-devel
genfstab -U -p /mnt/root > /mnt/root/etc/fstab
arch-chroot /mnt/root /bin/bash -c "ln -s /usr/share/zoneinfo/Europe/London /etc/localtime"
arch-chroot /mnt/root /bin/bash -c "nano /etc/locale.conf"
arch-chroot /mnt/root /bin/bash -c "locale-gen"
arch-chroot /mnt/root /bin/bash -c "mkinitcpio -p linux"
arch-chroot /mnt/root /bin/bash -c "passwd root"

The lines with "arch-chroot /mnt/root /bin/bash -c" are needed to run those inside the chroot environment, or else they will run in your live system, instead of making changes to your created system.

Last edited by s1ln7m4s7r (2013-03-18 17:46:26)

Offline

#5 2013-03-18 14:08:06

Bazzaah
Member
Registered: 2010-03-15
Posts: 69

Re: [SOLVED] error with mkinitcpio during installation

Yep - I don't seem to have a log that covers the installation process.

It said that there was no initrd and before I ran the second script it said there was no kernel as well.

I'll reinstall a bit later and make a proper note of the error.

Offline

#6 2013-03-18 14:18:15

Trilby
Forum Moderator
From: Massachusetts, USA
Registered: 2011-11-29
Posts: 14,052
Website

Re: [SOLVED] error with mkinitcpio during installation

Are you actually running those as a script?  Or are you just doing those commands in order?

If running it as a script, this is the expected result.  You need to run all those commands after arch-chroot within the chroot environment.  As written, they'll execute within the live environment only after the chroot exits because it has nothing to do.


InterrobangSlider
• How's my coding? See this page.
• How's my moderating? Feel free to email any concerns, complaints, or objections.

Offline

#7 2013-03-18 19:25:01

Bazzaah
Member
Registered: 2010-03-15
Posts: 69

Re: [SOLVED] error with mkinitcpio during installation

Thanks for the help - my scripting skills are close to zero, it seems!

Anyway, all sorted.

Thanks again for your help both of you, much appreciated

Offline

Board footer

Powered by FluxBB