Author Topic: Failed to open stream: postfix.php  (Read 4460 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Failed to open stream: postfix.php
« on: February 06, 2015, 04:13:20 PM »
Dovecot is not giving me any errors in maillog, but I am getting a few warnings for postfix, because it can't connect to MySQL

Quote
Warning: include(../resources/admin/include/postfix.php): failed to open stream: No such file or directory in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Warning: include(../resources/admin/include/postfix.php): failed to open stream: No such file or directory in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Warning: include(): Failed opening '../resources/admin/include/postfix.php' for inclusion (include_path='.:/usr/local/cwp/php54/lib/php') in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Notice: Undefined variable: db_host_postfix in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Notice: Undefined variable: db_user_postfix in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Notice: Undefined variable: db_pass_postfix in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Notice: Undefined variable: db_name_postfix in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Warning: mysql_connect(): Access denied for user ''@'localhost' (using password: NO) in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Notice: Undefined variable: db_name_postfix in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Warning: mysql_select_db() expects parameter 2 to be resource, boolean given in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2

Notice: Undefined variable: db_name_postfix in /usr/local/cwpsrv/htdocs/resources/client/modules/mail_list.php(1) : eval()'d code(1) : eval()'d code on line 2
Could not connect to database check configuration file.


SOLUTION:

Create the postfix.php in /usr/local/cwpsrv/htdocs/resources/admin/include/

Code: [Select]
<?php 
/* MySQL hostname [ localhost (127.0.0.1 via TCP/IP) ] */
$db_host_postfix "localhost";

/* The name of the database */
$db_name_postfix "postfix";

/* MySQL database username */
$db_user_postfix "postfix";

/* MySQL database password */
$db_pass_postfix 'postfix-password';
?>



--- Application Version
CWP version: 0.9.7
Apache version: Apache/2.2.27
PHP version: 5.4.27
MySQL version: 5.1.73
FTP version: 1.0.36

--- System Info
CPU Model: Intel(R) Xeon(R) CPU X3450 @ 2.67GHz
CPU Details: 2 Core (2660 MHz)
Distro Name: CentOS release 6.6 (Final)
Kernel Version: 2.6.18-348.16.1.el5.028stab108.1
Platform: x86_64 [openvz]
Uptime: 1 day, 1:11
Server Time: Fri Feb 6 19:06:59 MSK 2015

--- System Stats
Memory RAM: 0.85GB / 8GB ( 10.6%)
Swap Memory: 0GB / 0.84GB ( 0% )
Number of processes: 70
Postfix Mail Queue: 1