ナビゲーション
FrontPage
FreeBSD
Linux
Citrix XenServer
VMware ESXi
Unixコマンド
MySQL
PostgreSQL
Windows
CMS/CRM
クラウド
用語
PHPスクリプト
Bashシェルスクリプト
Rubyスクリプト
開発日記
検索
ツールボックス
新しいページの作成
バックアップの表示
外部のリンク元
最近更新したページ
全ページ
ヘルプ
凍結
アップロード
ページ名の変更
最新の40件
2016-08-17
Linux/NagiosQL
Linux/CentOSチューニング
2016-02-23
Linux/ソフトウェアRAID復旧手順
2016-02-18
FreeBSD/DHCP
FreeBSD/squid
2016-02-15
Unixコマンド/file
2016-02-05
FreeBSD/DynaBook
FreeBSD/Linux compatibility
2016-01-21
PHPスクリプト/PEAR DBインストールできない
PHPスクリプト/PEAR DB
2016-01-20
PHP/フレームワーク/Zend Framework
PHP/フレームワーク
FreeBSD/Postfix+amavisd+clamav
2016-01-15
FreeBSD/sl
2015-12-04
Unixコマンド/dig
Unixコマンド/nslookup
Unixコマンド/traceroute
Linux/rsync
FreeBSD/rsync
Unixコマンド/vipw
2015-11-25
Linux/Postfix+MySQL+Postfix AdminによるバーチャルSMTPサーバの構築
Linux/Postfix + postgrey
2015-11-24
Linux/Postfix + amavisd + clamav
2015-05-25
Unixコマンド/ifconfig
2015-05-23
Unixコマンド/netstat
Unixコマンド/route
Unixコマンド/lsof
Unixコマンド/disown
Unixコマンド/time
Unixコマンド/crontab
2015-05-22
Unixコマンド/nohup
Unixコマンド/fgとbg
Unixコマンド/nice
Unixコマンド/kill
Unixコマンド/jobs
Unixコマンド/restor
Unixコマンド/dump
Unixコマンド/uncompress
Unixコマンド/compress
Unixコマンド/zcat
total:
2718
today:
1
yesterday:
0
now:
1
本文
ノート
?
編集
差分
一覧
FreeBSD/MySQL/phpMyAdmin の編集
*phpMyAdmin [#u8d69937] [[dokuwiki.fl8.jp転載済>http://dokuwiki.fl8.jp/doku.php/02_freebsd/04_database/01_mysql/mysql_phpmyadmin]] WebブラウザからMySQLデータベースを管理するためのPHPで記述されたソフトウェアです。 phpMyAdminを使用してWebブラウザからMySQLのテーブル操作、インポート・エクスポートすることが出来ます。 #contents **環境 [#jfbb0b38] -FreeBSD 6.1 -PHP 4.4.4 -MySQL 4.1.23 **ダウンロード [#j6bea1ab] [[phpMyAdmin Project>http://www.phpmyadmin.net/home_page/downloads.php]]より最新版をダウンロード。 **インストール [#g199ca48] ***展開 [#v6f87cd2] Web上から表示できる場所に展開するとよいと思います。 $ tar zxvf phpMyAdmin-2.9.2-all-languages.tar.gz $ mv phpMyAdmin-2.9.2-all-languages phpMyAdmin $ cp config.sample.inc.php config.inc.php ***設定変更 [#e20229ad] $ vi config.ini.php --------------------変更箇所----------------------- 38 $cfg['Servers'][$i]['controluser'] = 'pmausr'; 39 $cfg['Servers'][$i]['controlpass'] = 'pmapass'; ↓ 38 $cfg['Servers'][$i]['controluser'] = ''; 39 $cfg['Servers'][$i]['controlpass'] = ''; ------------------何かパスワードを設定------------ 17 $cfg['blowfish_secret'] = ''; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */ これでmysqlに設定してあるユーザ名・パスワードでログインできます。 **確認 [#cb4b7524] ウェブ上から確認。 http://*******/phpMyAdmin **最新のバージョンだとlibmcryptが無いと怒られる [#m8b1e10c] # cd /usr/ports/security/libmcrypt # make install clean ・PHPを下記の--with-mysql=/usr/localを加えて再インストール ./configure --with-mysql=/usr/local \ --with-apxs2=/usr/local/apache2/bin/apxs \ --enable-pear --with-tsrm-pth --with-mcrypt=/usr/local \ --with-gd --with-zlib --with-ttf=/usr/local \ --with-freetype-dir=/usr/local --with-jpeg-dir=/usr/local \ --with-png-dir=/usr/local --enable-force-cgi-redirect \ --enable-mbstring --enable-mbstr-enc-trans \ --enable-trans-sid --enable-versioning --enable-gd-native-ttf --enable-gd-jis-conv *デフォルトでログインするように設定する。 [#v0bfc6c8] デフォルトでログインするユーザ名:パスワードを設定する。~ auth_typeをconfigに変更する。 # cd phpMyAdmin # cp config.sample.inc.php config.inc.php # vi config.inc.php 下記を追加 $cfg['Servers'][$i]['user'] = 'root'; $cfg['Servers'][$i]['password'] = 'hogehoge'; $cfg['Servers'][$i]['auth_type'] = 'config'; **この場合アクセスするだけで、ログインできてしまうのでBasic認証をかけておく [#c5084497] # cd phpMyAdmin # vi .htaccess AuthUserFile /home/www/public_html/phpMyAdmin/.htpasswd AuthGroupFile /dev/null AuthName "Please Enter Your Password" AuthType Basic Require valid-user **パスワードファイルの作成 [#yfcdefe4] # htpasswd -c .htpasswd hogehoge New password: Re-type new password: Adding password for user hogehoge **アクセスできるDBを設定する。 [#s3ec9db0] 199 * @global string $cfg['Servers'][$i]['only_db'] 200 */ 201 $cfg['Servers'][$i]['only_db'] = 'shinbutsu';
タイムスタンプを変更しない
*phpMyAdmin [#u8d69937] [[dokuwiki.fl8.jp転載済>http://dokuwiki.fl8.jp/doku.php/02_freebsd/04_database/01_mysql/mysql_phpmyadmin]] WebブラウザからMySQLデータベースを管理するためのPHPで記述されたソフトウェアです。 phpMyAdminを使用してWebブラウザからMySQLのテーブル操作、インポート・エクスポートすることが出来ます。 #contents **環境 [#jfbb0b38] -FreeBSD 6.1 -PHP 4.4.4 -MySQL 4.1.23 **ダウンロード [#j6bea1ab] [[phpMyAdmin Project>http://www.phpmyadmin.net/home_page/downloads.php]]より最新版をダウンロード。 **インストール [#g199ca48] ***展開 [#v6f87cd2] Web上から表示できる場所に展開するとよいと思います。 $ tar zxvf phpMyAdmin-2.9.2-all-languages.tar.gz $ mv phpMyAdmin-2.9.2-all-languages phpMyAdmin $ cp config.sample.inc.php config.inc.php ***設定変更 [#e20229ad] $ vi config.ini.php --------------------変更箇所----------------------- 38 $cfg['Servers'][$i]['controluser'] = 'pmausr'; 39 $cfg['Servers'][$i]['controlpass'] = 'pmapass'; ↓ 38 $cfg['Servers'][$i]['controluser'] = ''; 39 $cfg['Servers'][$i]['controlpass'] = ''; ------------------何かパスワードを設定------------ 17 $cfg['blowfish_secret'] = ''; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */ これでmysqlに設定してあるユーザ名・パスワードでログインできます。 **確認 [#cb4b7524] ウェブ上から確認。 http://*******/phpMyAdmin **最新のバージョンだとlibmcryptが無いと怒られる [#m8b1e10c] # cd /usr/ports/security/libmcrypt # make install clean ・PHPを下記の--with-mysql=/usr/localを加えて再インストール ./configure --with-mysql=/usr/local \ --with-apxs2=/usr/local/apache2/bin/apxs \ --enable-pear --with-tsrm-pth --with-mcrypt=/usr/local \ --with-gd --with-zlib --with-ttf=/usr/local \ --with-freetype-dir=/usr/local --with-jpeg-dir=/usr/local \ --with-png-dir=/usr/local --enable-force-cgi-redirect \ --enable-mbstring --enable-mbstr-enc-trans \ --enable-trans-sid --enable-versioning --enable-gd-native-ttf --enable-gd-jis-conv *デフォルトでログインするように設定する。 [#v0bfc6c8] デフォルトでログインするユーザ名:パスワードを設定する。~ auth_typeをconfigに変更する。 # cd phpMyAdmin # cp config.sample.inc.php config.inc.php # vi config.inc.php 下記を追加 $cfg['Servers'][$i]['user'] = 'root'; $cfg['Servers'][$i]['password'] = 'hogehoge'; $cfg['Servers'][$i]['auth_type'] = 'config'; **この場合アクセスするだけで、ログインできてしまうのでBasic認証をかけておく [#c5084497] # cd phpMyAdmin # vi .htaccess AuthUserFile /home/www/public_html/phpMyAdmin/.htpasswd AuthGroupFile /dev/null AuthName "Please Enter Your Password" AuthType Basic Require valid-user **パスワードファイルの作成 [#yfcdefe4] # htpasswd -c .htpasswd hogehoge New password: Re-type new password: Adding password for user hogehoge **アクセスできるDBを設定する。 [#s3ec9db0] 199 * @global string $cfg['Servers'][$i]['only_db'] 200 */ 201 $cfg['Servers'][$i]['only_db'] = 'shinbutsu';
テキスト整形のルールを表示する
ログインまたはアカウント作成