2,235 views
この記事は最終更新から 3164日 が経過しています。
wget コマンドは、httpや ftpプロトコルでファイルを取得できる。
[user@ ~]$ wget http://www.xxxxxxx.xxx/page1/
再帰的に全ファイルを取得する場合は -r オプションを指定する。
[user@ ~]$ wget -r http://www.xxxxxxx.xxx/page1/
再帰的にN階層目までファイルを取得する場合は -l N オプションを指定する。
例えば、3階層目までで -l 3 とする。
[user@ ~]$ wget -l 3 http://www.xxxxxxx.xxx/page1/
その他のオプションは man で見る。
[user@ ~]$ man wget
アクセス数(直近7日): ※試験運用中、BOT除外簡易実装済2026-01-25: 1回 2026-01-24: 0回 2026-01-23: 0回 2026-01-22: 0回 2026-01-21: 1回 2026-01-20: 1回 2026-01-19: 3回