Christine Tran wrote: > On Mon, Jan 25, 2010 at 5:13 PM, James Carlson <carlsonj at workingcode.com> > wrote: > >> Have you filed an RFE for whatever it is you're trying to do? > > Heh, no, not yet. Not sure I remember how. Should this go to the > zones people or the routing people?
I think both would be interested, though perhaps more the Zones folks. The specific issue seems to be how to set up a particular Zones usage. >> This depends on a long-standing oddity in Solaris: once the static >> routes are in the kernel, the system doesn't really care if the >> interface they point to goes away, and it'll correctly associate the >> route with any viable interface when one is later created, but the >> system "helpfully" rejects routes that have a missing output interface >> when initially installed. Thus, lying to the system works. > > I think Solaris should read and honor everything in the static_routes > file, even if it has routes using as yet missing interfaces. This is > being too helpful, and as a UNIX admin, I insist on the right to shoot > myself in the routing table without intervention. I mostly agree. That's just _never_ been the way it actually works. Instead, it invokes the /sbin/route command at a particular point in the boot cycle, and has "whatever" behavior that command happens to exhibit. This is oddness dating back to ancient BSD. In fact, that's the reason for the odd behavior. If I recall correctly, there were tests (SUS, perhaps?) that actually depended on having errors reported in certain cases. It's obviously inconsistent, though. You can establish those "hanging" routes if the interface exists -- even just momentarily -- but not otherwise. And it turns out that interfaces aren't always under your direct control (because the system itself can tear them down in various different cases, including DHCP and DR), so there's no completely foolproof guaranteed-to-succeed way of adding a static route to the system. The interface it depends on might slide out from underneath you as you type the command. An "I don't care if the destination exists when I'm adding this" flag for RTM_ADD would be nifty. It likely can't be the default, but it could be used by the static_route service. -- James Carlson 42.703N 71.076W <carlsonj at workingcode.com>