Did you type a literal \r\n\r\n? You need a carriage return followed by a newline and then another carriage return and linefeed. A carriage return is not a character you can enter using your keyboard, so I don't think you can run rust-analyzer directly in a terminal. You need to write a program that interacts with it.
In theory, you can, actually: '\r' = character code 13 = control-M.
ASCII and Unicode characters 1 through 13 correspond to control-A through control-Z. Not only that, as a legacy from the actual-terminal-keyboard days, the keyboard “enter” key (or “return” on Apple hardware) corresponds to control-M.
However, this isn't quite sufficient, because unless the tty (kernel object that sits between the terminal emulator and the program accepting input) is in “raw” mode, some of them are given special meaning before they get to the program, like control-C produces a signal, and control-M ends up being converted into '\n', code 10, control-J.
(This is true of Unix-style systems; the details on Windows are different and I can't tell you what the story of typing them is.)