I have started to create my own archiso because installing arch is fun, but automating it is even funnier ;-).

Before actually using it on my computer to do a fresh installation, I'm testing it on virtual box.

It's clearly a work in progress, but the source files can be found here: https://gitlab.com/neopium/archlinux

This is not supposed to be generic, it's only supposed to work on my computer. For instance, I want my system in GB English, but I use an azerty French keyboard and this is hardcoded because it's probably not going to change in my setup.

So, I have mainly two scripts that I have customized.

The first one, is https://gitlab.com/neopium/archlinux/blob/master/archlive/airootfs/root/customize_airootfs.sh.

It is used to create the ISO itself. Nothing fancy, really.

The second one is more interesting: it's the script that I'm executing to automatically install my minimal setup when running the live ISO: https://gitlab.com/neopium/archlinux/blob/master/archlive/airootfs/root/install-arch.sh

Again, it's a work in progress. Some things are still hardcoded. For instance, it assumes the partitions are already created, /boot is on /dev/sda1 and / is on /dev/sda2.

Be careful if you want to use this script, it formats the /dev/sda1 and /dev/sda2 partitions!

I retrieve the hostname, user name and password, format the disk, install some basic packages (the list is not fixed yet), install grub, set the locale and time zone, create the user and add it to the sudoers and finally activate internet.

Here is the command that installs the packages:

pacstrap -i /mnt base base-devel git curl wget openssh zsh zsh-completions networkmanager btrfs-progs ntfs-3g grub \
    os-prober xorg xorg-xinit xorg-apps xf86-video-fbdev mesa bspwm sxhkd xf86-video-intel xf86-input-synaptics nvidia \
    nvidia-utils lib32-nvidia-utils kitty rofi neovim alsa-utils pulseaudio dunst

I also have a third script that installs packages that are only relevant to virtual box: https://gitlab.com/neopium/archlinux/blob/master/archlive/airootfs/root/additional-virtualbox.sh

arch-chroot /mnt pacman -S virtualbox-guest-modules-arch
arch-chroot /mnt pacman -S virtualbox-guest-utils

Then I restart my virtualbox, login with my user account. But when I type startx, it doesn't work.

Here is the Xorg.0.log file: https://pastebin.com/raw/4RmxbDN8

I guess I missed a step in the installation/configuration of xorg, but I don't know which one.

I have two error messages:

(EE) Failed to load module "vboxvideo" (module does not exist, 0)
(EE) modeset(0): glamor initialization failed

FYI, I have cross posted this question on archlinux forum, but after thinking about it, my issue might not be a arch-specific problem, but more a virtual box / xorg related. I will update both posts if necessary.


I have realized my virtualbox additions was not properly configured, so on the host, I ran:

sudo systemctl enable vboxservice.service
sudo systemctl restart vboxservice.service

Executing lsmod gives:

Module                  Size  Used by
vboxsf                 40960  0
intel_powerclamp       20480  0
vboxvideo              40960  1
crct10dif_pclmul       16384  1
crc32_pclmul           16384  0
ttm                   114688  1 vboxvideo
ghash_clmulni_intel    16384  0
aesni_intel           372736  0
drm_kms_helper        208896  1 vboxvideo
aes_x86_64             20480  1 aesni_intel
snd_intel8x0           49152  0
crypto_simd            16384  1 aesni_intel
cryptd                 28672  3 crypto_simd,ghash_clmulni_intel,aesni_intel
glue_helper            16384  1 aesni_intel
drm                   499712  4 drm_kms_helper,vboxvideo,ttm
snd_ac97_codec        151552  1 snd_intel8x0
ac97_bus               16384  1 snd_ac97_codec
intel_rapl_perf        16384  0
snd_pcm               135168  2 snd_intel8x0,snd_ac97_codec
psmouse               172032  0
joydev                 28672  0
mousedev               24576  0
pcspkr                 16384  0
input_leds             16384  0
snd_timer              40960  1 snd_pcm
snd                   102400  4 snd_intel8x0,snd_timer,snd_ac97_codec,snd_pcm
intel_agp              24576  0
syscopyarea            16384  1 drm_kms_helper
sysfillrect            16384  1 drm_kms_helper
evdev                  24576  3
intel_gtt              24576  1 intel_agp
ac                     16384  0
mac_hid                16384  0
agpgart                53248  4 intel_agp,intel_gtt,ttm,drm
sysimgblt              16384  1 drm_kms_helper
soundcore              16384  1 snd
fb_sys_fops            16384  1 drm_kms_helper
vboxguest              45056  2 vboxsf
i2c_piix4              28672  0
ip_tables              32768  0
x_tables               49152  1 ip_tables
ext4                  749568  1
hid_generic            16384  0
crc32c_generic         16384  0
crc16                  16384  1 ext4
mbcache                16384  1 ext4
jbd2                  131072  1 ext4

Also on the xorg side, I did not have a xorg.conf file in /etc/X11. So I created one with:

Xorg :1 -configure

X still does not start, but the errors are not the same: https://pastebin.com/raw/e8FwRbVf

vbox% grep "(EE)" .local/share/xorg/Xorg.0.log 
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    41.117] (EE) modeset(0): glamor initialization failed

vbox% grep "(WW)" .local/share/xorg/Xorg.0.log 
[    40.566] (WW) Failed to open protocol names file lib/xorg/protocol.txt
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    40.591] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/misc".
[    40.591] (WW) The directory "/usr/share/fonts/TTF" does not exist.
[    40.591] (WW) The directory "/usr/share/fonts/OTF" does not exist.
[    40.591] (WW) The directory "/usr/share/fonts/Type1" does not exist.
[    40.594] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/misc".
[    40.594] (WW) The directory "/usr/share/fonts/TTF" does not exist.
[    40.594] (WW) The directory "/usr/share/fonts/OTF" does not exist.
[    40.594] (WW) The directory "/usr/share/fonts/Type1" does not exist.
[    40.594] (WW) Hotplugging is on, devices using drivers 'kbd', 'mouse' or 'vmmouse' will be disabled.
[    40.594] (WW) Disabling Mouse0
[    40.594] (WW) Disabling Keyboard0
[    40.601] (WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)
[    40.629] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
  • Why are you installing Nvidia tools on a VM that's running inside VirtualBox? Why aren't you installing the VirtualBox tools? – roaima May 3 '19 at 6:57
  • In the end, I want my script to run on an actual computer. Mine has an Nvidia card. In the additional script, I install virtual box tools – Ben May 3 '19 at 6:59
  • Your title clearly refers to X in VirtualBox. If that's not what you want, please edit your question to make it clear. – roaima May 3 '19 at 7:19
  • This is what I want. I want to test it on virtual box and X does not start. Next step is to make it work on actual hardware, but that's not gonna happen if I don't figure out how to do it in a testing environment first, because I want to test my default WM configuration. It's still a work in progress and I haven't implemented all the WM customization, I'm trying to do things step by step: first making X work, then customizing the WM. Once everything is tested, I go to HW installation. – Ben May 3 '19 at 7:24
  • OK. Modified first question stands then. Why aren't you installing the VirtualBox tools alongside the NVidia ones? – roaima May 3 '19 at 7:30

My bad.

Actually, X works.

The problem is: it has nothing to do. So it does nothing and closes.

I installed lightdm and now I see the login screen as expected. And when I log in, the WM starts.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.