4
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

linuxで一時的にIPとデフォルトゲートウェイを変更

Last updated at Posted at 2015-04-28

1. 現在設定しているデフォルトゲートウェイを削除

sudo /sbin/route del default gw 192.168.0.1

2. IPを取得

sudo /sbin/dhclient eth0
  • /etc/resolv.conf が書き換わるので後で戻すの忘れないこと。

3. デフォルトゲートウェイを設定

sudo /sbin/route add default gw 192.168.11.1
4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?