問題
cmake出錯
1.解決 cmake_symlink_library: System Error: Operation not supported在編譯uchardet時遇到這個錯誤:
cmake_symlink_library: System Error: Operation not supported
創建鏈接不成功,要確認當前帳戶下是否有權限在編譯的目錄中有創建鏈接的權限。我使用vmware,在win機器的共享目錄中編譯,無法創建鏈接,就會提示上面的錯誤。
解決辦法是:
把源碼複製到linux的本地目錄中,比如/home等,在本地目錄中編譯就不會有這個問題。
另外,從linux中拷貝符號鏈接到windows機器的共享目錄時,也會提示錯誤導致無法拷貝,也是這個原因。你可以使用xshell等將符號鏈接拷貝出來。
密碼忘記
-
1.vim /etc/my.cnf
在[mysqld]加入
skip-grant-tables
然後保存退出
然後重啓mysql -
2 ./etc/init.d/mysqld restart
登錄
-
3.mysql -u root -p
-
4.5.7版本前的mysql運行: update user set password=password(“你的密碼”) where user=“用戶”;
5.7版本後的mysql運行:update mysql.user set authentication_string=password(‘你的密碼’) where user=‘用戶’;
-
5.exit; #退出
-
6.編輯my.cnf文件刪掉skip-grant-tables 這一行,然後重啓MySQL,/etc/init.d/mysqld restart,否則MySQL仍能免密碼登錄
-
7.mysql -u root -p輸入密碼