1. A monitoring apparatus comprising: a selection unit configured to select, in a case where a monitoring task for monitoring setting information set for a network device is generated, a setting content to be a monitoring target from setting information that can be set for the network device; a saving unit configured to extract, as monitoring data, in a case where setting information of a specific type is selected as the setting content, setting information corresponding to the setting content along with generation of a monitoring task in which a network device as a target to be monitored, a monitoring setting, and a monitoring schedule are set, and save the monitoring data in such a manner that the monitoring data is associated with the generated monitoring task; a control unit configured to control execution of the generated monitoring task according to the monitoring schedule set in the monitoring task; an acquisition unit configured to acquire, in a case where the monitoring task is executed, setting information corresponding to the monitoring data from the network device set in the monitoring task; and an execution unit configured to execute, according to a result of a comparison process using the setting information acquired by the acquisition unit, processing according to the monitoring setting set in the executed monitoring task, wherein in a case where setting information of a type different from the specific type is selected as the setting content, the saving unit does not save monitoring data along with generation of a monitoring task in which a network device as a target to be monitored, a monitoring setting, and a monitoring schedule are set.