Astronomy is posing imminent big challenges to database management systems. Projects such as Pan-STARRS will build a 300 TB database system by year 2011. In order to achieve such as an ambitious goal, we must divide to conquer. We present the GrayWulf framework where computational and data resources are integrated through powerful workflow, and query tools. The system is built on top of a cluster of commodity servers. Its scalable architecture makes it a great host for data intensive applications such as large scale cross-matching.