In this study, all-cellulose nanocomposite (ACNC) was successfully prepared through a green and sustainable approach by using corn stalk as raw material, water as regeneration solvent, and recyclable two-component ionic liquid/DMSO as the solvent to dissolve cellulose. The morphology and structural properties of ACNC were determined by scanning electron microscopy, transmission electron microscopy, Fourier transform infrared spectroscopy, and X-ray diffraction analysis, indicating homogeneity and good crystallinity. In addition, a comprehensive characterization of ACNC showed that CNF not only improved the thermal stability and mechanical characteristics of ACNC, but also significantly improved the oxygen barrier performance. The ACNC prepared in this work has a good appearance, smooth surface, and good optical transparency, which provides a potential application prospect for converting cellulose wastes such as corn straws into biodegradable packaging materials and electronic device encapsulation materials.