Dan Stromberg wrote:
Dan Stromberg wrote:
We have a good-sized shell script that automates our openSUSE and SLES OS configurations, chained into from autoyast.
We'd like it to set up a multicast route.
If I put the route in /etc/sysconfig/network/ifroute-eth0, the line seems to be ignored - I get no route.
If I put the same line in /etc/sysconfig/network/routes, the line seems to take effect. However, the line eventually gets moved to routes.YaST2save and of course then stops working.
I suspect I've been putting the right thing in ifroute-eth0 and the program utilizing ifroute-eth0 is doing something wrong, because otherwise it seems like the same line wouldn't work in /etc/sysconfig/network/routes.
What do I need to do in order to automatically add a route and get it to stick?
It seems I could add an rc script to re-add my line to /etc/sysconfig/network/routes on every boot, but... that's a little bit icky.
The line I've been trying to use is:
228.0.0.0/8 0.0.0.0 255.0.0.0 eth0 multicast
Thanks!
BTW, we had a similar problem with changing the default runlevel in /etc/inittab. If we edited the runlevel in /etc/inittab from our shell script, the runlevel would be set back to the wrong value again on the next boot. We eventually found that we could make the runlevel stay put by changing the autoyast.xml instead, and letting yast (?) stuff the right value in the file in an automatic way.
So I checked our autoyast.xml files for this issue, but didn't see anything that looked much like a way of adding a route. I searched on "net" and "route" in an example file.
It looks like although our autoyast.xml's had no routing information, they can contain routing information. After googling and looking at some ycp files, I came up with this guess, which seems to be working: <routing> <ip_forward config:type="boolean">false</ip_forward> <!-- destination, gateway, netmask, [device, [extrapara]] --> <!-- 228.0.0.0/8 0.0.0.0 255.0.0.0 eth0 multicast --> <routes config:type="list"> <route> <destination>228.0.0.0/8</destination> <gateway>0.0.0.0</gateway> <netmask>255.0.0.0</netmask> <device>eth0</device> <extrapara>multicast</extrapara> </route> </routes> </routing> ...but using this rather complicated method is going to be a headache if we need to change a route in the field. It'd be much nicer if we could just edit the "routes" file with vi or a shell script. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org