Q18. What are the main Nagios configuration files?
The top-level file is nagios.cfg, the main config Nagios reads on startup. It sets global behavior and, more importantly, points at the object config files (via cfg_file and cfg_dir) where your hosts, services, commands, and contacts actually live. Then there's resource.cfg, which holds macros like $USER1$ (the plugin directory) and is kept readable only by Nagios because it can store secrets.
Your object definitions are usually split across many files under a conf.d or objects directory, grouped by type or by environment. Keeping them modular is what makes a growing config navigable instead of one giant unreadable file.
# in nagios.cfg
cfg_file=/usr/local/nagios/etc/objects/commands.cfg
cfg_dir=/usr/local/nagios/etc/conf.d
resource_file=/usr/local/nagios/etc/resource.cfgKey point: Knowing nagios.cfg points at object files and that resource.cfg holds $USER1$ and secrets shows you've navigated a real config tree, not just one example host.