2007-06-20, 04:31 PM
when i run the script i get error, log :
Code:
eth1: No such device
IPv6 configuration failed!
the script's code:
Code:
#!/bin/sh
if ! [ -f /proc/net/if_inet6 ]
then echo "IPv6 is not installed!" 1>&2; exit 1; fi
ifconfig sit0 up \
&& ifconfig sit0 inet6 tunnel ::213.121.24.85 \
&& ifconfig sit1 inet6 add 2001:618:400::591:cb1f/128 \
&& route -A inet6 add ::/0 gw fe80::d579:1855 dev sit1 \
&& route -A inet6 add 2000::/3 gw fe80::d579:1855 dev sit1 \
&& ifconfig eth1 up \
&& ifconfig eth1 inet6 add 2001:618:400:b733::/64 \
&& echo 1 > /proc/sys/net/ipv6/conf/all/forwarding \
&& echo 'interface eth1
{
AdvSendAdvert on;
prefix 2001
:618:400:b733::/64
{
AdvOnLink on;
AdvAutonomous on;
};
};' > /etc/radvd.conf \
&& /etc/init.d/radvd start \
&& echo "IPv6 configuration completed" || \
{ echo "IPv6 configuration failed!" 1>&2; exit 1; }
and when i do ifconfig there is:
Code:
snake@delta:~$ ifconfig
eth0 Link encap:Ethernet HWaddr 00:E0:4C:77:CD:1D
inet6 addr: fe80::2e0:4cff:fe77:cd1d/64 Диапазон:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:270656 errors:0 dropped:0 overruns:0 frame:0
TX packets:250379 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:275446383 (262.6 MiB) TX bytes:21518725 (20.5 MiB)
Interrupt:20 Base address:0x2000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Диапазон:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:84 errors:0 dropped:0 overruns:0 frame:0
TX packets:84 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:4817 (4.7 KiB) TX bytes:4817 (4.7 KiB)
ppp0 Link encap:Point-to-Point Protocol
inet addr:89.1.203.31 P-t-P:212.29.206.60 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1492 Metric:1
RX packets:269808 errors:0 dropped:0 overruns:0 frame:0
TX packets:249776 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:3
RX bytes:269452852 (256.9 MiB) TX bytes:15987305 (15.2 MiB)
sit0 Link encap:IPv6-in-IPv4
inet6 addr: ::89.1.203.31/96 Диапазон:Compat
inet6 addr: ::127.0.0.1/96 Диапазон:Unknown
UP RUNNING NOARP MTU:1480 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
sit1 Link encap:IPv6-in-IPv4
inet6 addr: 2001:618:400::591:cb1f/128 Диапазон:Общий
inet6 addr: fe80::5901:cb1f/64 Диапазон:Link
UP POINTOPOINT RUNNING NOARP MTU:1472 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:7 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 b) TX bytes:588 (588.0 b)
any ideas how to solve that problem?
i tryed editing the script and changing all eth1 to eth0 because in ifconfig i dont see any eth1 connection but i got error too
Code:
snake@delta:~$ sudo sh LinuxScript.sh
SIOCSIFADDR: File exists
IPv6 configuration failed!
thanks.