matyhtf / webim

使用PHP+Swoole实现的网页即时聊天工具
1.78k stars 653 forks source link

Uncaught exception 'Swoole\Exception\Factory' with message 'log->master is not found.' #32

Open zengmm opened 7 years ago

zengmm commented 7 years ago

swoole

swoole support => enabled Version => 2.0.7 Author => tianfeng.han[email: mikan.tenny@gmail.com] kqueue => enabled rwlock => enabled async http/websocket client => enabled pcre => enabled zlib => enabled

Directive => Local Value => Master Value swoole.aio_thread_num => 2 => 2 swoole.display_errors => On => On swoole.use_namespace => On => On swoole.fast_serialize => Off => Off swoole.unixsock_buffer_size => 8388608 => 8388608

yuforlong commented 7 years ago

我在Aliyun部署的时候也遇到了同样的问题,解决方案:在config目录下增加文件 log.php文件。文件内容:

<?php
$log['master'] = array(
    'type' => 'FileLog',
    'file' => WEBPATH . '/logs/app.log',
);
$log['test'] = array(
    'type' => 'FileLog',
    'file' => WEBPATH . '/logs/test.log',
);
return $log;