カテゴリー: linux ubuntu
CATEGORY ARCHIVE
As the following warning appeared after introducing of a domain name, I fixed it
by modifying of /etc/hosts.
Warning:
apache2: Could not reliably determine the server’s fully qualified domain name,
using 127.0.1.1 for ServerName
Fix:
sudo nano /etc/hosts
before
127.0.1.1 host_name
after
127.0.1.1 domain_name host_name
Then restart apache.
simle DNS
―――- server side ――
$ sudo apt-get update
$ sudo apt-get install dnsmasq
$ sudo nano /etc/hosts
192.168.2.199 windows7pro
192.168.2.197 debian
192.168.2.198 centos6
192.168.2.192 ubuntu
――― linux client side ――
add
dns-nameserver ‘IP of setted dnsmasq server’
なお、一番先頭にもってこないと、debian以外はうまくいかず
――――-added on 2016/3/13 ――――――
Don’t forget updating of /etc/resolv.conf
――――――――――――――――――――
――― windows client side ――
properties でDNSに追加
詳細設定のDNSのところで、さらに、
a single period (.) を追加が必要
―added on 2016/3/13――――――
at command prompt, the following command may be necessary ipconfig /flushdns
―added on 2016/3/19―――――――-
If and When the dnsmasq server is rebooted, “ipconfig/flushdns” may be necessary.
Though I don’t know why.
―-added on 2016/4/11―――――――
I don’t know the reason,but windows side couldn’t resolve right IP address. Restarting of Windows was necessary.
下記のコメンドを駆使してみる
apt-cache search キーワード #検索
apt-cache show パッケージ名 #パッケージ情報
apt-cache showpkg パッケージ名 #依存関係、被依存関係表示
apt-get -f install
dpkg -l #インストールされたpkgの表示
dpkg -l パッケージ名 # パッケージ情報
dpkg -L パッケージ名 # PKG内ファイル一覧
dpkg -r パッケージ ??
sudo dpkg -configure パッケージ名 #不完全な状態のPKGを再設定
sudo dpkg -configure -a 全て再設定
$ sudo apt-get ?purge remove パッケージ名
$ sudo apt-get clean
依存関係の修復には、以下のコマンドを用います。
$ sudo apt-get -f install
このコマンドにより、依存関係を満たすために必要なパッケージのダウンロード、インストールができるらしい。
パッケージの設定で問題が発生している場合は、以下のコマを試してみる
$ sudo dpkg ?configure -a
修復できない場合は、パッケージを削除し、キャッシュも消す。
$ sudo apt-get ?purge remove パッケージ名
$ sudo apt-get clean
再ダウンロードしたものをインストールしてみる。
$ sudo apt-get update
$ sudo apt-get install パッケージ名