Weird CLI behavior

I usually use the CLI over SSH to work with my Mikrotiks, because we are primarily a Macintosh shop, so we use Winbox and the like only when absolutely necessary.

Yesterday I was in a situation where I could only talk to a router in Winbox’s MAC connection mode. I brought up a terminal window inside Winbox to paste in (^V) a command line copied from an online file. Whenever I did this, my terminal session entered a mode where it anticipated the command it thought I was typing, automatically finished it as if I had typed a tab, then of course received the remainder of the command from the paste, and got all upset about the syntax. At that point, the command prompt line, which usually ends with a single “>”, changed to a double “>>”, and the terminal session was stuck in this “automatic completion” mode for the remainder of the session, even for things I typed by hand. I tried a number of things to get back to normal mode, but failed – the only way I could find to get out was to close the terminal window and start another one.

After a LONG time looking through the wiki, it looks like I probably entered something called “hotlock mode,” which isn’t described anywhere. I’m mildly curious about what it’s for, but my major question is, how do I avoid triggering it every time I want to paste things into a terminal window? Also how do I turn it off without re-pasting the same text over again?

(It also explains why I have never seen this behavior before, because “paste” is not ^V on the Macintosh.)

http://forum.mikrotik.com/t/partial-names-fill-automatically-bug-or-feature/35015/1
Don’t hit ctrl-v, basically.

Great, so how do you paste stuff to the terminal while using Windows? Even the “Paste” contextual menu triggers this behavior.

What version are you running? What version of the loader are you running?

I can’t reproduce that in Windows or OS X via Wine. Copy/paste via the context menu works fine, ctrl-v doesn’t actually do anything at all.

You may be correct. It’s quite possible that the sequence of operations that actually occurred was that I first typed in ^V expecting it to paste my clipboard, which didn’t happen, but it turned on hotlock mode with no indication. I then used the contextual menu to paste, which failed horribly because the connection was now in hotlock mode.

I think I understand what is going on now, thanks. At least knowing how to get back out of hotlock mode is a crucial improvement in my knowledge.

Might I suggest to the PTB that this should be documented somewhere more official than in a lone forum posting (well, two now)? There is a single mention of hotlock mode in the wiki, and it leads to a page with no content.