Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mac_BSD_resources.py is not invoked for benchmarking Seattle installation in BSD,instead Linux_resources.py is invoked #10

Open
Ashmita89 opened this issue Nov 24, 2015 · 4 comments

Comments

@Ashmita89
Copy link

No description provided.

@Ashmita89
Copy link
Author

Root Cause Analysis of the issue:
benchmark_resources.py is used to import bench-marking files respective OS.
Further,nonportable.py is used to figure out the OS type.
This in turn calls harshexit.py-init_ostype()
Here ,issue initiates.
However,
This in turn calls harshexit.py-init_ostype()-L151 reads that # workaround for a Vista bug,which is not clear as to whether it extends for harshexit.py-L151-L154 or harshexit.py-L151-L158.

Note:
a.The testing environment has Host OS-Windows Vista and Virtual Box Host as FreeBSD 10.2 .
b.nonportable.osrealtype value is returned as FreeBSD.Attaching screenshot with Debug Statements
os_realtype_detected_correctly

@aaaaalbert
Copy link
Contributor

Thanks for looking into the details!

The Vista comment most likely relates to the 'Microsoft' / 'Windows' block only. (Cross-reference: The various Windows and Python versions don't always play well with one another, see SeattleTestbed/dist#146 .)

However, classifying FreeBSD as Linux in L157 is what gets us into trouble later with trying to use procfs. Please try to fix this misclassification so that we invoke the correct benchmark script, then see what happens.

@Ashmita89
Copy link
Author

Thank you for the clarification on the comment.
I checked with two different approaches :
1.Removing the Cross Reference to Linux and assigning the ostype="FreeBSD" in harshexit.py-init_ostype().
However ,this solution does not work as in 'nonportable.py-getruntime()' expects a Linux or Darwin OS Type hence ,Cross Ref is required.

2.Only tracking the real OS type,in this case "FreeBSD" in benchmark_resources.py and allowing it to use 'Mac_BSD_resources.py-original' or 'Mac_BSD_resources.py-pull request version'
raises bench-marking failure .
This is traced back to exception raised while calling sysctl hw.memsize in Mac_BSD_resources.py.
Note :Ideally in FreeBSD ,sysctl hw.physmem should return the physical memory .

Attaching the related screenshots :
Case 1-
bsd-changing cross ref harsh exit
Case 2-
bsd-1-sysctl

@aaaaalbert
Copy link
Contributor

OK, for case 1 it seems we need "FreeBSD" in the list of OS names that nonportable.getruntime checks against: https://github.com/SeattleTestbed/repy_v2/blob/master/nonportable.py#L188

For case 2, we just moved away from hw.physmem to hw.memsize because the latter is what Mac OS X does these days: f2d79fd and #4

Adding an appropriate distinction of cases won't be difficult though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants