Community discussions

MikroTik App
Cartman
Member Candidate
Member Candidate
Topic Author
Posts: 104
Joined: Wed Jul 23, 2008 6:14 pm

Terminal, autocompletion when pasting commands

Wed Jan 28, 2015 9:49 pm

Hello world !!!

I have a problem when I try to paste to export of a configuration of one MikTik to another.

When I have
Code:Select all
add address=10.128.60.58 client-id=1:bc:8c:cd:b7:30:cd mac BC:8C:CD:B7:30:CD server=dhcp1
in /ip dhcp-server lease

the terminal of the winbox autocompletes the commands beginning from the first letter :
the above results in
Code:Select all
add dd address=10.128.60.58 client-id=1:bc:8c:cd:b7:30:cd mac BC:8C:CD:B7:30:CD server=dhcp1
and gives an error

Trying
Code:Select all
a address=10.128.60.58 client-id=1:bc:8c:cd:b7:30:cd mac BC:8C:CD:B7:30:CD server=dhcp1
results in
Code:Select all
add addressddress=10.128.60.58 client-id=1:bc:8c:cd:b7:30:cd mac BC:8C:CD:B7:30:CD server=dhcp1
I do not know from which release this behaviour startet.
I first saw it in 6.25.
Copying a complete configuration will get kind of exhausting with that.


THX
Top
User avatar
NathanA
Forum Veteran
Forum Veteran
Posts: 829
Joined: Tue Aug 03, 2004 9:01 am

Re: Terminal, autocompletion when pasting commands

Wed Jan 28, 2015 11:28 pm

You must be somehow accidentally engaging HotLock mode: seethis page of the manualon the wiki.

If you are not hitting Ctrl-V yourself, perhaps the same ASCII value that Ctrl-V would generate has somehow made it into the script or config that you are copying into the terminal.

If you are copying directly from one MikroTik console/terminal to another, rather than pasting it directly into the other terminal, try to first paste it into an intermediate destination, such as a text editor (Notepad? TextEdit in Plain Text mode? vi in some other console?), and then re-copying it from that. I have found that some of the ANSI terminal control characters that influence the formatting and coloring of the text in a RouterOS console can get captured into the clipboard buffer, and can cause trouble when being pasted into another RouterOS console. Pasting the clipboard into another place and re-copying it can effectively filter out those rogue bytes.

Alternatively, if you log into RouterOS by suffixing a "+tc" to the end of the username (e.g., "admin+tc"), this will disable the funky color and terminal auto-detection characters from being generated, which may make copying-and-pasting between terminals work much more smoothly; seethis section of the manual(console login process) for more information.

-- Nathan
Top
Cartman
Member Candidate
Member Candidate
Topic Author
Posts: 104
Joined: Wed Jul 23, 2008 6:14 pm

Re: Terminal, autocompletion when pasting commands

Fri Jan 30, 2015 12:13 am

Thank you Nathan.
It seems that I hit CRTL-V for pasting the code and got into the HotLock mode.
Today everything worked again.
Top
User avatar
NathanA
Forum Veteran
Forum Veteran
Posts: 829
Joined: Tue Aug 03, 2004 9:01 am

Re: Terminal, autocompletion when pasting commands

Fri Jan 30, 2015 1:02 am

Ah, yes. Ctrl-V is the keyboard shortcut for Paste in Windows. I have absent-mindedly tried to paste into Winbox using Ctrl-V many, many times, which is why I am so well acquainted with HotLock.

You have never been able to paste into a Winbox terminal using Ctrl-V; you must right-click and hit 'Paste' in the pop-up menu. This is not a new thing as of 6.25.

-- Nathan
Top

Who is online

Users browsing this forum:Bing [Bot],genesispro,Google [Bot],peterdaand 11 guests