Software Defined Networking (SDN) and Network Functions Virtualization (NFV) are the two fundamental paradigms that introduce concealed flexibility in communication systems. 5G has adopted SDN/NFV to make Network Functions (NFs) as virtualized software modules which run on top of commodity hardware. 5G aims to expand its reach to various business verticals and serve diverse users using network slicing which creates multiple logical networks on top of a shared infrastructure. This paper proposes a novel OpenNetVM based 5G framework (ONVM-5G) which uses Data Plane Development Kit for the communication between the core NFs and thus, is a candidate solution for implementing 5G core (5GC) in a box. The proposed framework based deployment of network slices enhances the user experience by reducing the latency involved in performing various User Equipment activities and increasing data plane throughput. Moreover, ONVM-5G also helps in achieving the 5G goals by allowing the network operators to efficiently serve the users in small dense cells and make service level isolation among the diverse users through network slicing by providing a network in a box like deployment of 5GC.