[Ns-bugs] [Bug 348] New: regression tests do not work in private or disconnected networks

bugzilla-daemon@nsnam-www.ece.gatech.edu bugzilla-daemon at nsnam-www.ece.gatech.edu
Sun Sep 14 11:18:45 PDT 2008


http://www.nsnam.org/bugzilla/show_bug.cgi?id=348

           Summary: regression tests do not work in private or disconnected
                    networks
           Product: ns-3
           Version: ns-3.2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P3
         Component: regression
        AssignedTo: ns-bugs at isi.edu
        ReportedBy: tomh at tomh.org


A typical use case is that someone will download the release and use it on a
machine where it is not well connected to the Internet, or where the user's
http_proxy variable is not set.

A user may first download the release tarball only.  Suppose this tarball is
downloaded onto a machine where either it is behind a NAT and http_proxy is not
set, or the machine may not even have reachability to the public network.  For
instance, a user who wants to try out ns-3 during a train ride.

I think the behavior in this case, regardless of whether hg is installed or
not, is reasonable with the current release candidate; a user who types in
"./waf --regression" on this released version will get a connect error in a
reasonably short time:  "Abort: name or service name not known".  How to remedy
this can be documented; waf could even output some suggestions if this socket
error occurs.

However, what if this user then tries to separately download the matching
regression trace tarball and unpack it on the machine?  He or she will put
these regression traces in the ns-3.2/regression trace directory, and try again
"./waf --regression" and will get this type of error:

========== Running Regression Tests ==========
Retrieving ns-3.2-RC2-bis-ref-traces.tar.bz2 from web.
Traceback (most recent call last):
  File "./waf", line 141, in <module>
    Scripting.prepare()
  File
"/home/tomh/ns-3.2-RC2-bis/.waf-1.4.2-81764acf62a7c7247901b9a99367b3a2/wafadmin/Scripting.py",
line 207, in prepare
    main()
  File
"/home/tomh/ns-3.2-RC2-bis/.waf-1.4.2-81764acf62a7c7247901b9a99367b3a2/wafadmin/Scripting.py",
line 299, in main
    if fun:fun()
  File "/home/tomh/ns-3.2-RC2-bis/wscript", line 451, in shutdown
    run_regression()
  File "/home/tomh/ns-3.2-RC2-bis/wscript", line 934, in run_regression
    urllib.urlretrieve(REGRESSION_TRACES_URL + traceball, traceball)
  File "/usr/lib/python2.5/urllib.py", line 89, in urlretrieve
    return _urlopener.retrieve(url, filename, reporthook, data)
  File "/usr/lib/python2.5/urllib.py", line 222, in retrieve
    fp = self.open(url, data)
  File "/usr/lib/python2.5/urllib.py", line 190, in open
    return getattr(self, name)(url)
  File "/usr/lib/python2.5/urllib.py", line 325, in open_http
    h.endheaders()
  File "/usr/lib/python2.5/httplib.py", line 860, in endheaders
    self._send_output()
  File "/usr/lib/python2.5/httplib.py", line 732, in _send_output
    self.send(msg)
  File "/usr/lib/python2.5/httplib.py", line 699, in send
    self.connect()
  File "/usr/lib/python2.5/httplib.py", line 667, in connect
    socket.SOCK_STREAM):
IOError: [Errno socket error] (-2, 'Name or service not known')

I verified this on a machine behind a NAT, both with and without hg in the
path, and got similar behavior.  I wasn't able to drop in the release trace
tarball and have it work seamlessly, nor do I know how to make it work.  

I think that the current behavior is that if these traces are placed into the
regression/ directory, waf assumes that it must go out and synchronize these
traces, and will fail with the above type of error.

So, I think that for user-friendliness, one of these steps needs to be taken:

1) include regression traces in the main tarball, and have the system work
self-contained even in the absence of network connectivity
2) document how one can separately download both the release and regression
traces, put them together, and make it work in a non-connected environment

This also is problematic on the development tree.  Similarly, I just tried the
following on ns-3-dev:

hg pull
hg update
./waf --regression
(disable network access)
./waf --regression
========== Running Regression Tests ==========
Synchronizing reference traces using Mercurial.
Pulling http://code.nsnam.org/ns-3-dev-ref-traces from repo.
abort: error: No address associated with nodename
Synchronizing reference traces using Mercurial failed. 


I really ought to be able to tell the system "Just use whatever regression
traces you have downloaded in the past-- do not try to synchronize them"  Can I
do that somehow?  ./waf configure --offline  or ./waf configure
--disable-updates?


-- 
Configure bugmail: http://www.nsnam.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


More information about the Ns-bugs mailing list