A CMMS is a computerised maintenance management system: software for planning, tracking and recording the maintenance of buildings and equipment. Work orders, planned preventative maintenance, spare parts and contractor records all live in it.
A CMMS is narrower than CAFM, which adds space and facilities management on top. If your main problem is broken kit and missed inspections, a CMMS is the tool; if it is how the whole workplace runs, look wider.