VirtualBox

Changeset 71018 in vbox


Ignore:
Timestamp:
Feb 14, 2018 6:42:52 PM (7 years ago)
Author:
vboxsync
Message:

Main,Installer: Made unattended installation work for rhel3 and friends.

Location:
trunk/src/VBox
Files:
4 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/Config.kmk

    r71011 r71018  
    6363        fedora_ks.cfg \
    6464        ol_ks.cfg \
     65        rhel3_ks.cfg \
     66        rhel4_ks.cfg \
     67        rhel5_ks.cfg \
    6568        redhat67_ks.cfg \
    66         rhel5_ks.cfg \
    67         rhel4_ks.cfg \
    6869        win_nt5_unattended.sif \
    6970        win_nt6_unattended.xml \
  • trunk/src/VBox/Main/UnattendedTemplates/Makefile.kmk

    r71011 r71018  
    2929        debian_preseed.cfg \
    3030        ubuntu_preseed.cfg \
     31        rhel3_ks.cfg \
     32        rhel4_ks.cfg \
     33        rhel5_ks.cfg \
    3134        redhat67_ks.cfg \
    32         rhel5_ks.cfg \
    33         rhel4_ks.cfg \
    3435        ol_ks.cfg \
    3536        fedora_ks.cfg \
  • trunk/src/VBox/Main/UnattendedTemplates/rhel3_ks.cfg

    r71011 r71018  
    1 # Template for RHEL5 and derivatives.
    2 #platform=x86, AMD64, or Intel EM64T
    3 #version=DEVEL
     1#
     2# Template for RHEL3 and derivatives.
     3#
     4# Note! RHEL3 kickstart typically just hangs if it finds something it doesn't like.
     5#       So, all changes to this file must be tested!
     6#
     7# N.B! AHCI is not supported by RHEL3
     8#
     9
     10# Use text mode install
     11text
     12
     13# Install OS instead of upgrade
     14install
     15
     16# System language
     17lang @@VBOX_INSERT_LOCALE@@.UTF-8
     18
     19# rhel4+rhel3 needs:
     20langsupport --default @@VBOX_INSERT_LOCALE@@.UTF-8 @@VBOX_INSERT_LOCALE@@.UTF-8
     21
     22# Use CDROM installation media
     23cdrom
     24
     25# System authorization information (rhel5: no --passalgo=sha512)
     26#auth  --useshadow
     27authconfig --enableshadow --enablemd5
     28
     29# Root password (rhel5 not --plaintext groks)
     30rootpw @@VBOX_INSERT_ROOT_PASSWORD_SH@@
     31
     32# Network information
     33# rhel3: doesn't like --onboot=on.
     34network  --bootproto=dhcp --device=eth0 --hostname=@@VBOX_INSERT_HOSTNAME_FQDN_SH@@
    435
    536# Firewall configuration
    637firewall --disabled
    738
    8 # Install OS instead of upgrade
    9 install
    10 
    11 # Use CDROM installation media
    12 cdrom
    13 
    14 # Root password (rhel5 not --plaintext groks)
    15 rootpw @@VBOX_INSERT_ROOT_PASSWORD_SH@@
    16 
    17 # System authorization information (rhel5: no --passalgo=sha512)
    18 auth  --useshadow
    19 
    20 # Use text mode install
    21 text
    22 
    2339# System keyboard
    2440keyboard us
    2541
    26 # System language
    27 lang @@VBOX_INSERT_LOCALE@@
    28 # rhel4 needs:
    29 langsupport --default=@@VBOX_INSERT_LOCALE@@.UTF-8 @@VBOX_INSERT_LOCALE@@.UTF-8
    30 
     42# rhel3 wants mouse config.
     43mouse genericwheelps/2 --device psaux
    3144
    3245# SELinux configuration
    33 selinux --enforcing
     46# rhel3: disable selinux
     47# selinux --enforcing
    3448
    3549# Installation logging level
     
    3852# System timezone
    3953timezone@@VBOX_COND_IS_RTC_USING_UTC@@ --utc@@VBOX_COND_END@@ @@VBOX_INSERT_TIME_ZONE_UX@@
    40 
    41 # Network information
    42 network  --bootproto=dhcp --device=eth0 --onboot=on --hostname=@@VBOX_INSERT_HOSTNAME_FQDN_SH@@
    4354
    4455# System bootloader configuration
     
    6273# Packages.  We currently ignore missing packages/groups here to keep things simpler.
    6374%packages --ignoremissing
     75grub
     76kernel
    6477@ base
    6578@ core
     
    8497
    8598# Prepare building the additions kernel module, try get what we can from the cdrom as it may be impossible
    86 # to install anything from the post script:
     99# to install anything from the post script (rhel3 seems to need kernel-sources):
     100kernel-source
    87101kernel-headers
    88102kernel-devel
     
    110124# rhel5: There is not /bin/bash, so use /bin/sh
    111125# rhel5: There is no /dev/cdrom, so try use /dev/hdc and /dev/sdb.
    112 %post --nochroot --log=/mnt/sysimage/root/ks-post.log
    113 df -h 1>&2
     126# rhel3: no --log option
     127%post --nochroot
     128df -h
    114129cp /tmp/vboxcdrom/vboxpostinstall.sh /mnt/sysimage/root/vboxpostinstall.sh
    115130chmod a+x /mnt/sysimage/root/vboxpostinstall.sh
  • trunk/src/VBox/Main/include/UnattendedInstaller.h

    r71011 r71018  
    528528
    529529/**
    530  * RHEL 5 installer (same as RHEL 6 & 7, except for the kickstart template).
     530 * RHEL 4 installer (same as RHEL 6 & 7, except for the kickstart template).
    531531 */
    532532class UnattendedRhel4Installer : public UnattendedRhel6And7Installer
     
    535535    UnattendedRhel4Installer(Unattended *pParent) : UnattendedRhel6And7Installer(pParent, "rhel4_ks.cfg") {}
    536536    ~UnattendedRhel4Installer() {}
     537};
     538
     539
     540/**
     541 * RHEL 3 installer (same as RHEL 6 & 7, except for the kickstart template).
     542 */
     543class UnattendedRhel3Installer : public UnattendedRhel6And7Installer
     544{
     545public:
     546    UnattendedRhel3Installer(Unattended *pParent) : UnattendedRhel6And7Installer(pParent, "rhel3_ks.cfg") {}
     547    ~UnattendedRhel3Installer() {}
    537548};
    538549
  • trunk/src/VBox/Main/src-server/UnattendedInstaller.cpp

    r71011 r71018  
    8181            else if (RTStrVersionCompare(strDetectedOSVersion.c_str(), "4") >= 0)
    8282                pUinstaller = new UnattendedRhel4Installer(pParent);
     83            else if (RTStrVersionCompare(strDetectedOSVersion.c_str(), "3") >= 0)
     84                pUinstaller = new UnattendedRhel3Installer(pParent);
    8385            else
    8486                pUinstaller = new UnattendedRhel6And7Installer(pParent);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette