内容へ移動
fl8 Wiki
ユーザ用ツール
ログイン
サイト用ツール
検索
ツール
文書の表示
以前のリビジョン
バックリンク
最近の変更
メディアマネージャー
サイトマップ
ログイン
>
最近の変更
メディアマネージャー
サイトマップ
現在位置:
Dokuwiki.fl8.jp
»
50 日記
»
2025
»
02
»
2025.02.18 mod_remoteip Apache2.2
トレース:
•
LVM の dm-0 とかの表示をデバイス名に読み替える
•
イメージファイルをfdiskする
•
DELL MegaRC
•
10 fsckでエラー
•
Ubuntu fsck
50_dialy:2025:02:18
この文書は読取専用です。文書のソースを閲覧することは可能ですが、変更はできません。もし変更したい場合は管理者に連絡してください。
====== 2025.02.18 mod_remoteip Apache2.2 ====== 古いOSでApache2.2が動いている場合、mod_remoteipは利用できない。 ※mod_remoteipは、Apache2.4以降 ===== ソースから ===== <code> cd /usr/local/src/ git clone https://github.com/ttkzw/mod_remoteip-httpd22.git cd mod_remoteip-httpd22 </code> ===== Apacheに組み込む ===== <code> apxs -i -c -n mod_remoteip.so mod_remoteip.c </code> ===== confファイル用意 ===== <code> cp -p mod_remoteip.conf /etc/httpd/conf.d/ </code> ===== Cloudflare用に修正 ===== Apache 2.2 では RemoteIPTrustedProxy が使用できないため、RemoteIPInternalProxyを利用 CloudflareのIPリストは、https://www.cloudflare.com/ja-jp/ips/ <code|/etc/httpd/conf.d/mod_remoteip.conf> LoadModule remoteip_module modules/mod_remoteip.so RemoteIPHeader CF-Connecting-IP RemoteIPInternalProxy 127.0.0.1 RemoteIPInternalProxy 173.245.48.0/20 RemoteIPInternalProxy 103.21.244.0/22 RemoteIPInternalProxy 103.22.200.0/22 RemoteIPInternalProxy 103.31.4.0/22 RemoteIPInternalProxy 141.101.64.0/18 RemoteIPInternalProxy 108.162.192.0/18 RemoteIPInternalProxy 190.93.240.0/20 RemoteIPInternalProxy 188.114.96.0/20 RemoteIPInternalProxy 197.234.240.0/22 RemoteIPInternalProxy 198.41.128.0/17 RemoteIPInternalProxy 162.158.0.0/15 RemoteIPInternalProxy 104.16.0.0/13 RemoteIPInternalProxy 104.24.0.0/14 RemoteIPInternalProxy 172.64.0.0/13 RemoteIPInternalProxy 131.0.72.0/22 </code> ===== ログ形式変更 ===== <code|/etc/conf/httpd.conf> LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined ↓ LogFormat "%a %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined </code> {{tag>日記 Cloudflare}}
50_dialy/2025/02/18.txt
· 最終更新: 2025/02/28 07:39 by
matsui
ページ用ツール
文書の表示
以前のリビジョン
バックリンク
文書の先頭へ