mysql 8.0 关闭binlog

清空日志

mysql> reset master;

查询是否开启了binlog

$mysql -uroot -p
mysql>use mysql;
mysql>
mysql> show variables like 'log_bin';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| log_bin       | ON    |
+---------------+-------+
1 row in set (0.01 sec)

阅读全文»

MBP ubuntu从18升级到20启动错误修正

错误信息:

Failed to Set MokListRT: Invalid Parameter
Could not create mokListRT: Invalid Parameter
Importing MOK states has failed: import_mok_state() failed: Invalid Parameter
Continuing boot since secure mode is disabled.

修正:

sudo su -
cd /boot/efi/EFI/ubuntu
cp grubx64.efi shimx64.efi
reboot

参考:(Ubuntu 20.04 Failed to Set MokListRT: Invalid Parameter)[https://askubuntu.com/questions/1279602/ubuntu-20-04-failed-to-set-moklistrt-invalid-parameter]

cocos2d-x 4.0 captureNode用法备份

-- 截取场景
cc.utils:captureNode(scene, function(image)
    -- 图片转纹理
    local texture = cc.Texture2D:new()
    texture:initWithImage(image)
    image:release()
    -- 纹理创建精灵
    local sp = cc.Sprite:createWithTexture(texture)
    sp:addTo(scene):center()
end)

Cocos2d-x fgui坑点

Component 挂事件监听不遵循传播规则,总可以收到监听,透明区域的点击判断需要一个单独的透明图形来挂监听器。
GList不能挂事件监听,不然GList滚动行为不正常。