[Ns-developers] Summer of Code nsc/ns-3 integration status, week 09
Florian Westphal
fw at strlen.de
Mon Jun 23 16:07:35 PDT 2008
Hello ns3-dev,
during last week i looked into adding some kind of iterator API to nsc
that would enable ns-3 to query the stack for its supported sysctl
values and the argument type (int, int*, const char *).
After some experimentation, looking into a recent Linux 2.6.26-rc
candidate and talking to Sam we decided that the most maintainable
solution is to add the functionality of the sysctl-userspace utility
to nsc, e.g.
sysctl(const char *sysctl_name, const char *value)
and add the actual mapping to NSC.
While this isn't elegant and 'uninteresting' to implement, it will
not require much maintenenance -- the only work is the initial
implementation for all the stacks and adding new sysctls when they
appear. On the ns-3 side, it allows the use of StringValue for all
sysctl attributes.
After such a mapping has been added to nsc, it will be little
effort to add a function that returns the whole list (or an iterator).
Another approach would be to reuse the linux proc format functions that
map writes to the /proc hierarchy to the kernel representation of the
data. Aside from being linux specific, this is also problematic because
it may change with each kernel release (also, i removed procfs support
for now in the initial 2.6.26 porting effort).
So, to summarize i'll be working on three things this week:
1.) porting linux 2.6.26 to nsc (low priority). Right now there are
about 100 unresolved symbols, but I hope that most of those
can be solved by adding a stub function.
2.) adding a sysctl mapping and an iterator to NSC.
I plan to do this tomorrow, I'll focus on Linux and only add a few
sysctls so I can start adding code to ns-3 that uses that interface
to build a sysctl attribute hierarchy.
Regards,
Florian
More information about the Ns-developers
mailing list