From Request Tracker Wiki
Jump to navigation Jump to search

The following one-liner uses the RT API and the internal RT::SystemUser to grant the root user the superuser safely. You'll need to run this as a local user that can access the RT config file.

perl -I/opt/rt3/lib -MRT -e'RT::LoadConfig; RT::Init;

  my $u=RT::User->new($RT::SystemUser);
  ($val,$msg) = $u->PrincipalObj->GrantRight(Object=> $RT::System, Right => "SuperUser");
  print "$msg\n"'