In order to build this code, you MUST put it in the correct location. GOLANG requires that
code be placed in one of two specific locations in order to leverage the sub packages features,
which I have used heavily. On Uranus at least, for me, GOPATH was not set at all. I had to edit my .bash_profile
to export it before I could run my code.
- YOU MUST put folder oop at where the environment var GOPATH is pointing to
- set | grep GOPATH
- [n00599835@cisatlas oop]$ set | grep GOPATH
- GOPATH=/home/n00599835/go/src
- [n00599835@cisatlas oop]$ set | grep GOPATH
- This can be tricky, for example i have to put oop in /home/n00599835/go/src/src/oop for go to find my packages...
- If you build, and it fails, move the files to where GOPATH is reporting from the build, not the set command...
- main.go:5:2: cannot find package "oop/core" in any of: 2. /opt/go/src/pkg/oop/core (from $GOROOT) 3. /home/n00599835/go/src/src/oop/core (from $GOPATH)
- Based on the compiler output, we can see go wants the program in /home/n00599835/go/src/src/, not /home/n00599835/go/src/ as indicated by set | grep GOPATH
- This is different between Uranus, and Atlas. so you will have to play around with the directory structure to get it to work.
- set | grep GOPATH
- unshar turnin compression somewhere
- If go is installed on your system, you "should" already have a directory at ~/go/src/
- This might be the root for all go programs for your profile, see step 0 for help.
- cp the oop directory in the shar to the following path
- ~/go/src/oop
- Such that the main.go is at ~/go/src/oop/main.go
- cd ~/go/src/oop
- go build main.go
--size
--all
--nlogn
--nsquared
--rocks => if set, will attempt to distribute to the rocks cluster
$ chmod 777 test.sh
$ ./test.sh
2018/11/10 13:47:21 Sequential Merge Sort took 997.3µs
2018/11/10 13:47:21 Parallel Merge Sort took 3.0005ms
- ssh cisatlas.ccec.unf.edu
- go run main.go --size=10000 --all
- go run main.go --size=10000 --nsquared
- go run main.go --size=10000 --nlogn
#NOTE: Server must be started seperatly to run these commands see Below Section on Running Distributed Memory Server#
-
ssh uranus.ccec.unf.edu
- go run main.go --size=10000 --all --rocks
- go run main.go --size=10000 --nsquared --rocks
- go run main.go --size=10000 --nlogn --rocks
- go run main.go --size=10000 --all --rocks --hostsfile
- go run main.go --size=10000 --nsquared --rocks --hostsfile
- go run main.go --size=10000 --nlogn --rocks --hostsfile
-
go run server.go
-
go run main.go --size=10000 --nlogn --rocks1
#Note: staring the server on any one compute node "should" start it on all iof the others... Should...#
- go run build to create the server executable.
- rocks run host compute-0-0 "~/go/src/oop/server" &
- It should be runnin on all clusters now, but if you get errors.
- run the command to start the server on the compute node having issues.
- rocks run host compute-0-[0-12] "~/go/src/oop/server" &
- It should be runnin on all clusters now, but if you get errors.
- at Root:
- lsof -i -P -n | grep LISTEN
- rocks iterate host "lsof -i -P -n | grep LISTEN" 2. rocks run host compute-0-0 "kill PID_FROM_ABOVE_COMMAND" 3. The PIDS will be repeating, and killing it on 0-0 should kill it everywhere.
curl http://localhost:8080/api/v1/running curl http://compute-0-0:8080/api/v1/running curl http://compute-0-[0-12]:8080/api/v1/running
Project 3 Parallel Computing --- Due 11/20/18
For this project you are to implement comparison of performance of
parallel applications.
Using your chosen language, implement O(nlgn), O(n^2)
algorithms. On atlas projects should use threading and
uranus utilizing socket communication or a communication provided
by the language.
GO - Sean Willison -------------- 11/20/18
Documentation and source code should be submitted
by the end of class on 12/1.
turnin to reepar3