Hi Everybody,
I am trying to install cPanel Unattended to CentOS 7.
Centos6 can also install without problems, but centos 6 support will be finished
My kickstart installation script is;
------------------------------------------
The error I received at installation;
How to Unattended Installation cPanel on CentOS7 with Kickstart
I am trying to install cPanel Unattended to CentOS 7.
Centos6 can also install without problems, but centos 6 support will be finished
My kickstart installation script is;
Code:
------------------------------------------
##################Kickstart Begin
# Run the installer
install
# Run the text install
text
# Network configuration
network --device eth0 --onboot=yes --bootproto=static --ip=192.168.2.200 --netmask=255.255.255.0 --gateway=192.168.2.1 --nameserver=192.168.2.1,8.8.8.8
# Use URL installation media
url --url="Index of /centos/7.6.1810/os/x86_64"
# Root password
rootpw --plaintext 123a456A
# Firewall Options
firewall --disabled
# Selinux Options
selinux --disabled
# System authorization information
authconfig --enableshadow --enablemd5
# System language
lang en_US.UTF-8
# Keyboard layouts
keyboard us
# System timezone
timezone Europe/Istanbul
# Skip X config
skipx
# Overwrite the MBR
zerombr
# Partition clearing information
clearpart --all --initlabel --drives=vda
# System bootloader configuration
bootloader --location=mbr --driveorder=vda
################## PARTITIONING LVM
part /boot --fstype ext4 --size=500
part swap --fstype="swap" --recommended
part pv.01 --size=1024 --grow --ondisk=vda
volgroup vg00 pv.01
logvol / --vgname=vg00 --fstype=ext4 --size=2048 --grow --name=lv_root
logvol /tmp --vgname=vg00 --fstype=ext4 --size=512 --name=lv_tmp
# Do not run the Setup Agent on first boot
firstboot --disabled
# Logging only information
logging info
# Reboot the system when the install is complete
reboot
################## Packages
%packages --ignoremissing --excludedocs
@base
wget
%end
################## Post Configuration - Output /tmp/ks-post.log
%post --log=/tmp/ks-post-removable.log
echo -e "NETWORKING=yes\nHOSTNAME=sr01.emirsah.com\nGATEWAY=192.168.2.1" > /etc/sysconfig/network
echo -e "nameserver 192.168.2.1\nameserver 8.8.8.8" > /etc/resolv.conf
echo -e "sr01.emirsah.com" > /etc/hostname
echo -e "127.0.0.1\tlocalhost localhost.localdomain\n192.168.2.200\tsr01.emirsah.com" > /etc/hosts
yum update -y && yum upgrade -y ""
systemctl stop NetworkManager.service && systemctl disable NetworkManager.service ""
cd /home && wget https://securedownloads.cpanel.net/latest ""
chmod +x latest && sh latest ""
%end
The error I received at installation;
Code:
[2019-04-24 16:41:53 +0300] Verifying : mysql-community-common-5.7.25-1.el7.x86_64 2/6
[2019-04-24 16:41:53 +0300] Verifying : mysql-community-server-5.7.25-1.el7.x86_64 3/6
[2019-04-24 16:41:53 +0300] Verifying : mysql-community-devel-5.7.25-1.el7.x86_64 4/6
[2019-04-24 16:41:53 +0300] Verifying : mysql-community-client-5.7.25-1.el7.x86_64 5/6
[2019-04-24 16:41:53 +0300] Verifying : mysql-community-libs-compat-5.7.25-1.el7.x86_64 6/6
[2019-04-24 16:41:54 +0300]
[2019-04-24 16:41:54 +0300] Complete!
[2019-04-24 16:41:54 +0300] Mysql installed from official repository.
[2019-04-24 16:41:54 +0300] Building configuration.
[2019-04-24 16:41:54 +0300] This step may produce some errors or warnings in the log. The errors are usually harmless and are a result of table changes between versions of MySQL or MariaDB.
[2019-04-24 16:41:54 +0300] Running: /usr/local/cpanel/bin/build_mysql_conf
[2019-04-24 16:41:54 +0300] The mysql.user table is missing, mysql_install_db will be called to recreate it.
[2019-04-24 16:42:42 +0300] Waiting for “mysql” to start ……………failed.
[2019-04-24 16:42:42 +0300] Waiting for “mysql” to start …………mysql has failed. Contact your system administrator if the service does not automagically recover.
[2019-04-24 16:42:52 +0300] Waiting for “mysql” to start …………Running /usr/local/cpanel/scripts/mysqlconnectioncheck.
[2019-04-24 16:42:52 +0300] Waiting for “mysql” to start …………Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/RestartSrv/Systemd.pm line 81.
[2019-04-24 16:42:52 +0300] Waiting for “mysql” to start …………
[2019-04-24 16:42:52 +0300] Done building configuration.
[2019-04-24 16:42:52 +0300] Hooks system enabled.
[2019-04-24 16:42:52 +0300] Checking for and running RPM::Versions 'post' hooks for any RPMs about to be installed
[2019-04-24 16:42:52 +0300] All required 'post' hooks have been run
[2019-04-24 16:42:52 +0300] Running: /usr/local/cpanel/scripts/check_cpanel_rpms --targets=MySQL41,MySQL50,MySQL51,MySQL55,MySQL56,MySQL57,MariaDB100,MariaDB101,MariaDB102,MariaDB103 --fix
Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/RestartSrv/Systemd.pm line 81.
Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/RestartSrv/Systemd.pm line 81.
Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/ServiceManager/Base.pm line 1210.
Waiting for “mysql” to start ………Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/RestartSrv/Systemd.pm line 81.
Running in chroot, ignoring request.
…Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/RestartSrv/Systemd.pm line 81.
Running in chroot, ignoring request.
…failed.
Cpanel::Exception::Services::StartError
Service Status
Service Error
(XID 6tvfqw) The “mysql” service failed to start.
Use of uninitialized value in string eq at /usr/local/cpanel/Cpanel/RestartSrv/Systemd.pm line 81.
Running in chroot, ignoring request.
mysql has failed. Contact your system administrator if the service does not automagically recover.
2019-04-24 16:43:41 333 [15261] (FATAL): The system failed to run the /usr/local/cpanel/scripts/cpanel_initial_install script.
How to Unattended Installation cPanel on CentOS7 with Kickstart
Last edited by a moderator: