-
plauria
- Posts: 11
- Joined: Wed Jul 23, 2014 6:57 pm
On boot: «either «local» is duplicate, or «/24″ is garbage»
Hi all,
I’m using the 0.92 version of the RP software. I am trying to give my redpitaya a static IP for use on a switch. Here is my /etc/network/interfaces file:
Code: Select all
###########################
# lo: Loopback interface #
###########################
auto lo
iface lo inet loopback
######################################
# eth0: Wired Ethernet - 1000Base-T #
######################################
#
# Uncomment only one: dynamic or static configuration.
#
# Dynamic (DHCP) IP address
#iface eth0 inet dhcp
# Dynamic (DHCP) IP address
#iface eth0 inet dhcp
# udhcpc_opts -t7 -T3
# Static IP address
# Don't forget to set the static DNS IP in sd:/etc/init.d/rcS too.
iface eth0 inet static
address 192.168.1.222
netmask 255.255.255.0
gateway 0.0.0.0
The network doesn’t work, and the relevant bootup message regarding eth0 is given in the subject line.
To get it to work, I have to log into the RP using serial console, then do
Code: Select all
ifconfig eth0 down
ifconfig eth0 192.168.1.222
ifconfig eth0 up
Then it works fine. Why do I have to do this every time I boot the RP? What’s going on? I must be missing something…
-
Nils Roos
- Posts: 1441
- Joined: Sat Jun 07, 2014 12:49 pm
- Location: Königswinter
Re: On boot: «either «local» is duplicate, or «/24» is garb
Post
by Nils Roos » Tue Oct 07, 2014 12:18 am
I must be missing something…
You are ! Two things, possibly:
1. You also need to put your static configuration into the /etc/network/config file
Code: Select all
...
NETWORK=static
# Static network configuration parameters (active if NETWORK=static)
IP=...
NETMASK=...
GATEWAY=...
2. Since a few commits back, the access-point («ap») configuration has become the default. If you are using the latest version from github repo, there is now a separate file /etc/network/interfaces.ap where you also need to change the settings.
The latter point has not yet been documented, unfortunately.
edit: Hmmm, just tested without the first change, I didn’t get the same messages as you did …
-
plauria
- Posts: 11
- Joined: Wed Jul 23, 2014 6:57 pm
Re: On boot: «either «local» is duplicate, or «/24» is garb
Post
by plauria » Tue Oct 07, 2014 5:48 pm
Thanks for the reply, but neither of those files exist in /etc/network. When I create them, they are gone by next boot.
I’m using a stable release; on boot it reports this version: Red Pitaya GNU/Linux/Ecosystem version 0.92-378
-
plauria
- Posts: 11
- Joined: Wed Jul 23, 2014 6:57 pm
Re: On boot: «either «local» is duplicate, or «/24» is garb
Post
by plauria » Tue Oct 07, 2014 6:05 pm
OK, I think I’ve discovered the error. Running ifup -v eth0 results in:
Code: Select all
redpitaya> ifup -fv eth0
run-parts /etc/network/if-pre-up.d
ip addr add 192.168.1.222 /24 dev eth0 label eth0
ip: either "local" is duplicate, or "/24" is garbage
ip link set eth0 up
ip route add default via 0.0.0.0 dev eth0
ip: RTNETLINK answers: File exists
There’s a typo in the `ip` command!!! There should be no space between 222 and /24! Running the commands without the space between 222 and /24 and the RP works now.
I just checked my /etc/network/interfaces file and there is a stray space at the end of the IP address! This was getting collected by ifup, and hence causing the erroneous command. This should be noted in the wiki I think!
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie
Who is online
Users browsing this forum: No registered users and 4 guests
View previous topic :: View next topic | |||||||||
Author | Message | ||||||||
---|---|---|---|---|---|---|---|---|---|
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
SeaTiger l33t Joined: 22 Nov 2007 |
|
||||||||
Back to top |
|
||||||||
d2_racing Bodhisattva Joined: 25 Apr 2005 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
SeaTiger l33t Joined: 22 Nov 2007 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
SeaTiger l33t Joined: 22 Nov 2007 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
lxg Veteran Joined: 12 Nov 2005 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
lxg Veteran Joined: 12 Nov 2005 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
lxg Veteran Joined: 12 Nov 2005 |
|
||||||||
Back to top |
|
||||||||
pneula n00b Joined: 16 Jan 2009 |
|
||||||||
Back to top |
|
||||||||
|
You cannot post new topics in this forum |
Debian Bug report logs —
#729882
Error: either «local» is duplicate, or «eth0» is a garbage
Reported by: Wolfgang Hotwagner <lister@feedyourhead.at>
Date: Mon, 18 Nov 2013 16:15:02 UTC
Severity: normal
Found in version openswan/1:2.6.37-3
Fixed in version 1:2.6.38-1+rm
Done: Debian FTP Masters <ftpmaster@ftp-master.debian.org>
Bug is archived. No further changes may be made.
Toggle useless messages
Report forwarded
to debian-bugs-dist@lists.debian.org, Rene Mayrhofer <rmayr@debian.org>
:
Bug#729882
; Package openswan
.
(Mon, 18 Nov 2013 16:15:06 GMT) (full text, mbox, link).
Acknowledgement sent
to Wolfgang Hotwagner <lister@feedyourhead.at>
:
New Bug report received and forwarded. Copy sent to Rene Mayrhofer <rmayr@debian.org>
.
(Mon, 18 Nov 2013 16:15:06 GMT) (full text, mbox, link).
Message #5 received at submit@bugs.debian.org (full text, mbox, reply):
Package: openswan Version: 1:2.6.37-3 Severity: normal Dear Maintainer, I do have one network-interface with multiple alias addresses: ip addr: 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 08:00:27:d2:69:ff brd ff:ff:ff:ff:ff:ff inet 172.17.0.202/24 brd 172.17.0.255 scope global eth0 inet 172.17.0.232/24 scope global secondary eth0 inet6 fe80::a00:27ff:fed2:69ff/64 scope link valid_lft forever preferred_lft forever If i startup ipsec, i'll recieve the following error: root@Wheezy2:~# /etc/init.d/ipsec restart ipsec_setup: Stopping Openswan IPsec... ipsec_setup: Starting Openswan IPsec 2.6.37-g955aaafb-dirty... ipsec_setup: ipsec0 -> NULL mtu=0(0) -> 0 ipsec_setup: Error: either "local" is duplicate, or "eth0" is a garbage. ipsec_setup: Error: either "local" is duplicate, or "eth0" is a garbage. This only happens, if i use the address 172.17.0.232 If i use the main-ip(172.17.0.202) of the interface, the problem doesn't appear. This is a big problem for me, since i want to use openswan on a heartbeat-shared-ip-address. Thank you very much Wolfgang Hotwagner -- System Information: Debian Release: 7.2 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 3.2.0-4-amd64 (SMP w/1 CPU core) Locale: LANG=de_AT@euro, LC_CTYPE=iso_8859_1 (charmap=ISO-8859-15) (ignored: LC_ALL set to de_AT@euro) Shell: /bin/sh linked to /bin/dash Versions of packages openswan depends on: ii bind9-host [host] 1:9.8.4.dfsg.P1-6+nmu2+deb7u1 ii bsdmainutils 9.0.3 ii debconf [debconf-2.0] 1.5.49 ii host 1:9.8.4.dfsg.P1-6+nmu2+deb7u1 ii iproute 20120521-3+b3 ii ipsec-tools 1:0.8.0-14 ii libc6 2.13-38 ii libcurl3 7.26.0-1+wheezy5 ii libgmp10 2:5.0.5+dfsg-2 ii libldap-2.4-2 2.4.31-1+nmu2 ii libpam0g 1.1.3-7.1 ii openssl 1.0.1e-2 openswan recommends no packages. Versions of packages openswan suggests: pn curl <none> pn openswan-doc <none> pn openswan-modules-source | openswan-modules-dkms <none> -- Configuration Files: /etc/ipsec.conf changed: version 2.0 # conforms to second version of ipsec.conf specification config setup # Do not set debug options to debug configuration issues! # plutodebug / klipsdebug = "all", "none" or a combation from below: # "raw crypt parsing emitting control klips pfkey natt x509 dpd private" # eg: # plutodebug="control parsing" # Again: only enable plutodebug or klipsdebug when asked by a developer # # enable to get logs per-peer # plutoopts="--perpeerlog" # # Enable core dumps (might require system changes, like ulimit -C) # This is required for abrtd to work properly # Note: incorrect SElinux policies might prevent pluto writing the core dumpdir=/var/run/pluto/ # # NAT-TRAVERSAL support, see README.NAT-Traversal nat_traversal=yes # exclude networks used on server side by adding %v4:!a.b.c.0/24 # It seems that T-Mobile in the US and Rogers/Fido in Canada are # using 25/8 as "private" address space on their 3G network. # This range has not been announced via BGP (at least upto 2010-12-21) virtual_private=%v4:10.0.0.0/8,%v4:192.168.0.0/16,%v4:172.16.0.0/12,%v4:25.0.0.0/8,%v6:fd00::/8,%v6:fe80::/10 # OE is now off by default. Uncomment and change to on, to enable. oe=off # which IPsec stack to use. auto will try netkey, then klips then mast protostack=auto # Use this to log to a file, or disable logging on embedded systems (like openwrt) #plutostderrlog=/dev/null interfaces="ipsec0=eth0:0" conn %default keyexchange=ike keyingtries=0 authby=secret ike=aes256-sha1;modp2048 ikelifetime=28800s auth=esp phase2alg=aes256-sha1;modp2048 keylife=28800s pfs=yes compress=yes dpddelay=10 dpdtimeout=120 left=172.17.0.232 -- debconf information excluded
Reply sent
to Debian FTP Masters <ftpmaster@ftp-master.debian.org>
:
You have taken responsibility.
(Tue, 01 Jul 2014 11:30:54 GMT) (full text, mbox, link).
Notification sent
to Wolfgang Hotwagner <lister@feedyourhead.at>
:
Bug acknowledged by developer.
(Tue, 01 Jul 2014 11:30:54 GMT) (full text, mbox, link).
Message #10 received at 729882-done@bugs.debian.org (full text, mbox, reply):
Version: 1:2.6.38-1+rm Dear submitter, as the package openswan has just been removed from the Debian archive unstable we hereby close the associated bug reports. We are sorry that we couldn't deal with your issue properly. For details on the removal, please see https://bugs.debian.org/736557 The version of this package that was in Debian prior to this removal can still be found using http://snapshot.debian.org/. This message was generated automatically; if you believe that there is a problem with it please contact the archive administrators by mailing ftpmaster@ftp-master.debian.org. Debian distribution maintenance software pp. Scott Kitterman (the ftpmaster behind the curtain)
Bug archived.
Request was from Debbugs Internal Request <owner@bugs.debian.org>
to internal_control@bugs.debian.org
.
(Wed, 30 Jul 2014 07:32:27 GMT) (full text, mbox, link).
Send a report that this bug log contains spam.
Debian bug tracking system administrator <owner@bugs.debian.org>.
Last modified:
Thu Feb 9 13:26:18 2023;
Machine Name:
buxtehude
Debian Bug tracking system
Debbugs is free software and licensed under the terms of the GNU
Public License version 2. The current version can be obtained
from https://bugs.debian.org/debbugs-source/.
Copyright © 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson,
2005-2017 Don Armstrong, and many other contributors.
- Печать
Страницы: [1] Вниз
Тема: Наследство дяди билли или куда копать??? (Прочитано 3227 раз)
0 Пользователей и 1 Гость просматривают эту тему.
Pride_Winner
Прошу прощения предыдущую тему не успел поправить. Вот суть проблемы, подскажите новичку. Работало вот так Сервер с win2008 получает интернет от провайдера ppp0e через сетевую карту 1, отдает ее в локальную сеть через карточку2, которая имеет ип адреса 192.168.0.2 и 192.168.3.100. В бугалтерии стоит сервер win2003, одна карточка смотрит в локалку на 192.168.0.2 имеет ип адрес 192.168.0.116. Вторая карточка win2003 смотрит в локалку с бугалтерами имеет параметры ип 192.168.2.2, шлюз непрописан. днс 192.168.2.2. Все «чудно» работает. это настраивалось до меня и моего старшего. Севодня я заменил сервер win2008 сервером с Ubuntu. все комьпьютеры нормально получают интернет и подмены незаметили. НО в бугалтерии компьютеры подключенные к2003 серверу интернет неполучают, на самом 2003 он есть. У Ubuntu интернет приходит по eth0, ppp0 подключение, а раздаеться eth1 192.168.0.2. дописал в /etc/sysctl.conf net.ipv4.ip_forward=1 выполнил sysctl -w net.ipv4.ip_forward=«1»
iptables -v -t nat -A POSTROUTING -o ppp0 -j MASQUERADE У всех есть инет кроме пользователей сервера вин2003 Вот скришоты из вин2008 настройки сети http://yadi.sk/d/NRAXaHNc7pHAD http://yadi.sk/d/IeM3plU87pHCB http://yadi.sk/d/zdTtsVXL7pHE9 Я так понимаю мне нужно в Ubuntu сделать статические маршруты как сдесь? http://yadi.sk/d/IeM3plU87pHCB
fisher74
sudo ip r add 192.168.2.0/24 gw 192.168.0.116
Pride_Winner
sudo ip r add 192.168.2.0/24 gw 192.168.0.116
Простите пожалуйста совсем тупой вопрос мне нужно создать сетевой интерфейс на eth1 с ип 192.168.2.0?
sudo ip r add 192.168.2.0/24 gw 192.168.0.116
[/quote] если сейчас просто выполнить то
smt@smt-web:~$ sudo ip r add 192.168.2.0/24 gw 192.168.0.116
Error: either "to" is duplicate, or "gw" is a garbage.
[/quote]
fisher74
Pride_Winner
smt@smt-web:~$ ip a ; ip r
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:26:55:80:83:e6 brd ff:ff:ff:ff:ff:ff
inet6 fe80::226:55ff:fe80:83e6/64 scope link
valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:26:55:80:83:e7 brd ff:ff:ff:ff:ff:ff
inet 192.168.0.2/24 brd 192.168.0.255 scope global eth1
inet 192.168.3.100/24 brd 192.168.3.255 scope global eth1:1
inet 192.168.2.2/24 brd 192.168.2.255 scope global eth1:2
inet6 fe80::226:55ff:fe80:83e7/64 scope link
valid_lft forever preferred_lft forever
4: ppp0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1492 qdisc pfifo_fast state UNKNOWN qlen 3
link/ppp
inet 95.79.29.19 peer 91.144.184.70/32 scope global ppp0
default dev ppp0 scope link
default via 192.168.0.116 dev eth1 metric 100
91.144.184.70 dev ppp0 proto kernel scope link src 95.79.29.19
169.254.0.0/16 dev eth1 scope link metric 1000
192.168.0.0/24 dev eth1 proto kernel scope link src 192.168.0.2
192.168.2.0/24 dev eth1 proto kernel scope link src 192.168.2.2
192.168.3.0/24 dev eth1 proto kernel scope link src 192.168.3.100
smt@smt-web:~$
fisher74
inet 192.168.2.2/24 brd 192.168.2.255 scope global eth1:2
Это зачем? Уберите. Тогда и с маршрутом проблемы не будет
Pride_Winner
smt@smt-web:~$ sudo ip r add 192.168.2.0/24 gw 192.168.0.116
Error: either "to" is duplicate, or "gw" is a garbage.
smt@smt-web:~$ ip a ; ip r
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:26:55:80:83:e6 brd ff:ff:ff:ff:ff:ff
inet6 fe80::226:55ff:fe80:83e6/64 scope link
valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
link/ether 00:26:55:80:83:e7 brd ff:ff:ff:ff:ff:ff
inet 192.168.0.2/24 brd 192.168.0.255 scope global eth1
inet 192.168.3.100/24 brd 192.168.3.255 scope global eth1:1
inet6 fe80::226:55ff:fe80:83e7/64 scope link
valid_lft forever preferred_lft forever
4: ppp0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1492 qdisc pfifo_fast state UNKNOWN qlen 3
link/ppp
inet 95.79.29.19 peer 10.86.255.126/32 scope global ppp0
default dev ppp0 scope link
10.86.255.126 dev ppp0 proto kernel scope link src 95.79.29.19
169.254.0.0/16 dev eth1 scope link metric 1000
192.168.0.0/24 dev eth1 proto kernel scope link src 192.168.0.2
192.168.3.0/24 dev eth1 proto kernel scope link src 192.168.3.100
fisher74
а… давайте по старинке
sudo route add -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.0.116
Пользователь решил продолжить мысль 12 Августа 2013, 16:52:57:
потому что надо
sudo ip r add 192.168.2.0/24 via 192.168.0.116
Стыднааа….
Pride_Winner
выполнилось, только эффект смогу завтра узнать, бухгалтерия свалила. заранее спасибо
вот если с вашей поправкой то
smt@smt-web:~$ sudo ip r add 192.168.2.0/24 via 192.168.0.116
RTNETLINK answers: File exists
« Последнее редактирование: 12 Августа 2013, 16:55:27 от Pride_Winner »
AnrDaemon
Pride_Winner, думайте, что пишете. Два раза один и тот же маршрут вы не добавите.
Хотите получить помощь? Потрудитесь представить запрошенную информацию в полном объёме.
Прежде чем [Отправить], нажми [Просмотр] и прочти собственное сообщение. Сам-то понял, что написал?…
- Печать
Страницы: [1] Вверх