Join the community today
Register Now

Featured CentOS 7.x How to help test .08 CentOS 7 Betas with Github code ?

Discussion in 'Beta release code' started by eva2000, Jul 11, 2014.

  1. Josephm

    Josephm Active Member

    132
    44
    28
    Aug 26, 2014
    Ratings:
    +48
    Local Time:
    2:41 AM
    1.9.5
    10.0.21
    I tested Centos 6.5 with stable script and everything is good at turnkey cloud. Seems we have more thing to make centminmod beta compatible in centos 7...

     
  2. Andy

    Andy Active Member

    540
    89
    28
    Aug 6, 2014
    Ratings:
    +132
    Local Time:
    2:41 PM
    Got same issue on Linode and DigitalOcean centos 7 and latest centminmod beta 8.
    I didn't have this problem before so I suspect this may be related to some nginx changes that George made to the code.

    Weird enough, this issue only appears on brand new server that we install from centminmod menu 1. I have 2 existing server that use latest beta 8 code without issue with updating nginx, etc.
     
  3. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    would need the santised initial install log via gist or pastebin as per How to troubleshoot Centmin Mod initial install issues to further diagnose the problem
     
  4. Andy

    Andy Active Member

    540
    89
    28
    Aug 6, 2014
    Ratings:
    +132
    Local Time:
    2:41 PM
  5. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    ah might need to reverse i change i did in nginx.conf changing it back

    from
    Code:
    pid        nginx.pid;
    to
    Code:
    pid         logs/nginx.pid;
    run command to kill all nginx processes before restarting with nginx.conf changes
    Code:
    kill -9 $(pidof nginx)
     
  6. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
  7. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Might want to santise and filter out passwords in the log at very bottom of log too as per How to troubleshoot Centmin Mod initial install issues | Centmin Mod Community

    i see the error with CSF Firewall,

    Code:
    [1;33;40m--------------------------------------------------------
    (B[m[1;33;40mCheck CSF Firewall Version:
    (B[m[1;33;40m--------------------------------------------------------
    (B[mYou have an unresolved error when starting csf:
    Error: IPSET: [ipset v6.19: Cannot open session to kernel.], at line 4363 in /usr/sbin/csf
    
    You need to restart csf successfully to remove this warning, or delete /etc/csf/csf.error
    are you using VPS ? what type OpenVZ, KVM, Xen, VMware ?

    made a fix in latest .08 beta at fix CSF firewall IPSET check for non-OpenVZ systems only · 1995994 · centminmod/centminmod · GitHub as missing OpenVZ check..

    so only if you use OpenVZ VPS should disable IPSET in CSF Firewall using commands below

    Code:
    rm -rf /etc/csf/csf.error
    sed -i 's/LF_IPSET = "1"/LF_IPSET = "0"/g' /etc/csf/csf.conf
    csf -r
    
     
    Last edited: Dec 15, 2014
  8. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    Hi, thanks for replying. I'm afraid it's already 'sanitized'(?) - I've changed the password to random characters manually - they do not reflect real values.

    Indeed, I am using OpenVZ. and running your suggested commands seemed to have fixed it. Will future centminmod autoinstaller script on openvz vps require running the commands too?
     
  9. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
  10. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    Oh sorry, because commit was named for non-OpenVZ systems - it confused me

    Anwyay, I wiped test VPS and re-run

    Code:
    curl -sL https://gist.github.com/centminmod/dbe765784e03bc4b0d40/raw/installer.sh | bash
    I still get that same csf error. Even after running your commands, once the vps is rebooted, it becomes inaccesible, and the only way to access it again is to rebuild the vm. Wondering what's going on :(
     
  11. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    what does commands output
    Code:
    grep LF_IPSET /etc/csf/csf.conf
    yum -q list ipset*
     
  12. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    $ grep LF_IPSET /etc/csf/csf.conf
    LF_IPSET = "1"

    $ yum -q list ipset*
    Installed Packages
    ipset.x86_64 6.19-4.el7 @base
    ipset-devel.x86_64 6.19-4.el7 @base
    ipset-libs.x86_64 6.19-4.el7 @base
     
  13. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    so for some reason LF_IPSET is still set to 1 for OpenVZ systems... i use /proc/user_beancounters to determine if OpenVZ is used.. do you have that file ?

    Code:
    ls -lah /proc/user_beancounters
    -r-------- 1 root root 0 Dec 15 08:00 /proc/user_beancounters
     
  14. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    Yes I do.

    Code:
    [root@dallas ~]# ls -lah /proc/user_beancounters
    -r-------- 1 nginx root 0 Dec 15 13:02 /proc/user_beancounters
    [root@dallas ~]# cd /proc/
    [root@dallas proc]# ls -a
    .   1    122  18756  21844  21847  21861  22184  22521  28464  29528  3    359  4419  cgroups  cpuinfo  fairsched   filesystems  kmsg     locks    modules  net         self  swaps  sysrq-trigger  uptime             version  vz
    ..  109  125  2      21846  21860  21872  22238  28395  29527  29529  350  363  63    cmdline  devices  fairsched2  fs           loadavg  meminfo  mounts   partitions  stat  sys    sysvipc        user_beancounters  vmstat
    
    For info also, here is centos version / kernel

    Code:
    [root@dallas proc]# cat /etc/*-release
    1.2.3-eva2000.08
    CentOS Linux release 7.0.1406 (Core)
    NAME="CentOS Linux"
    VERSION="7 (Core)"
    ID="centos"
    ID_LIKE="rhel fedora"
    VERSION_ID="7"
    PRETTY_NAME="CentOS Linux 7 (Core)"
    ANSI_COLOR="0;31"
    CPE_NAME="cpe:/o:centos:centos:7"
    HOME_URL="https://www.centos.org/"
    BUG_REPORT_URL="https://bugs.centos.org/"
    
    CentOS Linux release 7.0.1406 (Core)
    CentOS Linux release 7.0.1406 (Core)
    
    [root@dallas proc]# uname -a
    Linux dallas.jarylwang.com 2.6.32-042stab094.7 #1 SMP Wed Oct 22 12:43:21 MSK 2014 x86_64 x86_64 x86_64 GNU/Linux
    
    [root@dallas proc]# cat /proc/version
    Linux version 2.6.32-042stab094.7 (root@kbuild-rh6-x64) (gcc version 4.4.6 20120305 (Red Hat 4.4.6-4) (GCC) ) #1 SMP Wed Oct 22 12:43:21 MSK 2014
    
     
  15. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
  16. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    Code:
    selinxcheck() {
            # check if selinux is disabled, if not abort and prompt to reboot
            if [[ -z $(sestatus | grep disabled) && -f /etc/selinux/config ]]; then
                    echo "---------------------------------------------------------------"
                    echo "SELINUX linux detected"
                    echo "---------------------------------------------------------------"
                    echo "disabling SELINUX..."
                    echo "will require a server reboot before running initial install"
                    sleep 3
                    sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config && setenforce 0
                    sed -i 's/SELINUX=permissive/SELINUX=disabled/g' /etc/selinux/config && setenforce 0
                    echo
                    echo "SELINUX disabled, please reboot server and rerun install"
                    echo "on reboot you can find the centmin.sh file located at:"
                    echo "echo $(pwd)"
                    echo "---------------------------------------------------------------"
                    exit 0
            fi
    }
    
    centaltoff() {
            if [[ -f /etc/yum.repos.d/centalt.repo ]]; then
                    sed -i 's/enabled=1/enabled=0/g' /etc/yum.repos.d/centalt.repo
                    yum clean all -q
            fi
    }
    
    csfipsetcheck() {
            if [ ! -f /proc/user_beancounters ]; then
            if [[ ! -f /usr/sbin/ipset || ! -f /usr/include/libipset/data.h ]]; then
                    yum -y -q install ipset ipset-devel
                    sed -i 's/LF_IPSET = "0"/LF_IPSET = "1"/g' /etc/csf/csf.conf
            fi
            fi
    }
    
    cpcheck() {
    
    if [ -f /var/cpanel/cpanel.config ]; then
    echo "WHM/Cpanel detected.. centmin mod NOT compatible"
    echo "aborting script..."
    exit
    fi
    
    if [ -f /etc/psa/.psa.shadow ]; then
    echo "Plesk detected.. centmin mod NOT compatible"
    echo "aborting script..."
    exit
    fi
    
    if [ -f /etc/init.d/directadmin ]; then
    echo "DirectAdmin detected.. centmin mod NOT compatible"
    echo "aborting script..."
    exit
    fi
    
    selinxcheck
    centaltoff
    csfipsetcheck
    
    }
    
    Apparently it does.
     
  17. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    That suggests you do not have the updated .08 beta code - you missing the csfipsetcheck function seen here in lines 28-35 and line 59 at centminmod/cpcheck.inc at 1995994ec936f05b3695ea5ba84a54c391022f4c · centminmod/centminmod · GitHub

    I've updated .08 beta for further changes see detection improvements for OpenVZ systems and IPSET disabling · 4b5d5d5 · centminmod/centminmod · GitHub

    so suggest you use latest .08 beta code and after download zip AND before running verify if inc/cpcheck.inc and inc/csfinstall.inc have the right contents as per centminmod/cpcheck.inc at 4b5d5d5a2404e621b68dc8e7193ebb59a8093114 · centminmod/centminmod · GitHub and centminmod/csftweaks.inc at 4b5d5d5a2404e621b68dc8e7193ebb59a8093114 · centminmod/centminmod · GitHub
     
  18. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    I actually checked the file on wrong vps , I've since edited my post, I did have the appropriate lines.

    I will rebuild the VPS again and try. I actually ran the one click installer.sh. I will download , untar and verify before running ./centmin.sh instead.

    Still, even with LF_IPSET=0 set manually, something is borked, and the vps reboot will not allow any sort of connection to the ip address (ping returns no result too).

    EDIT: I mean nothing runs on the VPS after reboot after initial centminmod install (I believe so), since the control panel reflect ram usage at 18 MB :'(
     
    Last edited: Dec 15, 2014
  19. eva2000

    eva2000 Administrator Staff Member

    53,488
    12,130
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,671
    Local Time:
    5:41 AM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    strange

    try the same installer but with CentOS 6.6 and see.. could be specific to CentOS 7.0 + OpenVZ - a combination I haven't tested yet as all my CentOS 7.0 tests are with Xen or KVM VPS
     
  20. JarylW

    JarylW Active Member

    216
    41
    28
    Jun 19, 2014
    Singapore
    Ratings:
    +103
    Local Time:
    3:41 AM
    @eva2000
    CentOS 6.6 Install on OpenVZ

    grep LF_IPSET /etc/csf/csf.conf
    LF_IPSET = 0 <- correct

    yum -q list ipset*
    ipset.x86_64 6.11-3.el6 @base
    ipset-devel.x86_64 6.11-3.el6 @base

    Rebooting the VPS after centminmod install also fine - works as intended out of the box. I guess it is an issue with OpenVZ & CentOS 7.