9 lines
217 B
Plaintext

#!/bin/bash
ifconfig eth2 down && \
ifconfig eth2 hw ether [ETH2MAC] && \
ifconfig eth2 [ETH2IP] netmask [ETH2MASK] && \
ifconfig eth2 up && \
ip route add default via [GATEWAY] dev eth2 && \
service dnsmasq restart