Skip to content

spirit posteets tagged route

 

  • 8 years ago
    1. # Use of ip command
    2. ip route add 192.168.55.0/24 via 192.168.1.254 dev eth1
    3. route add -net 192.168.55.0 netmask 255.255.255.0 gw 192.168.1.254 dev eth1
    4. #———————————————-
    5. # Red Hat/Fedora Linux Static route file
    6. #———————————————-
    7. cat /etc/sysconfig/network-scripts/route-eth0
    8. GATEWAY0=192.168.1.254
    9. NETMASK0=255.255.255.0
    10. ADDRESS0=192.168.55.0
    11. GATEWAY1=10.164.234.112
    12. NETMASK1= 255.255.255.240
    13. ADDRESS1=10.164.234.132
    14. #————————————
    15. # Debian Linux static routes file
    16. #————————————
    17. cat /etc/network/interface
    18. auto eth0
    19. iface eth0 inet static
    20. address 192.168.1.2
    21. netmask 255.255.255.0
    22. gateway 192.168.1.254
    23. up route add -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.2.1
    24. down route del -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.2.1
  • 8 years ago and saved by 1 other
    1. # Pour ajouter une route vers le réseau 192.168.1.1/24 à travers la passerelle 172.10.10.1
    2. route add 192.168.1.1 mask 255.255.255.0 172.10.10.1
    3. # Pour que la route soit permanente :
    4. route -p add 192.168.1.1 mask 255.255.255.0 172.10.10.1
  • 8 years ago and saved by 2 others
    1. #ajouter une route par defaut
    2. route add default gw 192.168.0.1
    3. #afficher les routes
    4. route -n
    5. # supprimer une route
    6. route del -net 192.168.0.1/24

    “route” related tags

    spirit’s tags