Added optimize command.