• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    PHP error Uncaught Exception: DateTimeZone

    Scheduled Pinned Locked Moved Solved
    Bug Reports
    3
    21
    7.8k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      kortnor @Tom Elliott
      last edited by

      @Tom-Elliott
      I’ve noticed ( at least on a fresh installation ) that when I install centos 7 minimal on a vm (virtual box ) that when I restart the vm and I restart the mysqld daemon that he indicates me the mysqld.pid can’t be created because there is not mysqld folder in /var/run

      now i’ve tried to clean the actual centos 7 from mysql meaning by that a yum remove mysql mysql-* and also delete the /var/lib/mysql
      Then Ive installed mariadb ( mariadb-server mariadb-libs mariadb) with yum and configured with :

      after I try a reinstallation of the trunk ( before I make a git pull in order to be sure I’m on the last version ) then I receive the following error

      I would like to know also, if the script detect the specific version of centos family or does he embed it in redhat ( Base linux: Red Hat )

       * Here are the settings FOG will use:
       * Base Linux: Redhat
       * Detected Linux Distribution: CentOS Linux
       * Server IP Address: 10.10.0.15
       * Server Subnet Mask: 255.255.255.0
       * Interface: eth0
       * Installation Type: Normal Server
       * Donate: 0
       * Internationalization: 0
       * Image Storage Location: /images
       * Using FOG DHCP: Yes
       * DHCP router Address: 10.10.0.100
       * DHCP DNS Address: 10.10.0.254
      
      
       * Are you sure you wish to continue (Y/N) Y
      
       * Installation Started
      
       * Installing required packages, if this fails
       | make sure you have an active internet connection.
      
       * Adding needed repository....................................OK
       * Preparing Package Manager...................................OK
       * Packages to be installed:
      
      	httpd php php-cli php-common php-gd mysql mysql-server dhcp tftp-server nfs-utils vsftpd net-tools wget xinetd tar gzip make m4 gcc gcc-c++ lftp php-mysqlnd curl php-mcrypt php-mbstring mod_ssl php-fpm php-process
      
      
       * Skipping package: httpd.....................................(Already Installed)
       * Skipping package: php.......................................(Already Installed)
       * Skipping package: php-cli...................................(Already Installed)
       * Skipping package: php-common................................(Already Installed)
       * Skipping package: php-gd....................................(Already Installed)
       * Installing package: mysql...................................Failed!
      

      log within the error_xxx.log which indicates the script still try to install mysql in place of using the mariadb.

      ransaction Summary
      ================================================================================
      Install  1 Package (+1 Dependent package)
      
      Total download size: 6.5 M
      Installed size: 33 M
      Downloading packages:
      --------------------------------------------------------------------------------
      Total                                              202 kB/s | 6.5 MB  00:33
      Running transaction check
      Running transaction test
      
      
      Transaction check error:
        file /etc/my.cnf from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/lib64/mysql/libmysqlclient.so.18.0.0 from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/czech/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/danish/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/dutch/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/english/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/estonian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/french/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/german/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/greek/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/hungarian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/italian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/japanese/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/korean/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/norwegian-ny/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/norwegian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/polish/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/portuguese/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/romanian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/russian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/serbian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/slovak/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/spanish/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/swedish/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
        file /usr/share/mysql/ukrainian/errmsg.sys from install of mysql-libs-5.5.48-1.el6.remi.x86_64 conflicts with file from package mariadb-libs-1:5.5.44-2.el7.centos.x86_64
      
      1 Reply Last reply Reply Quote 0
      • S
        Sebastian Roth Moderator
        last edited by

        @kortnor Please check your /opt/fog/.fogsettings file. I guess it says:

        ...
        packages='... mysql mysql-server...'
        ...
        

        Forcing the installer to try and install mysql. Just remove the .fogsettings file if you are doing a clean new install anyway - maybe backup if in case you need it later on.

        Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

        Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

        Tom ElliottT K 2 Replies Last reply Reply Quote 0
        • Tom ElliottT
          Tom Elliott @Sebastian Roth
          last edited by

          @Sebastian-Roth To add an, if you still want to update, but want dynamic packages, just remove the packages line altogether from the .fogsettings file (while maintaining the file itself.)

          Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

          Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

          Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

          K 1 Reply Last reply Reply Quote 0
          • K
            kortnor @Sebastian Roth
            last edited by

            @Sebastian-Roth
            I tried that also 🙂
            Cleaning setup

            • delete /etc/httpd/conf.d/fog
            • rm -rf /var/www/html/fog
            • rm -rf /opt/fog/
            • fully delete mysql (lke explained before)

            restart install

            • cd /opt/fogGit/
            • git pull
            • cd bin
            • ./installfog.sh

            I don’ think I’m missing something.

            1 Reply Last reply Reply Quote 0
            • S
              Sebastian Roth Moderator
              last edited by Sebastian Roth

              @kortnor On my system I was not able to fully remove the mariadb/mysql packages because mariadb/mysql-libs is needed by some very important system packages. So I am wondering if you somehow managed to install mysql-libs and are not able to get rid of it anymore? rpm -qa | grep -e mysql -e mariadb (just a wild guess)

              Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

              Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

              K 1 Reply Last reply Reply Quote 0
              • K
                kortnor @Tom Elliott
                last edited by

                @Tom-Elliott
                also, After deleting the whole opt/fog directory I suppose the install script reacts like it will be a new installation ==> so creating the folder again.

                Now what I’ve done is:

                • yum remove mariadb*
                • check 2 time if there is no mysql pkg wih ==> yum list installed | grep mysql

                make a new installation again.

                Now I arrived to the fog webui

                for your info the script has installed the following mysql package
                mysql.x86_64 5.5.48-1.el6.remi @remi
                mysql-libs.x86_64 5.5.48-1.el6.remi @remi
                mysql-server.x86_64 5.5.48-1.el6.remi @remi

                now, because mysql is replaced by mariadb , will there be any changed applied to the script when its run to centos 7 or rhel 7 ?

                Best,

                1 Reply Last reply Reply Quote 0
                • S
                  Sebastian Roth Moderator
                  last edited by Sebastian Roth

                  @kortnor Try running the following commands on your system. Here is what they show on my system (as well CentOS 7 fresh install but installs mariadb):

                  $ dnf list --enablerepo=remi mysql
                  Using metadata from Tue Mar 15 19:11:26 2016
                  Available Packages
                  mariadb.x86_64                                   1:5.5.44-2.el7.centos                                   base
                  $ yum --enablerepo=remi list mysql
                  ...
                  Error: No matching Packages to list
                  $ yum --enablerepo=remi list mariadb
                  ...
                  Available Packages
                  mariadb.x86_64                                    1:5.5.44-2.el7.centos                                    base
                  

                  I am wondering why you have mysql el6 packages installed…?!?

                  Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                  Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                  K 1 Reply Last reply Reply Quote 0
                  • K
                    kortnor @Sebastian Roth
                    last edited by Sebastian Roth

                    @Sebastian-Roth
                    hereunder the result of the requested command line

                    [root@fog ~]# yum --enablerepo=remi list mysql
                    Loaded plugins: fastestmirror, replace
                    Loading mirror speeds from cached hostfile
                     * base: ftp.belnet.be
                     * epel: ftp.nluug.nl
                     * extras: miroir.univ-paris13.fr
                     * remi: mirror5.layerjet.com
                     * remi-php70: mirror5.layerjet.com
                     * remi-safe: mirror5.layerjet.com
                     * rpmforge: ftp.nluug.nl
                     * updates: miroir.univ-paris13.fr
                    Installed Packages
                    mysql.x86_64                                   5.5.48-1.el6.remi                                    @remi
                    [root@fog ~]# yum --enablerepo=remi list mariadb
                    Loaded plugins: fastestmirror, replace
                    Loading mirror speeds from cached hostfile
                     * base: ftp.belnet.be
                     * epel: ftp.nluug.nl
                     * extras: miroir.univ-paris13.fr
                     * remi: mirror5.layerjet.com
                     * remi-php70: mirror5.layerjet.com
                     * remi-safe: mirror5.layerjet.com
                     * rpmforge: ftp.nluug.nl
                     * updates: miroir.univ-paris13.fr
                    Available Packages
                    mariadb.x86_64                                 1:5.5.44-2.el7.centos                                 base
                    
                    1 Reply Last reply Reply Quote 0
                    • K
                      kortnor @Sebastian Roth
                      last edited by

                      @Sebastian-Roth
                      i’m using the following package

                      [root@fog ~]# rpm -qa | grep -e mysql -e mariadb
                      mysql-5.5.48-1.el6.remi.x86_64
                      mysql-libs-5.5.48-1.el6.remi.x86_64
                      php-mysqlnd-7.0.4-1.el7.remi.x86_64
                      mysql-server-5.5.48-1.el6.remi.x86_64
                      

                      But i can’t use mariadb also and that’s a major threat for me:
                      everytime I restart my server host, I need to create the /var/run/mysqld /; touch /var/run/mysqld.pid ; chown -R mysql:mysql /var/run/mysqld
                      otherwise mysql won’t start

                      1 Reply Last reply Reply Quote 0
                      • S
                        Sebastian Roth Moderator
                        last edited by

                        @kortnor Ahhhh… the “old” mysql package is still newer than the mariadb package (5.5.48 vs 5.5.44). Therefore yum prefers to install the EL6 mysql version instead of using EL7 mariadb.

                        yum remove remi-release-6
                        rpm -Uvh  http://rpms.remirepo.net/enterprise/remi-release-7.rpm
                        yum -y update
                        yum --enablerepo=remi list mysql
                        

                        Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                        Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                        1 Reply Last reply Reply Quote 0
                        • K
                          kortnor @Guest
                          last edited by

                          @Sebastian-Roth
                          that’s really interresting, I’ll create a fresh new vm ( aside the my running one, ) and try what’s you’re proposing, I should do that for thursday evening

                          In the meantime, I need to learn how to fine tune the images because at the end I would like to apply it on a cluser created with 6 intel nuc.
                          On each nuc, I’ll push my images but after every nuc needs to be configurer with a static ip ( for sure different for everyone ) 😄

                          Tom ElliottT 1 Reply Last reply Reply Quote 0
                          • Tom ElliottT
                            Tom Elliott @kortnor
                            last edited by

                            @kortnor The datetimezone issue should be fixed in the latest update. I wasn’t implicitly defining a Timezone, so it would not find any data in the case of a fresh install.

                            I found two places that I could use to ensure the timezone is set (albeit not necessarily accurate) in the case the DB hasn’t been loaded yet (fresh install), the php.ini file does not have a date.timezone specified (php defaults to commenting the timezone out). The fix, for now, is test the presence of the variable by means of checking if it’s empty or not.

                            Mind you if the php.ini file IS set with the date timezone setting, it will NOT try to use the one defined in the DB anyway. However, if you aren’t comfortable messing in /etc/php.ini, the current push of FOG should take over and operate as originally expected (no more 500 heres or erroneous error messages.)

                            Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

                            Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                            Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                            1 Reply Last reply Reply Quote 2
                            • S
                              Sebastian Roth Moderator
                              last edited by

                              @kortnor I am marking this solved as the initial OP is now properly handled, thanks Tom!!

                              Probably best if you start a new topic if you run into another problem. I am sure we’ll be able to help you fix it as well!

                              Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                              Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                              1 Reply Last reply Reply Quote 0
                              • 1
                              • 2
                              • 1 / 2
                              • First post
                                Last post

                              207

                              Online

                              12.0k

                              Users

                              17.3k

                              Topics

                              155.2k

                              Posts
                              Copyright © 2012-2024 FOG Project