- Turn to the directory src/main
- Run the following command
# Build wc.go
go build -buildmode=plugin ../mrapps/wc.go
# Run the coordinator
go run mrcoordinator.go pg*.txt
# Run in race mode
go run -race mrcoordinator.go pg*.txt
# Run the workers
go run mrworker.go wc.so
# Check the result
cat mr-out-* | sort | more- Clear the intermediate files
- Run the command above
# Clear the intermediate files
rm -rf mr-* wc.sosort -V -k1,1 -k2,2 mr-out* | grep . > mr-wc-all