Bug #6405
closedServer roles overwritten regularly for unknown reason
Description
Hi,
In a multiserver setup, the server roles are overwritten with data loss at some regular (?) interval.
Here's an excerpt of the script I use to init the rudderweb instance, based on the one from rudder-tools git repo:
## Inform Rudder about the various roles so installation can proceed successfully mkdir -p /var/rudder/cfengine-community/inputs cat >/var/rudder/cfengine-community/inputs/rudder-server-roles.conf <<EOF rudder-ldap:rudderldap01 rudder-inventory-endpoint:rudderldap01 rudder-db:rudderdb rudder-front:rudderrelaytop01 rudder-relay-top:rudderrelaytop01 rudder-webapp:rudderweb rudder-web:rudderweb EOF ## Install components yum install -y rudder-agent rudder-webapp rudder-techniques rsyslog rsyslog-pgsql httpd httpd-tools ## Give more RAM to jetty #<snip> ## Init DB (/opt/rudder/etc/postgresql/reportsSchema.sql from rudder-reports-3.0.2.release-1.EL.6.noarch) #<snip, this performs the init our rds instance, set the proper psql password in the conf, etc> ## Initialize the server: hostname, demodata?, ldapreset?, initialpromisesreset?, allowednet sed -i '/^Pause$/d' /opt/rudder/bin/rudder-init # ensure that it won't hang waiting for user input /opt/rudder/bin/rudder-init yes <our networks>
After that, rudder seems to work fine for some time, at least the UI. But at some point we can't get any report.
Indeed, because /etc/rsyslog.d/rudder.conf contains:
:ompgsql:localhost,rudder,rudder,password;RudderReportsFormat
localhost instead of rudderdb!
rudder.jdbc.* keys in /opt/rudder/etc/rudder-web-properties have the proper values.
Now, if I look at /var/rudder/cfengine-community/inputs/rudder-server-roles.conf, it has been overwritten by something:
# This file contains, for each role, the list of nodes that have this role # These roles are auto-detected by default, based on inventories of nodes that have role files in /opt/rudder/etc/server-roles.d/ # Format is the following # role:hostname1,hostname2,hostname3 rudder-ldap:rudderldap01 rudder-inventory-endpoint:rudderldap01 rudder-relay-top:rudderrelaytop01
rudderdb is gone!
If I put it back and run cf-agent, then the rsyslog config is ok.
However, it's somehow overwritten again at some point, because I restored the proper value yesterday evening, and this morning it's broken again.
Thanks.
Updated by Nicolas CHARLES almost 10 years ago
- Category set to Server components
- Status changed from New to Discussion
- Assignee set to Lionel Le Folgoc
Hello Lionel,
I have several questions for you:
- which version of Rudder do you use ?
- in the file /opt/rudder/etc/rudder-web-properties, you can define roles there. Which role did you define ?
- do you have the package rudder-db installed on the serveur with the web interface ? if so, that may be the cause of your issue, as a new inventory is generated and reconfigure the roles
Updated by Lionel Le Folgoc almost 10 years ago
- Category deleted (
Server components) - Status changed from Discussion to New
- Assignee deleted (
Lionel Le Folgoc)
Hi,
- Rudder 3.0.2
- See https://github.com/Normation/rudder-tools/blob/master/scripts/rudder-multiserver-setup/rudder-web.sh#L10 and http://www.rudder-project.org/rudder-doc-3.0/rudder-doc.html#multiserver-rudder, there's no mention of this file to set the roles...
- Nope: rudder-agent rudder-webapp rudder-techniques rsyslog rsyslog-pgsql httpd httpd-tools
But I guess the scripts and the documentation are incorrect and it'll work fine once I edit /opt/rudder/etc/rudder-web.properties. =)
Updated by Lionel Le Folgoc almost 10 years ago
# ll /opt/rudder/etc/server-roles.d/ total 0 -rw-r--r-- 1 root root 0 Mar 9 16:06 rudder-jetty -rw-r--r-- 1 root root 0 Mar 9 16:24 rudder-webapp
so if there's "rudder.server-roles.db=autodetect" in /opt/rudder/etc/rudder-web.properties it will put localhost as db server even when the localhost has not the db role...
Updated by Nicolas CHARLES almost 10 years ago
- Category set to Server components
- Status changed from New to Discussion
- Assignee set to Lionel Le Folgoc
"rudder.server-roles.db=autodetect" should be the right value
could you check, on the node with the rudder-db role, that you indeed have the file rudder-db in /opt/rudder/etc/server-roles.d ?
Just to be sure, it used to work correctly, and you have problems since the upgrade ?
Updated by Lionel Le Folgoc almost 10 years ago
The db is on amazon rds, so I can't really set the role, so rudder does not "know" rudderdb. I guess this is why autodetection fails. So I think in this case forcing "rudder.server-roles.db=rudderdb" will make it work.
Updated by Nicolas CHARLES almost 10 years ago
Indeed, if you don't have a node with the rudder-db role, you'll have to specifically define that the rudder-db is on a specific node in the rudder.server-roles.db value
Updated by François ARMAND almost 10 years ago
- Priority changed from N/A to 1 (highest)
- Target version set to 2.11.9
Lionel,
Did changing the property in /opt/rudder/etc/rudder-web.properties make the role OK ?
If so, can I rename that ticket to: "Mis-documentation on server role configuration make them be regularly overwritten" so that we correct the documentation to handle your use case ?
Updated by Vincent MEMBRÉ almost 10 years ago
- Target version changed from 2.11.9 to 2.11.10
Updated by Vincent MEMBRÉ over 9 years ago
- Target version changed from 2.11.10 to 2.11.11
Updated by Vincent MEMBRÉ over 9 years ago
- Target version changed from 2.11.11 to 2.11.12
Updated by Vincent MEMBRÉ over 9 years ago
- Target version changed from 2.11.12 to 2.11.13
Updated by Vincent MEMBRÉ over 9 years ago
- Target version changed from 2.11.13 to 2.11.14
Updated by Vincent MEMBRÉ about 9 years ago
- Target version changed from 2.11.14 to 2.11.15
Updated by Vincent MEMBRÉ about 9 years ago
- Target version changed from 2.11.15 to 2.11.16
Updated by Vincent MEMBRÉ about 9 years ago
- Target version changed from 2.11.16 to 2.11.17
Updated by Vincent MEMBRÉ about 9 years ago
- Target version changed from 2.11.17 to 2.11.18
Updated by Vincent MEMBRÉ almost 9 years ago
- Target version changed from 2.11.18 to 2.11.19
Updated by Vincent MEMBRÉ almost 9 years ago
- Target version changed from 2.11.19 to 2.11.20
Updated by Vincent MEMBRÉ over 8 years ago
- Target version changed from 2.11.20 to 2.11.21
Updated by Vincent MEMBRÉ over 8 years ago
- Target version changed from 2.11.21 to 2.11.22
Updated by Vincent MEMBRÉ over 8 years ago
- Target version changed from 2.11.22 to 2.11.23
Updated by Vincent MEMBRÉ over 8 years ago
- Target version changed from 2.11.23 to 2.11.24
Updated by Vincent MEMBRÉ over 8 years ago
- Target version changed from 2.11.24 to 308
Updated by Vincent MEMBRÉ over 8 years ago
- Target version changed from 308 to 3.1.14
Updated by Vincent MEMBRÉ about 8 years ago
- Target version changed from 3.1.14 to 3.1.15
Updated by Vincent MEMBRÉ about 8 years ago
- Target version changed from 3.1.15 to 3.1.16
Updated by Vincent MEMBRÉ about 8 years ago
- Target version changed from 3.1.16 to 3.1.17
Updated by François ARMAND about 8 years ago
- Related to Architecture #8463: Server roles is a BIG mess causing inconsistencies and bugs added
Updated by Vincent MEMBRÉ about 8 years ago
- Target version changed from 3.1.17 to 3.1.18
Updated by Vincent MEMBRÉ almost 8 years ago
- Target version changed from 3.1.18 to 3.1.19
Updated by Benoît PECCATTE almost 8 years ago
- Subject changed from Server roles overwritten regurlarly for unknown reason to Server roles overwritten regularly for unknown reason
Updated by Jonathan CLARKE over 7 years ago
- Severity set to Minor - inconvenience | misleading | easy workaround
- User visibility set to Operational - other Techniques | Technique editor | Rudder settings
Updated by Vincent MEMBRÉ over 7 years ago
- Target version changed from 3.1.19 to 3.1.20
Updated by Jonathan CLARKE over 7 years ago
- Status changed from Discussion to New
Updated by Jonathan CLARKE over 7 years ago
- Assignee deleted (
Lionel Le Folgoc)
Updated by Vincent MEMBRÉ over 7 years ago
- Target version changed from 3.1.20 to 3.1.21
Updated by Vincent MEMBRÉ over 7 years ago
- Target version changed from 3.1.21 to 3.1.22
Updated by Vincent MEMBRÉ over 7 years ago
- Target version changed from 3.1.22 to 3.1.23
Updated by Vincent MEMBRÉ over 7 years ago
- Target version changed from 3.1.23 to 3.1.24
Updated by Vincent MEMBRÉ about 7 years ago
- Target version changed from 3.1.24 to 3.1.25
Updated by Vincent MEMBRÉ about 7 years ago
- Target version changed from 3.1.25 to 387
Updated by Vincent MEMBRÉ about 7 years ago
- Target version changed from 387 to 4.1.10
Updated by Vincent MEMBRÉ almost 7 years ago
- Target version changed from 4.1.10 to 4.1.11
Updated by Vincent MEMBRÉ over 6 years ago
- Target version changed from 4.1.11 to 4.1.12
Updated by Vincent MEMBRÉ over 6 years ago
- Target version changed from 4.1.12 to 4.1.13
- Priority changed from 27 to 28
Updated by Vincent MEMBRÉ over 6 years ago
- Target version changed from 4.1.13 to 4.1.14
Updated by Benoît PECCATTE over 6 years ago
- Target version changed from 4.1.14 to 4.1.15
Updated by Vincent MEMBRÉ about 6 years ago
- Target version changed from 4.1.15 to 4.1.16
- Priority changed from 28 to 29
Updated by Vincent MEMBRÉ about 6 years ago
- Target version changed from 4.1.16 to 4.1.17
Updated by Vincent MEMBRÉ about 6 years ago
- Target version changed from 4.1.17 to 4.1.18
- Priority changed from 29 to 0
Updated by Vincent MEMBRÉ almost 6 years ago
- Target version changed from 4.1.18 to 4.1.19
Updated by Alexis Mousset almost 6 years ago
- Target version changed from 4.1.19 to 4.1.20
Updated by François ARMAND almost 6 years ago
- Target version changed from 4.1.20 to 4.1.21
Updated by Vincent MEMBRÉ over 5 years ago
- Target version changed from 4.1.21 to 4.1.22
Updated by Vincent MEMBRÉ over 5 years ago
- Target version changed from 4.1.22 to 4.1.23
Updated by Vincent MEMBRÉ over 5 years ago
- Target version changed from 4.1.23 to 4.1.24
Updated by Vincent MEMBRÉ over 5 years ago
- Target version changed from 4.1.24 to 588
Updated by Vincent MEMBRÉ over 5 years ago
- Target version changed from 588 to 5.0.13
Updated by Vincent MEMBRÉ over 5 years ago
- Target version changed from 5.0.13 to 5.0.14
Updated by Vincent MEMBRÉ about 5 years ago
- Target version changed from 5.0.14 to 5.0.15
Updated by François ARMAND about 5 years ago
- Status changed from New to Rejected
We are not allowing split installation in Rudder 6.0 as described here, I'm closing that ticket.
Updated by Benoît PECCATTE about 5 years ago
We still allow separate DB installs.
But we removed rudder-init support.