Archive for 'CentOS 5' Category
DHCPサーバーで社内とゲストのセグメントをわける方法
30 3 月 2009
DHCPサーバーで社内とゲストのセグメントをわける方法
今回設定するのは、DHCPサーバーです。
セキュリティを考慮して、
社内PCは共有可能にし、ゲストPCには、インターネットのみを提供するようにします。
ネットワークは、
社内ネットワーク = 192.168.1.0/255.255.255.0
ゲストネットワーク = 192.168.2.0/255.255.255.0
で設定しています。自分の環境に置き換えて読んでください。
参考にしたサイトは、dhcp / iptables を組み合わせた仮想的なネットワーク分離 です。
まず、DHCPをインストールします。
# yum -y install dhcp
# rpm -ql dhcp
/etc/dhcpd.conf
/etc/rc.d/init.d/dhcpd
/etc/rc.d/init.d/dhcrelay
/etc/sysconfig/dhcpd
/etc/sysconfig/dhcrelay
/usr/bin/omshell
/usr/sbin/dhcpd
/usr/sbin/dhcrelay
/usr/share/doc/dhcp-3.0.5
/usr/share/doc/dhcp-3.0.5/IANA-arp-parameters
/usr/share/doc/dhcp-3.0.5/README
/usr/share/doc/dhcp-3.0.5/RELNOTES
/usr/share/doc/dhcp-3.0.5/api+protocol
/usr/share/doc/dhcp-3.0.5/dhcpd.conf.sample ← 設定ファイルのサンプル
/usr/share/doc/dhcp-3.0.5/draft-ietf-dhc-authentication-14.txt
/usr/share/doc/dhcp-3.0.5/draft-ietf-dhc-dhcp-dns-12.txt
/usr/share/doc/dhcp-3.0.5/draft-ietf-dhc-failover-07.txt
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP/dhclient-script.8
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP/dhclient.8
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP/dhclient.conf.5
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP/dhclient.leases.5
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP/dhcp-eval.5
/usr/share/doc/dhcp-3.0.5/ja_JP.eucJP/dhcp-options.5
/usr/share/doc/dhcp-3.0.5/rfc1542.txt
/usr/share/doc/dhcp-3.0.5/rfc2131.txt
/usr/share/doc/dhcp-3.0.5/rfc2132.txt
/usr/share/doc/dhcp-3.0.5/rfc2485.txt
/usr/share/doc/dhcp-3.0.5/rfc2489.txt
/usr/share/doc/dhcp-3.0.5/rfc951.txt
/usr/share/man/man1/omshell.1.gz
/usr/share/man/man5/dhcpd-eval.5.gz
/usr/share/man/man5/dhcpd-options.5.gz
/usr/share/man/man5/dhcpd.conf.5.gz
/usr/share/man/man5/dhcpd.leases.5.gz
/usr/share/man/man8/dhcpd.8.gz
/usr/share/man/man8/dhcrelay.8.gz
/var/lib/dhcpd
/var/lib/dhcpd/dhcpd.leases
設定ファイルのサンプルをコピーして 設定ファイルを編集します。
# cp /usr/share/doc/dhcp-3.0.5/dhcpd.conf.sample /etc/dhcpd.conf
# vi /etc/dhcpd.conf
——————– ここから ——————–
ddns-update-style interim;
ignore client-updates;
# サブネットマスクに注意
subnet 192.168.0.0 netmask 255.255.0.0 {
# 以下 2行を追加 社内ネットワーク用
pool {
deny unknown-clients;
# — default gateway
# 以下、ルーター経由の場合は、ルーターのIPアドレス
# サーバーがルーターの場合は、サーバーのIPアドレス
option routers 192.168.1.1;
# サブネットマスクに注意
option subnet-mask 255.255.255.0;
# 以下 2行をコメントアウト
#option nis-domain "domain.org";
#option domain-name "domain.org";
# 以下、ルーター経由の場合は、ルーターのIPアドレス
# サーバーがルーターの場合は、プロバイダのDNSアドレスをカンマ区切りで
option domain-name-servers 192.168.1.1;
#option [...]
CentOS5 で WEBサイトのスクリーンショット
13 6 月 2008
ImageMagick と firefoxを利用してスクリーンショットを作りたいと思います。
ダウンロード&インストール
ScreenShot で必要なものをyum でインストールする。
1 画像処理に必 [...]
移転のため数日間停止します。
13 6 月 2008いつもごらんいただいている皆様。
ありがとうございます。
このたび当サイトのサーバー機を移転することになりました。
予定では、6月25日から ~ 7月はじめまでの間に移転すると思います。
が、ホームページ停止期間は長 [...]
iTunes Serverの構築
7 4 月 2008CentOS5 & mt-daapd で iTunes Serverの構築
必要なファイルは
howl
libid3tag
mt-daapd
当サイトはこの三つでいけました。
※iTunes は、 [...]
Sambaでユーザーごとの共有
21 3 月 2008Samba設定ファイルを編集
# vi /etc/samba/smb.conf
———-ここから———-
[global]
hosts allow = 127. 192.168.0. 192.168.1. 10.8.0
include = /etc/samba/%G.conf ← 追加する。
———-ここまで———-
# vi /etc/samba/hogehoge.conf ← 管理ユーザー(グループ名を指定)
———-ここから———-
[特殊1]
comment = Public Stuff
path = /home/samba/data1
[...]
