A blaze at Panda Environmental Services, a waste treatment plant near Ayr, prompted a brief evacuation of nearby businesses on Thursday morning.
Ayr and New Dundee fire departments were dispatched to the scene and the fire was extinguished quickly.
Three people were inside the building at the time, but they all escaped without injury.
The fire reportedly started in a pit inside a building where materials are prepared for processing.
The company uses chemicals and sawdust as part of the process to treat the oil and sludge products, and the sawdust is what reportedly sparked the fired.
North Dumfries Fire Chief Robert Shantz says "It was in the mixing process that the fire occurred."
Fortunately, because the process happens in a pit underneath the structure, it was easier to extinguish.
The fire, which was in an industrial area on Earl Thompson Road, off of Cedar Creek Road in North Dumfries, prompted reports of thick yellow smoke.
Officers evacuated nearby businesses and schools downwind were told to keep children inside.
Police say one of the big issues with the fire was that they didn't know what chemicals were in the building, because they had none on file.
In the current system, files are spread among different fire services and police, and in this case they weren't up to date.
Waterloo Regional Police Insp. Dave Bishop says "In terms of what those chemicals are, the fire department is looking into that, to determine the appropriate response."
The company says there are no unusual hazards in the building.
Reports are expected to be filed with the North Dumfries Fire Department and the Ministry of the Environment.