ubuntu 16.04で
ネットワークに接続されている
プリンター(epson プリンタ ep-903a)を
使用できるように、設定してみた
画面左上の電源マークのメニューの中から
システム設定>プリンター>
+追加 タブ
ネットワークプリンタ
Epson EP-903F(192.xxx.xxx.xxx)
接続
DNS-SD経由のLPDネットワークプリンタ
進む
( )ライセンスを受託します
チェック
進む
設定ができた。
ubuntu 16.04で
ネットワークに接続されている
プリンター(epson プリンタ ep-903a)を
使用できるように、設定してみた
画面左上の電源マークのメニューの中から
システム設定>プリンター>
+追加 タブ
ネットワークプリンタ
Epson EP-903F(192.xxx.xxx.xxx)
接続
DNS-SD経由のLPDネットワークプリンタ
進む
( )ライセンスを受託します
チェック
進む
設定ができた。
ubuntu16.04で、
アーカイブマネージにより、
ZIPファイルを解凍すると、ファイル名が文字化けすることがある。
~/.profileに
export UNZIP=”-O CP932″;export ZIPINFO=”-O CP932″
を追加し、再起動により、対策できた。
vim ~/.profile
G 文末へ移動
i 挿入モード
export UNZIP="-O CP932";export ZIPINFO="-O CP932"
esc :wq 上書き終了
参考:
http://roganpalm.com/20160424/1039-08/
Ubuntu fileZilla が固まった時
端末から
> killall filezilla
で、強制終了にて対応できた。
Ubunt16にWordPressと
レスポンシブルWebデザインテーマbizvektorを組み込んでみます
1,Apacheの組み込み
sudo apt -y install apache2
apache2 -v
Server version: Apache/2.4.18 (Ubuntu) Server built: 2016-07-14T12:32:26
apacheを起動する
sudo service apache2 start
Webで確認する
firefox localhost
cat <<EOF > /var/www/html/test.html <html> <hr> hello <hr> </html> EOF
bash: /var/www/html/test.html: 許可がありません
ローカルでなので、
sudo chmod 777 /var/www/html/
cat <<EOF > /var/www/html/test.html <html> <hr> hello <hr> </html> EOF curl 'http://localhost/test.html'
アクセスできた
<html> <hr> hello <hr> </html>
ブラウザでも確認
firefox localhost/test.html
2,PHPを組み込む
sudo apt -y install php
php -v
PHP 7.0.8-0ubuntu0.16.04.2 (cli) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
with Zend OPcache v7.0.8-0ubuntu0.16.04.2, Copyright (c) 1999-2016, by Zend Technologies
cat <<EOF > /var/www/html/phpinfo.php <?php phpinfo(); ?> EOF curl 'http://localhost/phpinfo.php'
firefoxで、アクセスしてみる
firefox localhost/phpinfo.php apacheの再起動を忘れた sudo service apache2 stop sudo service apache2 start
うまくいかない
firefox localhost/phpinfo.php パッケージを追加 sudo apt -y install libapache2-mod-php
firefox localhost/phpinfo.php
うまくいった。
3,mysqlをインストール
sudo apt -y install mysql-server php-mysql
Mysqlのrootのパスワードを聞かれるので、
入力しタブでスペースで、続行する(確認の2回あります)
mysql -u root -p
データベース(wordpress)を作成
wordpressというユーザを作成し、パスワードをwordpress2016とする
rootで入るので、先ほどのパスワードを入力する
mysql -u root -p Enter password: (先ほどのパスワード) create database wordpress; grant all privileges on wordpress.* to wordpress@localhost identified by 'wordpress2016'; flush privileges; exit;
4,WordPressをインストール
WordPressをダウンロードし
ファイルを解凍する
cd /tmp wget http://ja.wordpress.org/wordpress-3.8.1-ja.tar.gz tar zxvf wordpress-3.8.1-ja.tar.gz cp -r wordpress /var/www/html
sudo chown -R www-data:www-data /var/www/html/wordpress
firefox http://localhost/wordpress/
お使いのサーバーの PHP では WordPress に必要な MySQL 拡張を利用できないようです。
ライブラリィ−を追加してみる
sudo apt-get update sudo apt-get install php-curl php-gd php-mbstring php-mcrypt php-xml php-xmlrpc sudo service apache2 stop sudo service apache2 start firefox http://localhost/wordpress/
やはりだめ
お使いのサーバーの PHP では WordPress に必要な MySQL 拡張を利用できないようです。
WordPressのバージョンを上げてみる
cd /tmp sudo rm -rf /var/www/html/wordpress sudo rm -rf /tmp/wordpress wget http://ja.wordpress.org/latest-ja.tar.gz tar -xzvf latest-ja.tar.gz cp -r wordpress /var/www/html sudo chown -R www-data:www-data /var/www/html/wordpress firefox http://localhost/wordpress/
うまくいった。。。。
データベース名:wordpress
ユーザ名:wordpress
パスワード:wordpress2016
データベースのホスト名:localhost
テーブル接頭辞:wp_
「インストール続行」
サイトのタイトル:タイトル
ユーザー名:admin
パスワード:admin_password
パスワード:admin_password
メールアドレス:xxx@yyy.zz
「WordPressをインストール」
5,レスポンシブルWebデザインテーマbizvektorを組み込む
手順は
・テーマの読み込み
・推奨プラグインの読み込み(有効化)
・サンプルデータの読み込み
となります。
5.1 テーマの読み込み
BizVektor
https://bizvektor.com/
のダウンロードページ
https://bizvektor.com/bizvektor.com/about/download/
から、
Download BizVektor ver 1.8.23
を、ダウンロード
外観>テーマ>新規追加
「データのアップロード」
により
先ほど、ダウンロードしたファイルを「参照」で
指定し、
「今すぐインストール」
を、押下
外観>テーマ
選択し、
ダウンロードしたテーマ「BizVektor」
を、有効にしてください。
5.2 推奨プラグインの読み込み(有効化)
に従い、
「プラグイン」→「新規追加」画面より、『お気に入り』画面を表示。
「wordpress.orgユーザー名」のフォームに「bizvektor」と入力して、必要なプラグインをインストール。
インストールした、プラグインを有効化します
プラグインを追加する
5.3 サンプルデータの読み込み
BizVektor クイックスタート
のページの
「サンプルデータ」
を、ダウンロードする
ダウンロードしたデータを
bv_contents_corporate_v20140928.zip
解凍し、
bv_contents_corporate_v20140928.xml
のファイルを読み出す
コンテンツデータのダウンロード・インポート
に従い、コンテンツデータを、インポートする
「ツール」→「インポート」→「WordPress」でダウンロードしたxmlファイルを選択し、「ファイルをアップロードしてインポート」
これで、レスポンシブル対応のWordPressが立ち上がります。
■隘路(ポイント)
「お使いのサーバーの PHP では WordPress に必要な MySQL 拡張を利用できないようです。」
への対策
1,WordPressを最新にする
2,不足しているライブラィーを追加する
sudo apt-get install php-curl php-gd php-mbstring php-mcrypt php-xml php-xmlrpc
3,Apacheを再起動する
sudo service apache2 stop sudo service apache2 start
Redmineのプラグイン
redmine_github_hook.git
を使って、GitとRedmineを連携してみました。
Redmineの配置場所を、
/var/lib/redmine
としますので、
それ以外の場合は、
/var/lib/redmine
の部分を書き換えて下さい
1,プラグインを組み込む
cd /var/lib/redmine/plugins git clone https://github.com/koppen/redmine_github_hook.git
2,Git側で、レポジトリーを作成
GitHubまたは、Gitbucketで、対象のレポジトリを作成
3,サーバ側設定
cd /var/lib/redmine/repo
GitHubの場合
git clone --bare https://github.com/<アカウント名>/<レポジトリ名>.git
Gitbucketの場合
git clone --bare https://<アカウント名>@bitbucket.org/<アカウント名>/<レポジトリ名>.git
キーを登録しSSHで接続する場合は
git clone --bare git@github.com:<アカウント名>/<レポジトリ名>.git
で、可能です。
4,Remindeの再起動し、プラグインを組み込む
cd /var/lib/redmine//tmp touch restart.txt
RedmineのWebでどこかの、画面をアクセスする(または、再表示)
(再起動しても、restart.txtは、消えない)
5,Redmineで、設定
プロジェクトの画面
設定>リポジトリ>新しいリポジトリ
バージョン管理システム:Git
識別子:わかりやすい文字を指定
リポジトリのパス:/var/lib/redmine/repo/<レポジトリ名>.git
パスのエンコーディング:UTF-8
識別子を設定により、
一つのプロジェクトで、識別子名による、切り替えができる
これにより、
Redmineから、
更新履歴、差分、コメントなどを、見ることがき、
更新内容と、Redmine内のチケットと連携(関係付ける)ことができます
6,Gitの最新の手動反映
Gitサーバ側のWebhookにより、
Gitサーバ側の更新時に、Redmineサーバの
更新内容を自動連携する方法がありますが、
以下により、手動反映ができました
cd /var/lib/redmine/repo rm -rf <レポジトリ名>.git git clone --bare https://github.com/<アカウント名>/<レポジトリ名>.git git clone --bare https://<アカウント名>@bitbucket.org/<アカウント名>/<レポジトリ名>.git
7,プラウザからGitの最新の反映
毎回端末で、接続して、反映するのが大変なため、
自動更新を行う
更新方法としては
Cronで行う方法もあるが、
ほどんど更新していないのに、
Gitサーバに問い合わせに行くのは、申し訳ない。
本来,Gitサーバ側で
Service Hooks:WebHook
で、設定を行えばいいのだが、
Redmine側から取りに行く方法で行ってみた。
phpから、Shellを起動してみる
7,1 phpのインストール
phpがあるか確認
php --version -bash: php: コマンドが見つかりません
ないので、phpのインストール
参考:
http://qiita.com/ozawan/items/caf6e7ddec7c6b31f01e
yum install --enablerepo=remi,remi-php56 php php-devel php-mbstring php-pdo php-gd /etc/rc.d/init.d/httpd stop /etc/rc.d/init.d/httpd start
7.2 phpで、shellを起動
参考:
http://php.net/manual/ja/function.shell-exec.php
cat <<EOF > /var/lib/redmine/public/ls.php
<?php
$output = shell_exec('ls -lart');
echo "<pre>$output</pre>";
?>
EOF
xx.xx.xx/ls.php
で、表示を確認
7.3 phpで、gitを起動するプログラムを作成
repoの所有者を変更
chown -R apache:apache /var/lib/redmine/repo
cat <<EOF > /var/lib/redmine/public/git_change.php
<?php
shell_exec('rm -rf /var/lib/redmine/repo/<レポジトリ名>.git');
$output = shell_exec('git clone --bare https://github.com/<アカウント名>/<レポジトリ名>.git');
shell_exec('mv /var/lib/redmine/public/<レポジトリ名>.git /var/lib/redmine/repo/<レポジトリ名>.git');
echo "<pre>$output</pre>";
?>
EOF
同期したいときに
ブラウザから
xx.xx.xx/git_change.php
で、最新情報を読み取る
8 ファイル、フォルダの日本語対応
Redmineサーバ側のGitのバージョンを上げる
CentOS 8.7
の場合、Gitのバージョンは 1.7.1
最新にバージョンを上げる
参考
バージョンを確認する
git --version git version 1.7.1
パッケージを読み込む
yum -y install curl-devel expat-devel gettext-devel openssl-devel zlib-devel perl-ExtUtils-MakeMaker
ソースを読み込み、インストールする
cd wget https://www.kernel.org/pub/software/scm/git/git-2.4.0.tar.gz tar zxvf git-2.4.0.tar.gz cd git-2.4.0 make prefix=/usr/local all make prefix=/usr/local install . ~/.bash_profile git --version git version 2.4.0
最新を読み込み、インストールする
cd /usr/local/src/ git clone git://git.kernel.org/pub/scm/git/git.git cd git make prefix=/usr/local all make prefix=/usr/local install git --version git version 2.9.2.574.gc6b0597
Redmineを再起動する
cd /var/lib/redmine/tmp rm restart.txt touch restart.txt /etc/rc.d/init.d/httpd restart
参考
http://qiita.com/n_slender/items/54cd282c140fadbbb322
http://symfoware.blog68.fc2.com/blog-entry-1694.html
1,パッケージインストール
|
1 |
yum -y install git gcc gcc-c++ libcurl-devel httpd httpd-devel openssl-devel readline-devel zlib-devel curl-devel mysql-server mysql-devel ImageMagick ImageMagick-devel ipa-pgothic-fonts |
2,EPELリポジトリの登録
|
1 |
rpm -ivh http://ftp.riken.jp/Linux/fedora/epel/6/x86_64/epel-release-6-8.noarch.rpm |
3,開発ツール・インストール
|
1 |
yum -y groupinstall "Development Tools" |
4,Rubyをインストール
|
1 2 3 4 5 6 |
git clone https://github.com/sstephenson/rbenv.git ~/.rbenv echo 'export PATH="$HOME/.rbenv/bin:$PATH"'>> ~/.bashrc echo 'eval "$(rbenv init -)"' >> ~/.bashrc source ~/.bashrc mkdir ~/.rbenv/plugins cd ~/.rbenv/plugins |
|
1 |
git clone git://github.com/sstephenson/ruby-build.git |
10分ほどかかります。
|
1 |
rbenv install 2.2.5 |
|
1 |
rbenv shell 2.2.5 |
5,bundlerインストール
|
1 |
gem install bundler |
6,MySQL redmine用の設定
|
1 2 3 4 5 6 7 8 9 10 11 12 13 |
service mysqld start mysql -u root update mysql.user set password=password('centos') where user = 'root'; flush privileges; exit; mysql -u root -p Enter password:centos create database db_redmine default character set utf8; grant all on db_redmine.* to user_redmine@localhost identified by 'redmine'; flush privileges; exit; |
7,redmineインストール
|
1 2 3 |
curl -O http://www.redmine.org/releases/redmine-3.3.0.tar.gz tar zxvf redmine-3.3.0.tar.gz mv redmine-3.3.0 /var/lib/redmine |
8,DB情報設定
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
cd /var/lib/redmine/config cat <<EOF > database.yml production: adapter: mysql2 database: db_redmine host: localhost username: user_redmine password: redmine encoding: utf8 EOF cd /var/lib/redmine bundle install --without development test --path vendor/bundle bundle exec rake generate_secret_token RAILS_ENV=production bundle exec rake db:migrate RAILS_ENV=production REDMINE_LANG=ja bundle exec rake redmine:load_default_data |
9,Passengerインストール
|
1 2 3 4 5 6 7 |
cd /var/lib/redmine gem install passenger --no-rdoc --no-ri passenger-install-apache2-module passenger-install-apache2-module --snippet > /etc/httpd/conf.d/passenger.conf chown -R apache:apache /var/lib/redmine |
10,httpd設定
|
1 2 3 4 |
vim /etc/httpd/conf/httpd.conf #DocumentRoot "/var/www/html" ↓↓ DocumentRoot "/var/lib/redmine/public" |
DocumentRootで検索 /DocumentRoot
|
1 2 3 4 |
chown -R apache:apache /var/lib/redmine chmod o+x /root/ /etc/rc.d/init.d/httpd start |
11,Redmineへアクセス
サーバとトップへアクセス
|
1 |
http://xxx.xxx.xxx.xxx |
1,パッケージインストール
|
1 |
yum -y install git gcc gcc-c++ libcurl-devel httpd httpd-devel openssl-devel readline-devel zlib-devel curl-devel mysql-server mysql-devel ImageMagick ImageMagick-devel ipa-pgothic-fonts |
2,EPELリポジトリの登録
|
1 |
rpm -ivh http://ftp.riken.jp/Linux/fedora/epel/6/x86_64/epel-release-6-8.noarch.rpm |
3,開発ツール・インストール
|
1 |
yum -y groupinstall "Development Tools" |
4,Rubyをインストール
|
1 2 3 4 5 6 7 8 9 10 11 |
git clone https://github.com/sstephenson/rbenv.git ~/.rbenv echo 'export PATH="$HOME/.rbenv/bin:$PATH"'>> ~/.bashrc echo 'eval "$(rbenv init -)"' >> ~/.bashrc source ~/.bashrc mkdir ~/.rbenv/plugins cd ~/.rbenv/plugins git clone git://github.com/sstephenson/ruby-build.git rbenv install 2.0.0-p648 rbenv shell 2.0.0-p648 |
5,bundlerインストール
|
1 |
gem install bundler |
6,MySQL redmine用の設定
|
1 2 3 4 5 6 7 8 9 10 11 12 13 |
service mysqld start mysql -u root update mysql.user set password=password('centos') where user = 'root'; flush privileges; exit; mysql -u root -p Enter password:centos create database db_redmine default character set utf8; grant all on db_redmine.* to user_redmine@localhost identified by 'redmine'; flush privileges; exit; |
7,redmineインストール
|
1 2 3 |
curl -O http://www.redmine.org/releases/redmine-2.5.0.tar.gz tar zxvf redmine-2.5.0.tar.gz mv redmine-2.5.0 /var/lib/redmine |
8,DB情報設定
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
cd /var/lib/redmine/config cat <<EOF > database.yml production: adapter: mysql2 database: db_redmine host: localhost username: user_redmine password: redmine encoding: utf8 EOF cd /var/lib/redmine bundle install --without development test cd /var/lib/redmine/config bundle exec rake generate_secret_token RAILS_ENV=production bundle exec rake db:migrate |
9,Passengerインストール
|
1 2 3 4 5 6 7 |
cd /var/lib/redmine gem install passenger --no-rdoc --no-ri passenger-install-apache2-module passenger-install-apache2-module --snippet > /etc/httpd/conf.d/passenger.conf chown -R apache:apache /var/lib/redmine |
10,httpd設定
|
1 2 3 4 |
vim /etc/httpd/conf/httpd.conf #DocumentRoot "/var/www/html" ↓↓ DocumentRoot "/var/lib/redmine/public" |
DocumentRootで検索 /DocumentRoot
|
1 2 3 4 |
chown -R apache:apache /var/lib/redmine chmod o+x /root/ /etc/rc.d/init.d/httpd start |
11,Redmineへアクセス
サーバとトップへアクセス
|
1 |
http://xxx.xxx.xxx.xxx |
注意点(ポイント)
1,redmine-2.5.0の場合、Rubyのバージョンが依存する(2.0.0-p648)
2.2.3だとだめだった
2,chmod o+x /root/ をしないとダメだった
画面表示されない時はログファイルでエラーの内容を確認
find / -name error_log
cat /var/log/httpd/error_log
参考
http://j-orangepekoe.blog.so-net.ne.jp/2016-03-02
http://www.aetherworks.org/article/112066375.html
http://qiita.com/mozo/items/6ec0151dad350c051399
http://blog.redmine.jp/articles/2_5/installation_centos/
http://blog.redmine.jp/articles/3_2/install/centos/
Ubuntu16 で、漢字入力を設定する
システム設定>言語サポート
を選択する
必要な言語パッケージがインストールされる
インストールされたた、
システム設定>テキスト入力
から、
日本語を選択し
ー
ボタンで、削除する
+
ボタンで、追加を指定し
日本語(Mozc)(IBus)
を選択し、追加する
切り替えにカーソルを移動し、半角/全角
ボタンで、変換ボタンを指定する
矢印で、
日本語(Mozc)(IBus)
を、一番上にする
入力する場所で、変換ボタンを押して
入力が切り替えるのを見る(右上)
日本語変換になった時に
切り替えの表示を
クリックし、入力モードをひらがなにする
Ubuntu16 に、Chromeをインスツールします
https://www.google.co.jp/chrome/browser/desktop/
から、パッケージをダウンロードする
gdebiをダウンロードする
sudo apt -y install gdebi
ダウンロードしたフォルダーから
google-chrome-stable_current_amd64.deb
を、右クリックで、gdebiを選択して
インストールを行う
完了したら、左上のコンピュータ検索から
chrome
で検索する
ドラッグして、メニューに追加する
検索で表示されない場合には
端末から
google-chrome
で、一度、起動する
左上のコンピュータ検索から
chrome
で検索する
ドラッグして、メニューに追加する
CentOS 6.7にWordPressとレスポンシブルWebデザインテーマbizvektorを組み込んでみる
CentOs に WordPressをインストールする
root権限になっていなければ、rootになる
$su パスワード: #
各種パッケージ
httpd mysql-server php php-mysql wget
をインストールする
yum -y install httpd mysql-server php php-mysql wget
apacheがインストールされたか確認
/etc/init.d/httpd status httpd は停止しています
apacheを起動する
/etc/init.d/httpd start
httpd を起動中: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName
[ OK ]
localhostにアクセスする
curl 'http://localhost/'
firefoxで、アクセスしてみる
firefox localhost/
タイムゾーンの設定
PHPの設定ファイル(/etc/php.ini)を編集する。
vim /etc/php.ini
date.timezone =を検索(”/”は検索)
/date.timezone =
iで、挿入モードにして
#date.timezone =
date.timezone = “Asia/Tokyo”
に変更
; Defines the default timezone used by the date functions ; http://www.php.net/manual/en/datetime.configuration.php#ini.date.timezone #date.timezone = date.timezone = "Asia/Tokyo"
esc+:wq
で、上書き終了
apacheを再起動
/etc/init.d/httpd restart
httpd を停止中: [ OK ]
httpd を起動中: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName
[ OK ]
Webが起動し、PHPが走っているか確認する
cat <<EOF > /var/www/html/phpinfo.php <?php phpinfo(); ?> EOF curl 'http://localhost/phpinfo.php'
firefoxで、アクセスしてみる
firefox localhost/phpinfo.php
mysqlがインストールされたか確認
/etc/init.d/mysqld status mysqld は停止しています
mysqlを起動する
/etc/init.d/mysqld start : mysqld を起動中: [ OK ]
パスワードを設定(rootにパスワードcentosと設定してみた)
mysql -u root
update mysql.user set password=password('centos') where user = 'root';
flush privileges;
exit;
設定したパスワードでログインできるかを確認します。
# mysql -u root -p Enter password: exit;
データベース(wordpress)を作成
wordpressというユーザを作成し、パスワードをwordpress2016とする
# mysql -u root -p Enter password: create database wordpress; grant all privileges on wordpress.* to wordpress@localhost identified by 'wordpress2016';
WordPressをインストール
WordPressをダウンロードし
ファイルを解凍し、
Apacheが読み込めるようにする。
cd /tmp wget http://ja.wordpress.org/wordpress-3.8.1-ja.tar.gz tar zxvf wordpress-3.8.1-ja.tar.gz cp -r wordpress /var/www/ chown -R apache.apache /var/www/wordpress
apacheの設定を行う
vim /etc/httpd/conf/httpd.conf
DocumentRoot “/var/www/html
DocumentRoot “/var/www/wordpress”
に変更
DocumentRoot “/var/www/htmlを検索
/DocumentRoot "/var/www/html
DocumentRoot “/var/www/wordpress”
に変更
iで、挿入モードに入る
#DocumentRoot "/var/www/html" DocumentRoot "/var/www/wordpress "
次に、
<Directory "/var/www/html">
を
<Directory "/var/www/wordpress">
に変更
一度、ESCで、コマンドモードに戻り
/<Directory "/var/www/html">
で、検索
挿入モードiで、
#<Directory "/var/www/html"> <Directory "/var/www/wordpress">
に、修正
次に、
<Directory "/var/www/wordpress">
の中の
AllowOverride None
を、
AllowOverride All
に変更
# AllowOverride None
AllowOverride All
に変更
esc+:wq
を指定
apacheを再起動
/etc/init.d/httpd restart
httpd を停止中: [ OK ]
httpd を起動中: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName
[ OK ]
fierfoxで、アクセスする
firefox localhost/
データベース名:wordpress
ユーザ名:wordpress
パスワード:wordpress2016
データベースのホスト名:localhost
テーブル接頭辞:wp_
「インストール続行」
サイトのタイトル:タイトル
ユーザー名:admin
パスワード:admin_password
パスワード:admin_password
メールアドレス:xxx@yyy.zz
「WordPressをインストール」
成功しました !
「ログイン」
にて、開始画面へ
WordPress 4.5.3 が利用可能です ! 更新してください。
とのメッセージがあるため、
WordPress 4.5.3に更新する
WordPress の新しいバージョンがあります。
「今すぐ更新」
を押下
更新の後、ログイン画面に戻るので、
ログイン後、
プラグインを「今すぐ更新」を押下
次に、レスポンシブルWebデザインテーマbizvektorを組み込んでみる
BizVektor
のダウンロードページ
から、
Download BizVektor ver 1.8.23
を、ダウンロード
外観>テーマ>新規追加
「データのアップロード」
により
先ほど、ダウンロードしたファイルを「参照」で
指定し、
「今すぐインストール」
を、押下
外観>テーマ
選択し、
ダウンロードしたテーマ「BizVektor」
を、有効にしてください。
に従い、
「プラグイン」→「新規追加」画面より、『お気に入り』画面を表示。
「wordpress.orgユーザー名」のフォームに「bizvektor」と入力して、必要なプラグインをインストール。
インストールした、プラグインを有効化します
プラグインを追加する
プラグインが、有効にならない場合、
必要なライブラィーを追加する
お使いの WP Multibyte Patch を有効化するには PHP の mbstring 関数が必要です。
yum -y install php-mbstring
apacheを再起動
/etc/init.d/httpd restart
httpd を停止中: [ OK ]
httpd を起動中: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName
[ OK ]
コンテンツデータのダウンロード・インポート
に従い、コンテンツデータを、インポートする
「ツール」→「インポート」→「WordPress」でダウンロードしたxmlファイルを選択し、「ファイルをアップロードしてインポート」
インストール時のエラーが分からないので、
エラー表示を有効にする
vim /etc/php.ini
display_errors = Off
変更前
display_errors = On
変更後
display_errors =を検索し
/display_errors =
i挿入モードで
;display_errors = Off display_errors = On
に変更
esc+:wqで上書き終了
apacheを再起動
/etc/init.d/httpd restart
httpd を停止中: [ OK ]
httpd を起動中: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName
[ OK ]
WordPress インポートできない時の対処方法
Fatal error: Class ‘DOMDocument’ not found
yum -y install php-xml
再度、apacheを再起動
/etc/init.d/httpd restart
httpd を停止中: [ OK ]
httpd を起動中: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain for ServerName
[ OK ]
サンプルデータが表示できた・・・
apacheとmysqlを自動起動に設定する
現状の確認
apacheは
chkconfig --list | grep httpd
offになっている
httpd 0:off 1:off 2:off 3:off 4:off 5:off 6:off
自動起動(on)に設定
chkconfig httpd on
onになった
chkconfig --list | grep httpd httpd 0:off 1:off 2:on 3:on 4:on 5:on 6:off
mysqlの設定も
chkconfig --list | grep mysqld
offになっている
mysqld 0:off 1:off 2:off 3:off 4:off 5:off 6:off
onにする
chkconfig mysqld on chkconfig --list | grep mysqld mysqld 0:off 1:off 2:on 3:on 4:on 5:on 6:off
一応chromeもインストールしておく
wget http://chrome.richardlloyd.org.uk/install_chrome.sh bash ./install_chrome.sh
テーマ、記事などを、修正削除していて、
うまく行かなくなり、削除し、再インストーツする場合。
wordpressが残っている確認する
cd /tmp ls wordpress
もし、なければ、再度、ダウンロード
cd /tmp wget http://ja.wordpress.org/wordpress-3.8.1-ja.tar.gz tar zxvf wordpress-3.8.1-ja.tar.gz
コンテンツ側(/var/www/wordpress)を削除し、
再度、複写する
rm -rf /var/www/wordpress cp -r wordpress /var/www/ chown -R apache.apache /var/www/wordpress
Webより、再度設定する
firefox localhost/
データベーステーブルの接頭辞は、
一応、wp1_に変えておく
エラー対策まとめ、
■プラグイン有効時(WP Multibyte Patch)でのエラー
[/html]
yum -y install php-mbstring
/etc/init.d/httpd restart
[/html]
■サンプルデータのインポート時に無反応
vim /etc/php.ini にて、 display_errors = On /etc/init.d/httpd restart
■サンプルデータのインポート時のエラー
yum -y install php-xml /etc/init.d/httpd restart
■サンプルデータ読み込み時の、infoエラー
をインポートできませんでした。投稿タイプ info が有効ではありません。
テーマが、「BizVektor」に切り替わっていない
外観>テーマで、
「BizVektor」を有効化