BENTONVILLE, Ark. — Soon, the labyrinthine aisles at Walmart’s distribution centers — stocked high with canned beans, toys and many other products — could also have a low humming sound.

Walmart, the country’s largest retailer, is testing the use of flying drones to handle inventory at its large warehouses, which supply the thousands of Walmart stores throughout the nation. In six to nine months, the company said, the machines may be used in one or more of its distribution centers.

At a demonstration on Thursday at a dry goods distribution center here, a drone moved up and down an aisle packed nearly to the ceiling with boxes, taking 30 images per second. Shekar Natarajan, the vice president of last mile and emerging science, explained that the machines could help catalog in as little as a day what now takes employees about a month.

Walmart applied to the Federal Aviation Administration for permission to begin testing drones last year.