Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rpm -U deletes elasticsearch.yml #18158

Closed
Martin-Logan opened this issue May 5, 2016 · 6 comments

Comments

Projects
None yet
3 participants
@Martin-Logan
Copy link

commented May 5, 2016

Elasticsearch version:
5.0 Alpha 2
JVM version:
openjdk version "1.8.0_91"
OS version:
Centos 7
Description of the problem including expected versus actual behavior:
inplace upgrade using 64bit rpm (e.g. rpm -U elasticsearch-5.0.0-alpha2.rpm) overwrites the elasticsearch.yml file . Expect it to create an rpmnew file.
Steps to reproduce:
1.install alpha 1
2.edit elasticsearch.yml
3.upgrade with rpm -U elasticsearch-5.0.0-alpha2.rpm

Provide logs (if relevant):

@jasontedor

This comment has been minimized.

Copy link
Member

commented May 5, 2016

This is the expected behavior in your circumstance. When rpm -U is invoked, there are different scenarios. The scenarios come from there being three possible config files: the original config file distributed with alpha1, your config file with edits, and the config file that is distributed with alpha2. In this situation, you have alpha1 = x, your config = y and it turns out that alpha2 = z (there was a change to the shipped config file between alpha1 and alpha2). In this case, rpm assumes that z must be used with the new package (it can not safely assume that either x or y are safe to use with the new package). That is why it will not produce an rpmnew here.

@jasontedor jasontedor closed this May 5, 2016

@Martin-Logan

This comment has been minimized.

Copy link
Author

commented May 5, 2016

Would it not be better then to produce an rpmold rather than entirely lose the configuration?

@jasontedor

This comment has been minimized.

Copy link
Member

commented May 5, 2016

Would it not be better then to produce an rpmold rather than entirely lose the configuration?

It should have produced an rpmsave. Are you saying that it did not? If not, that is a bug that we should fix.

@Martin-Logan

This comment has been minimized.

Copy link
Author

commented May 5, 2016

It indeed did not

@jasontedor

This comment has been minimized.

Copy link
Member

commented May 5, 2016

It indeed did not

Yes, I just reproduced this as well. Thanks for reporting.

@jasontedor

This comment has been minimized.

Copy link
Member

commented May 6, 2016

@Martin-Logan I've marked you as eligible for the Pioneer Program and opened #18188.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.