How to configure dnf not to sync meta data automatically ?
Fedora 29, Although I have configured the repos as metadata-expires to 7d, dnf downloads them randomly throughout the day! (obviously only when I run some dnf install command). It is almost more than 60MB of data it downloads. So, how to make it so that it will not download the meta data unless I explicitly do that ?
You have changed the option to 7d for all repos that are enabled on your system? And you are not using the --refresh option?!
Metadata downloads should be smaller with Fedora 30 https://fedoraproject.org/wiki/Change... so in a couple of months things should improve. In the meantime @florian's answer should help.