RocketChat/Rocket.Chat · warning · Meteor.Error
crowd_disabled
crowd_disabled
Error message
crowd_disabled
What it means
crowd_test_connection reads the CROWD_Enable setting and throws 'crowd_disabled' when it is not exactly true. The connection test is refused until the Crowd integration is switched on, so credentials cannot be tested against a disabled integration.
Source
Thrown at apps/meteor/server/meteor-methods/auth/crowd.ts:34
}
Meteor.methods<ServerMethods>({
async crowd_test_connection() {
const user = await Meteor.userAsync();
if (!user) {
throw new Meteor.Error('error-invalid-user', 'Invalid user', {
method: 'crowd_test_connection',
});
}
if (!(await hasPermissionAsync(user, 'test-admin-options'))) {
throw new Meteor.Error('error-not-authorized', 'Not authorized', {
method: 'crowd_test_connection',
});
}
if (settings.get('CROWD_Enable') !== true) {
throw new Meteor.Error('crowd_disabled');
}
try {
const crowd = new CROWD();
await crowd.checkConnection();
return {
message: 'Crowd_Connection_successful' as const,
params: [],
};
} catch (err) {
logger.error({
msg: 'Invalid crowd connection details, check the url and application username/password and make sure this server is allowed to speak to crowd',
err,
});
throw new Meteor.Error('Invalid connection details', '', { method: 'crowd_test_connection' });
}
},View on GitHub (pinned to b2c16d5842)
Solutions
- Enable CROWD_Enable in the admin LDAP/CROWD settings and save before testing
- Save the settings form first, then run Test Connection
- In multi-instance setups, confirm every instance reads the same settings source
Example fix
// before — integration disabled
await Meteor.callAsync('crowd_test_connection'); // throws crowd_disabled
// after — enable first, then test (Admin -> LDAP -> CROWD toggle, or server-side:)
await settings.updateById('CROWD_Enable', true);
await Meteor.callAsync('crowd_test_connection'); Defensive patterns
Strategy: validation
Validate before calling
// server-side: confirm the integration is on before testing
if (settings.get('CROWD_Enable') !== true) {
throw new Error('Enable CROWD before testing the connection');
}
await Meteor.callAsync('crowd_test_connection'); Type guard
const isMeteorErrorCode = (e: unknown, code: string): e is Meteor.Error => e instanceof Meteor.Error && e.error === code;
Try / catch
try {
await Meteor.callAsync('crowd_test_connection');
} catch (err) {
if (isMeteorErrorCode(err, 'crowd_disabled')) {
// prompt the user to enable and save CROWD settings first, then retry
}
} Prevention
- Save and enable the integration before exposing a Test Connection action
- In multi-instance deployments, verify the setting is consistent across nodes
When it happens
Trigger: Clicking Test Connection on the Crowd settings screen while the CROWD_Enable toggle is off; calling the method programmatically before enabling the integration; a multi-instance deployment where the setting differs between nodes.
Common situations: Testing credentials before flipping the enable toggle; settings reset after a backup restore; instances reading different settings databases.
Related errors
AI-assisted analysis of RocketChat/Rocket.Chat@b2c16d5842 (2026-08-18).
Data as JSON: /api/errors/d29da3468f37db9f.
Report an issue: GitHub.