Several Fixes for OS X

Fixing the following OS X problems:
1. CPU usages get 100 %.
2. MAC addresses of VLAN is not set correctly.