debian wheezy mysql 設定、データ移行

インストール sudo aptitude install mysql-server alive check mysqladmin ping -u root -p mysqlパスワード変更 mysql -u root -p rootパスワード入力 SET PASSWORD FOR root@localhost=PASSWORD('new_password'); ユーザ確認 ログイン mysql -u root -p SQL実行 SELECT host,user,password FROM mysql.user; 文字コード設定 charset UTF8 check mysql> status -------------- mysql Ver 14.14 Distrib 5.5.38, for debian-linux-gnu (armv7l) using readline 6.2 Connection id: 39 Current database: Current user: root@localhost SSL: Not in use Current pager: stdout Using outfile: '' Using delimiter: ; Server version: 5.5.38-0+wheezy1 (Debian) Protocol version: 10 Connection: Localhost via UNIX socket Server characterset: utf8 Db characterset: utf8 Client characterset: utf8 Conn. characterset: utf8 UNIX socket: /var/run/mysqld/mysqld.sock Uptime: 5 hours 20 min 7 sec Threads: 1 Questions: 114 Slow queries: 0 Opens: 171 Flush tables: 1 Open tables: 41 Queries per second avg: 0.005 if your env is not seted to utf8, add utf8 settings below sudo vim /etc/mysql/conf.d/character_set.cnf ...

2014-10-11 ·  2014-10-11 · 3 分 · 426 文字

Linkstation(debian wheezy) へ mysql を設定、データ移行

インストール sudo aptitude install mysql-server alive check mysqladmin ping -u root -p mysqlパスワード変更 mysql -u root -p rootパスワード入力 SET PASSWORD FOR root@localhost=PASSWORD('new_password'); ユーザ確認 ログイン mysql -u root -p SQL実行 SELECT host,user,password FROM mysql.user; 文字コード設定 charset UTF8 check mysql> status -------------- mysql Ver 14.14 Distrib 5.5.38, for debian-linux-gnu (armv7l) using readline 6.2 Connection id: 39 Current database: Current user: root@localhost SSL: Not in use Current pager: stdout Using outfile: '' Using delimiter: ; Server version: 5.5.38-0+wheezy1 (Debian) Protocol version: 10 Connection: Localhost via UNIX socket Server characterset: utf8 Db characterset: utf8 Client characterset: utf8 Conn. characterset: utf8 UNIX socket: /var/run/mysqld/mysqld.sock Uptime: 5 hours 20 min 7 sec Threads: 1 Questions: 114 Slow queries: 0 Opens: 171 Flush tables: 1 Open tables: 41 Queries per second avg: 0.005 if your env is not seted to utf8, add utf8 settings below sudo vim /etc/mysql/conf.d/character_set.cnf ...

2014-10-11 ·  2014-10-11 · 3 分 · 427 文字

Debian wheezy に Ubuntu 14.04 クライアントからSSH接続する

[Client] Key generate create pub, private key at ~/.ssh cd ~/.ssh ssh-keygen -t rsa # created under files id_rsa id_rsa.pub upload public key to server. scp id_rsa.pub [server ip address]:~/ [Client] .ssh/config vim ~/.ssh/config Host [server name] HostName [server name or ipaddress] Port 22 User [login user name] IdentityFile ~/.ssh/id_rsa [server] regist pub key login the server. cd ~ cat rsa.pub >> ~/.ssh/authorized_keys [server] sshd settings sudo vim /etc/ssh/sshd_config check the settings ...

2014-10-07 ·  2014-10-07 · 1 分 · 78 文字

Linkstation(ls-xhle) へdebian wheezy を導入する

パーティション構成 /dev/sda1 /boot /dev/sda2 / /dev/sda3 swap /dev/sda4 /data ここを参考に update 2013.05.15: Now when Debian 7 wheezy is stable, i made a new image. I created a minimal debian wheezy bootstrap for our Linkstations. It comes with 3.9.2 kernels for both LS-CHLv2 and LS-XHL, which you can find here. Infos Changes to plain debootstrap This is a ready to use image, no need to tweak device specific stuff after install e.g. do NOT install blstools. Download http://neboola.de/fjen/lschlv2/debian/wheezy/ Archive is packed with tar/xz. Use tar/xz-utils on Linux to extract. Do not extract it on Windows or it won’t boot because of permission problems! Installation -backup your installation -partition harddrive with gpt layout –sda1 boot ext3 128MB –sda2 root ext4 >1GB -extract archive to / and /boot FOR LSXHL: Replace /boot/uImage.buffalo.3.9.2-fjen-1 with the lsxhl one. your setup should look like this: Code: boot / sda1 uImage.buffalo uImage.buffalo.3.9.2-fjen-1 initrd.buffalo root / sda2 /bin /boot /dev /etc […] After installation Device gets IP through DHCP. root pw: toor ssh port: 22 Execute these commands to have a sane system: Code: dpkg-reconfigure locales dpkg-reconfigure tzdata rm /etc/ssh/ssh_host_* && dpkg-reconfigure openssh-server apt-get update Have fun! Linkstation LS-CHLv2 and LS-XHL stuff: Debian 7 Wheezy - Rootfs Kernel 3.13

2014-09-13 ·  2014-09-13 · 1 分 · 201 文字

玄箱HG(debian lenny) mysqlディレクトリ変更

参考 mysql停止 sudo /etc/init.d/mysql stop データ移行 mkdir -p /path/to/mysql_directory chown mysql:mysql /path/to/mysql_directory cd /path/to/mysql_directory mkdir mysqldata mysqldump chown mysql:mysql mysqldata chown mysql:mysql mysqldump sudo cp -fprv /var/lib/mysql/ ./mysqldata/ ディレクトリ指定設定 sudo vi /etc/mysql/conf.d/my_datadir.cnf 修正内容は以下 [mysqld] datadir = /path/to/mysql_directory/mysqldata/mysql 正しく設定変更され起動できるか確認する為、元のデータは別場所へ移動 mkdir /data/tmp sudo mv /var/lib/mysql /data/tmp mysql 再起動 sudo /etc/init.d/mysql restart 不要となったデータを削除 sudo rm /data/tmp

2012-10-20 ·  2012-10-20 · 1 分 · 53 文字