開啟部落格發現載入失敗,檢視部落格日誌顯示mysql連線不上
啟動mysql發現錯誤日誌如下:
190612 11:20:47 [note] plugin 'federated' is disabled.
190612 11:20:47 innodb: the innodb memory heap is disabled
190612 11:20:47 innodb: mutexes and rw_locks use gcc atomic builtins
190612 11:20:47 innodb: compressed tables use zlib 1.2.7
190612 11:20:47 innodb: initializing buffer pool, size = 128.0m
innodb: mmap(137363456 bytes) failed; errno 12
190612 11:20:47 innodb: completed initialization of buffer pool
190612 11:20:47 innodb: fatal error: cannot allocate memory for the buffer pool
190612 11:20:47 [error] plugin 'innodb' init function returned error.
190612 11:20:47 [error] plugin 'innodb' registration as a storage engine failed.
190612 11:20:47 [error] unknown/unsupported storage engine: innodb
190612 11:20:47 [error] aborting
190612 11:20:47 [note] /www/wdlinux/mysql-5.5.58/bin/mysqld: shutdown complete
伺服器記憶體只有1g,但是開了很多東西,導致記憶體不足,開啟my.conf修改配置
**mysql的配置都在/ect/my.cnf裡面(ubuntu目錄有稍微的差別,用whereis my.cnf就能找到了)。**
vim /etc/my.cnf
如果有innodb_buffer_pool_size 屬性則修改為50mb,沒有的話新增一行
innodb_buffer_pool_size = 128m
然後重新啟動mysql
service mysqld start
![alt](
mysql查詢錯誤 複雜的MySQL查詢錯誤的結果
我正在嘗試構建複雜的 mysql查詢,但它返回錯誤的結果 select b.name as batch name,b.id as batch id,count distinct s.id as total students,coalesce sum s.open bal 0 as open bala...
mysql 錯誤 2061 mysql8 常見錯誤
1.error 2061 hy000 authentication plugin caching sha2 password reported error authentication requires secure connection.分析 mysql8預設使用外掛程式caching sha2 ...
mysql控制台常見錯誤 MySQL常見錯誤
error 1044 42000 access denied for user localhost to database mydb 原因是因為mysql資料庫的user表裡,存在使用者名為空的賬戶即匿名賬戶,導致登入的時候是雖然用的是root,但實際是匿名登入的,通過錯誤提示裡的 localhos...