2017年1月18日水曜日

mysql 5.6でgrantをしたら、ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tm p/mysql_q4m.sock' のエラー

解決方法は、以下のコマンドを実行
# mysql_upgrade -u root -p

Looking for 'mysql' as: /usr/local/q4m/bin/mysql
Looking for 'mysqlcheck' as: /usr/local/q4m/bin/mysqlcheck
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
mysql.columns_priv                                 OK
mysql.db                                           OK
mysql.event                                        OK
mysql.func                                         OK
mysql.general_log                                  OK
mysql.help_category                                OK
mysql.help_keyword                                 OK
mysql.help_relation                                OK
mysql.help_topic                                   OK
mysql.host                                         OK
mysql.ndb_binlog_index                             OK
mysql.plugin                                       OK
mysql.proc                                         OK
mysql.procs_priv                                   OK
mysql.servers                                      OK
mysql.slow_log                                     OK
mysql.tables_priv                                  OK
mysql.time_zone                                    OK
mysql.time_zone_leap_second                        OK
mysql.time_zone_name                               OK
mysql.time_zone_transition                         OK
mysql.time_zone_transition_type                    OK
mysql.user                                         OK
Running 'mysql_fix_privilege_tables'...
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
freegame_queue.application_message_merge           OK
freegame_queue.game_playing_date                   OK
freegame_queue.guide_send_twitter_dm               OK
freegame_queue.mailbatch_mail                      OK
freegame_queue.messageapi_application_mail         OK
freegame_queue.messageapi_user_mail                OK
OK
Could not create the upgrade info file '/usr/local/q4m/var/mysql_upgrade_info' in the MySQL Servers datadir, errno: 13
[vagrant@010node mysql5.6q4m]$ sudo /usr/local/q4m/bin/mysql_upgrade -u root -p
Enter password:
Looking for 'mysql' as: /usr/local/q4m/bin/mysql
Looking for 'mysqlcheck' as: /usr/local/q4m/bin/mysqlcheck
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
mysql.columns_priv                                 OK
mysql.db                                           OK
mysql.event                                        OK
mysql.func                                         OK
mysql.general_log                                  OK
mysql.help_category                                OK
mysql.help_keyword                                 OK
mysql.help_relation                                OK
mysql.help_topic                                   OK
mysql.host                                         OK
mysql.ndb_binlog_index                             OK
mysql.plugin                                       OK
mysql.proc                                         OK
mysql.procs_priv                                   OK
mysql.proxies_priv                                 OK
mysql.servers                                      OK
mysql.slave_master_info                            OK
mysql.slave_relay_log_info                         OK
mysql.slave_worker_info                            OK
mysql.slow_log                                     OK
mysql.tables_priv                                  OK
mysql.time_zone                                    OK
mysql.time_zone_leap_second                        OK
mysql.time_zone_name                               OK
mysql.time_zone_transition                         OK
mysql.time_zone_transition_type                    OK
mysql.user                                         OK
Running 'mysql_fix_privilege_tables'...
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--port=3306' '--socket=/tmp/mysql_q4m.sock'
Warning: Using a password on the command line interface can be insecure.
freegame_queue.application_message_merge           OK
freegame_queue.game_playing_date                   OK
freegame_queue.guide_send_twitter_dm               OK
freegame_queue.mailbatch_mail                      OK
freegame_queue.messageapi_application_mail         OK
freegame_queue.messageapi_user_mail                OK
OK
[vagrant@010node mysql5.6q4m]$ /usr/local/q4m/bin/mysql -h localhost -P 13306 -u"root" -p"vagrant"
Warning: Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 18
Server version: 5.6.32-q4m-log Q4M

Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

2017年1月15日日曜日

windows10のリモートデスクトップでタスクマネージャーを起動する方法

方法1、コマンドプロンプトを起動する。
     以下のコマンドを実行
     >taskmgr

方法2、ショートカットキー「Ctrl+Alt+End」を押す
     ちなみに、ローカル場合は、「Ctrl+Alt+Del」を押す

2017年1月9日月曜日

Stderr: VBoxManage.exe: error: Could not find a controller named 'SATA Controller' の解消方法

以下のような設定で vagrant up をしたら、タイトルのエラーが出来ました。
 ["storageattach", "5cbed0f4-9370-4603-8da8-f02b7f943cad", "--storagectl", "SATA Controller", "--port", "1", "--device", "0", "--type", "hdd", "--medium", "010node.com.vdi"]



解決手順は以下の通りです。
 1、まず VirtualBoxの設定画面で、「新しいストレージコントローラーを追加委します。」からSATAコントローラーを追加する

 
2、次に、 設定ファイルの「 "--storagectl", "SATA Controller"」を「 "--storagectl", "SATA"」に変更する。
 SATA Controllerの「名前」のところに、名前は「SATA」となっているので、それに合わせる必要。