This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

[Urgent Help needed] Unable to run daemon.php manually
#1
[Solved] [Urgent Help needed] Unable to run daemon.php manually
Hello everyone,

I am having an issue while adding domain in zPanel 10.1.1 .
The domain which I added is in pending mode from last 3 hours.

I tried manual daemon.php run but it returns an error :

Code:
root@xxxxxxx:~# php /etc/zpanel/panel/bin/daemon.php

PHP Fatal error:  Undefined class constant 'MYSQL_ATTR_INIT_COMMAND' in /etc/zpanel/panel/inc/dbc.inc.php on line 25


I don't know what to do!

Need help


Thanks a lot
Reply
Thanks given by:
#2
[Solved] RE: [Urgent Help needed] Unable to run daemon.php manually
Moved to proper forum section.

Never heard of this error, will look into it.
-TGates - Head of Support

SEARCH the Forums or read the DOCUMENTATION before posting!
Modules Maintained: 13 - Module Installs: 108k+

Find my support helpful? Donate HERE
Help me to help you by getting your domains using this link:
GoDaddy - Domains
Reply
Thanks given by:
#3
[Solved] RE: [Urgent Help needed] Unable to run daemon.php manually
(12-23-2016, 06:10 PM)TGates Wrote: Moved to proper forum section.

Never heard of this error, will look into it.

Hello TGates ,

Have a look on my dbc.ini.php 


PHP Code:
<?php

/**
 * Initiates the database driver object and debug object and registers the $zdhb and $zlo globals for the framework.
 * @package zpanelx
 * @subpackage core
 * @author Bobby Allen (ballen@bobbyallen.me)
 * @copyright ZPanel Project (http://www.zpanelcp.com/)
 * @link http://www.zpanelcp.com/
 * @license GPL (http://www.gnu.org/licenses/gpl.html)
 */
/**
 * @global debug_logger $zlo
 */
global $zlo;

/**
 * @global db_driver $zdbh
 */
global $zdbh;

$zlo = new debug_logger();

try {
    $zdbh = new db_driver("mysql:host=$host;dbname=$dbname"$user$pass, array(PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES 'utf8'"));
    $zdbh->setAttribute(PDO::ATTR_ERRMODEPDO::ERRMODE_EXCEPTION);
} catch (
PDOException $e) {
    $zlo->method "text";
    $zlo->logcode "0100";
    $zlo->detail "Unable to connect or authenticate against the database supplied!";
    $zlo->mextra $e;
    $error_html "<style type=\"text/css\"><!--
            .dbwarning {
                    font-family: Verdana, Geneva, sans-serif;
                    font-size: 14px;
                    color: #C00;
                    background-color: #FCC;
                    padding: 30px;
                    border: 1px solid #C00;
            }
            p {
                    font-size: 12px;
                    color: Custom Vhost entries problem - Not working;
            }
            </style>
            <div class=\"dbwarning\"><strong>Critical Error:</strong> [0100] - Unable to connect or authenticate to the ZPanel database (<em>
$dbname</em>).<p>We advice that you contact the server administrator to ensure that the database server is online and that the correct connection parameter are being used.</p></div>";

    die($error_html);
}
?>
Reply
Thanks given by:
#4
[Solved] RE: [Urgent Help needed] Unable to run daemon.php manually
Finally ! Got the problem ..

I don't know how , I do have  2 php versions -


Code:
root@xxxxxxxxxx:~# php -v
PHP 5.6.29-1+deb.sury.org~precise+1 (cli)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
    with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2016, by Zend Technologies


and 

Code:
root@xxxxxxxxxx:~# php5 -v
PHP 5.4.45-4+deprecated+dontuse+deb.sury.org~precise+1 (cli) (built: Jun 24 2016 08:32:17)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies

When I tried 


Code:
php /etc/zpanel/panel/bin/daemon.php

I got error every time.
But when I tried 


Code:
php5 /etc/zpanel/panel/bin/daemon.php


Everything went good and finally problem solved !!  Idea  Cool

Can anyone tell me how do I remove that php 5.6.29 ?

Thanks
Reply
Thanks given by:
#5
[Solved] RE: [Urgent Help needed] Unable to run daemon.php manually
Glad you got it sorted out! Smile
Not sure how to remove one version, but I'm sure there is a tutorial out there if you search google Wink
-TGates - Head of Support

SEARCH the Forums or read the DOCUMENTATION before posting!
Modules Maintained: 13 - Module Installs: 108k+

Find my support helpful? Donate HERE
Help me to help you by getting your domains using this link:
GoDaddy - Domains
Reply
Thanks given by: himanshu
#6
[Solved] RE: [Urgent Help needed] Unable to run daemon.php manually
You obviously added an exteranl repo to add php 5.6 on Ubuntu 12.04.

Check how you added it in first place to remove it.

M B
No support using PM (Auto adding to IGNORE list!), use the forum. 
How to ask
Coldfusion Freelance

10$ free to start your VPS

Reply
Thanks given by:
#7
[Solved] RE: [Urgent Help needed] Unable to run daemon.php manually
(12-26-2016, 02:27 AM)Me.B Wrote: You obviously added an exteranl repo to add php 5.6 on Ubuntu 12.04.

Check how you added it in first place to remove it.

M B

Thanks for replying Me.B 

Let me check that
Reply
Thanks given by:


Possibly Related Threads...
Thread Author Replies Views Last Post
zpanel daemon errors "Undefined class constant 'MYSQL_ATTR_INIT_COMMAND'" craigh 3 337 06-02-2017, 03:52 AM
Last Post: craigh
Critical Error: [0100] - Unable to connect or authenticate to the Sentora database (s marketingdigitalmassivo 13 2,996 08-06-2016, 05:25 AM
Last Post: TGates
Many instances of daemon.php gyro 2 783 07-16-2016, 02:14 AM
Last Post: TGates

Forum Jump:


Users browsing this thread: 1 Guest(s)