1

I've been trying to get unattended linux installs (fedora 28 in this case) working under KVM for some time. I've got it mostly worked out but it still asks me if I want to use text mode or fire up VNC. Here's a snippet to illustrate:

(snip)
[  OK  ] Listening on Open-iSCSI iscsid Socket.
[  OK  ] Reached target Sockets.
[  OK  ] Reached target Basic System.
[  OK  ] Started Hardware RNG Entropy Gatherer Daemon.
         Starting pre-anaconda logging service...
         Starting OpenSSH ed25519 Server Key Generation...
         Starting OpenSSH ecdsa Server Key Generation...
         Starting Login Service...
         Starting Hold until boot process finishes up...
         Starting OpenSSH rsa Server Key Generation...
[  OK  ] Started Hold until boot process finishes up.
[  OK  ] Started Terminate Plymouth Boot Screen.

Starting installer, one moment...
anaconda 28.22.10-1.fc28 for Fedora 28 started.
 * installation log files are stored in /tmp during the installation
 * shell is available on TTY2
 * when reporting a bug add logs from /tmp as separate text/plain attachments
15:12:21 X startup failed, falling back to text mode
15:12:21 X startup failed, falling back to text mode
================================================================================
================================================================================

1) Start VNC
2) Use text mode

Please make a selection from the above ['c' to continue, 'q' to quit, 'r' to
refresh]: 2
Starting automated install...
Generating updated storage configuration
Checking storage configuration...

================================================================================
================================================================================
Installation

1) [x] Language settings                 2) [x] Time settings
       (English (United States))                (America/Denver timezone)
3) [x] Installation source               4) [x] Software selection
       (https://mirror.chpc.utah.edu/pu         (Custom software selected)
       b/fedora/linux/releases/28/Serve
       r/x86_64/os/)
5) [x] Installation Destination          6) [x] Network configuration
       (Automatic partitioning                  (Wired (ens3) connected)
       selected)

================================================================================
================================================================================
Progress

.
Setting up the installation environment
.
Configuring storage
..
Creating disklabel on /dev/sda
Creating ext4 on /dev/sda1
Creating lvmpv on /dev/sda2
(snip)

I'm using this as my virt-install line:

virt-install  \
--name fedoratest2 \
--ram 2048 \
--disk path=/vm-images/fedoratest2.qcow2,size=15 \
--vcpus 2 \
--network bridge=br0 \
--mac=<insert unicast mac here> \
--graphics none \
--location https://mirror.chpc.utah.edu/pub/fedora/linux/releases/28/Server/x86_64/os/ \
--os-type linux \
--extra-args "console=ttyS0 inst.ks=http://http.mydomain.com/kickstart_fedora_testing.cfg hostname=fedoratest2.mydomain.com" 

(mydomain.com of course isn't my real domain)

And a kickstart of:

#ptform=x86, AMD64, or Intel EM64T
#version=DEVEL
# Keyboard layouts
keyboard 'us'
# Root password
rootpw --plaintext thisisnotmyrootpassword
# user is needed for fedora? --disabled isn't an option
user --name="joe" --password="thisisnotmyuserpassword"

# System language
lang en_US
# System timezone
timezone America/Denver
# Use graphical install
graphical
# System authorization information
auth  --useshadow  --passalgo=sha512
# Firewall configuration
firewall --disabled
# SELinux configuration
selinux --enforcing
# Do not configure the X Window System
skipx

# System bootloader configuration
bootloader --location=mbr
# Partition clearing information
clearpart --all
# Disk partitioning information
autopart --type lvm

# these are what were produced in anaconda_ks.cfg after I selected what I wanted during a non-kickstart install
%packages
@^server-product-environment
@headless-management
%end

# this was in default anaconda_ks.cfg file after non-kickstart install, figure I'll keep it just in case
%addon com_redhat_kdump --disable --reserve-mb='128'

%end

The thing that has me bugged are the lines that appear during bootup/setup:

15:12:21 X startup failed, falling back to text mode
15:12:21 X startup failed, falling back to text mode

and I wonder - why is it even trying to start X in the first place? I recognize that my boot params in --extra-args above aren't specifying that a text mode should be used or not, and as I understand it, fedora/anaconda wants to default to graphical installation mode. That's fine. I used the following two arguments in --extra-args as well to try and force it to text mode and not ask me anything:

inst.text
inst.cmdline

But neither of those seem to have any effect. It still complains that X startup failed and then asks me if I want to use VNC or text mode...

I'm trying these settings based on the official f28 install guide: https://docs.fedoraproject.org/en-US/fedora/f28/install-guide/advanced/Boot_Options/

Furthermore, the docs here for anaconda: https://anaconda-installer.readthedocs.io/en/latest/boot-options.html

state that console= implies inst.txt... I'm baffled.

Summary:

No matter what I've tried to specify that I want a text or cmdline only install (no graphical), the installer still tries to run graphical, fails miserably, and prompts me to specify either VNC or text mode. I'm trying to find out what I'm doing wrong or if it's even possible to get it to not prompt me for ANYTHING during install and just ride off of the kickstart file.

  • I don't understand why you are keeping the keyword graphical in the kickstart file, instead of replacing it by text. Perhaps you can also try inst.noninteractive – meuh Aug 29 '18 at 8:28
1

You're getting an attempt at a graphical install because your kickstart file explicitly asked for it:

# Use graphical install
graphical

The errors state that the graphical installer is failing to start, which is why you're being prompted about whether you want to continue with VNC.

Since you say you want a text-based install anyway, remove graphical and replace it with text.

  • Well bust my buttons, I'm betting you're right. I'll test it as soon as I can, thanks. I can't believe I missed that. So embarrassing. -_- – scooterx3 Aug 29 '18 at 23:12
  • Yep, that did it. Thanks! Note to self: read better. – scooterx3 Aug 29 '18 at 23:19

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.