Is rpm and/or dnf able to replace defined-as-irreplacable configurative files (restore `/etc/ssh/ssh_config` file)?

Identically to what describes, I have erroneously deleted /etc/ssh/ssh_config.

during today, but all of the solutions that are have been provided are for apt and dpkg. Does dnf and rpm possess any equivalent ability?

Alternatively, un-installation and subsequent installation does not provide the file. Automatic Re-installation does not provide the file, so if the I wonder whether OpenSSH initially provided it.

What package did you re-install? The file is provided by openssh-clients:

rpm -qf /etc/ssh/ssh_config

rpm (and so anything that uses rpm, including dnf/packagekit) will not replace configuration files—these must be marked as configuration files in the spec, though. If the configuration file differs from what is currently on disk, rpm will create a <file>.rpmnew file there, and then it is up to the admin to decide if the new file should be used or bits of it should be and so on. One can do this using the rpmconf tool.

So, I think you should try reinstalling the openssh-clients package and see how that goes?

PS: even if you’ve run into an issue that’s posted elsewhere, please post your problem here in its entirety so that users do not need to click on links etc. to see what the issue is. Also of course, if this third party website disappears in the future, readers won’t know what the issue here was.


I did reinstall openssh-clients, and all of its dependencies, and although the problem had not been remediated when I posted this, the file has reappeared. I am thankful for the assistance, and have modified my question to provide some redeundancy against hyperlink-rot.

1 Like