Community discussions

MikroTik App
 
User avatar
otgooneo
Trainer
Trainer
Topic Author
Posts: 581
Joined: Tue Dec 01, 2009 3:24 am
Location: Mongolia
Contact:

RB as serial console

Thu Jun 21, 2012 1:36 pm

I want to use routerboard as console server. Is there any way to do this?

Option1. Use miniPCI serial console card. For example http://microcontrollershop.com/product_ ... ts_id=2459
Option2. Use miniPCI USB card and plug again USB to RS232 converter, which is supported by ROS (USB U209-000-R Serial-Port)

Please advise if anyone used before what I want.
 
User avatar
NathanA
Forum Veteran
Forum Veteran
Posts: 829
Joined: Tue Aug 03, 2004 9:01 am

Re: RB as serial console

Thu Jun 21, 2012 2:19 pm

Option 3: Get a RouterBOARD model with built-in USB (such as the RB750UP), plug a powered 4-port USB hub into it, and then get 4 USB to RS232 adapters.

I'm 99% sure that this will work. I have personally used an USB to RS232 adapter with an RB751U, and although I have not tried it, other forum posts indicate that you can use a USB hub with a RouterBOARD to increase the number of USB ports. I suggest a powered one only because I don't know if the total power draw of multiple USB to RS232 adapters can be handled solely by the RouterBOARD or not; better safe (over-engineered) than sorry!

-- Nathan
 
User avatar
otgooneo
Trainer
Trainer
Topic Author
Posts: 581
Joined: Tue Dec 01, 2009 3:24 am
Location: Mongolia
Contact:

Re: RB as serial console

Thu Jun 21, 2012 5:53 pm

Hi NathanA. Good idea. Thanks.
Does anyone tried before USB hub with RB?
 
jadu
Frequent Visitor
Frequent Visitor
Posts: 86
Joined: Sat Feb 05, 2011 9:22 am
Location: Bucharest - Constanta

Re: RB as serial console

Fri Jul 13, 2012 3:17 pm

I'he tried USB Hub with a 4GB flash USB and a 3G modem (Huawei E1750) working simultaneously.
And also tried with one 4GB and a 8GB flash sticks.
Working both!
 
tomchinese
just joined
Posts: 2
Joined: Fri Jan 20, 2012 4:11 pm

Re: RB as serial console

Mon Feb 25, 2013 7:44 am

I have an application need to connect a USB hub to RB751U, there is a very wired issues as below:

1. RB751U is connected to a usb hub;

2.Usb serial convertor is connected to usb hub;

3.RB751U is found the usb hub and usb serial convertor, and connect this convertor to a normal computer with serial.

4. open a new terminal in winbox, and type /system serial-terminal usb1 channel=0

5. open a hyper terminal on the computer.

6.the serial port of the computer can received any typing from RB751U, But the RB751U can not receive any typing from the computer.

For sure the RB751U can receive the typing from computer when the usb serial convertor is connected to RB751U directly.

Anyone have the same issues? Really appreciate for any help!
 
User avatar
jacekes
Member Candidate
Member Candidate
Posts: 167
Joined: Tue Aug 30, 2011 9:34 am
Location: Poznan, Poland
Contact:

Re: RB as serial console

Sun Mar 24, 2013 11:18 pm

Hi,

I have a similar problem as described above. I guess it's not a bug in RB, but maybe you guys can give me some feeddback. I need a configuration like this:
Image
I've got everything working except for the USB hub. I've tried several different types, powered and passive, nothing works. I've also tried different USB-RS232 converters, several based on the PL2303 chipset and a couple of FTDI based converters. They all work perfectly when connected directly to the USB port in the RouterBoard, so does the USB modem, but I haven't found a USB hub which would let me use a couple of devices simultaneously.

Has anyone got a hub, that works correctly with USB-RS232 converters? What make/model is it? It would be best if it had more than 4 ports.
I know it's kind of a weird workaround, because all the network devices should be managed over IP, but there are situations when IP-based management fails.

I'm looking forward to your replies. ;)

Best regards!
 
User avatar
otgooneo
Trainer
Trainer
Topic Author
Posts: 581
Joined: Tue Dec 01, 2009 3:24 am
Location: Mongolia
Contact:

Re: RB as serial console

Mon Mar 25, 2013 4:35 am

Hi, jacekes
I also want to know whether USB hub support or not. If you solve your issue, please share your solution here.
 
vchrizz
just joined
Posts: 23
Joined: Sun Jul 10, 2016 11:07 am
Location: Austria, Vienna
Contact:

Re: RB as serial console

Thu Mar 07, 2019 1:44 am

(sorry posting to this old thread but its the most apropriate one i found)

for me the mentioned prolific usb-rs232 converter basically works great too.

one problem i noticed, it somehow "freezes" after some time when no data is sent or received.
i connect via ssh to rb and then just /system serial-terminal usb1 . this works fine as long as i work on it, type commands or get frequently output.
but while i leave the ssh session open, do something else for about 5-10minutes, then looking back on the ssh session, i can not type anything.

what i tried:
- replace serial-cable: have 3 of them, problem is with every cable.
- not using usb hub: attached just the cable directly to rb - no difference, same problem.
- check if serial-terminal responds: seems ok: ctrl-a prefix-key and functions work to e.g. quit serial-terminal. (but else no input works)
- get some output for long time: print date every second on the serial-terminal device - works for 30+minutes ok.
- check logs: set debug rule and filter everything unrelated out, no log messaged when serial-terminal freezes.
- reboot router: this fixes it until it freezes again. but i found out, full reboot not needed, only usb power-reset fixes it too until next freeze.
- upgrade router: recently updated to (actual stable channel) version 6.44 - problem still there.
- somehow find out after what time it freezes: something between 5min and 10min:
Thu Mar  7 00:13:28 CET 2019
Thu Mar  7 00:13:29 CET 2019
Thu Mar  7 00:13:30 CET 2019
Thu Mar  7 00:13:31 CET 2019
Thu Mar  7 00:13:32 CET 2019
Thu Mar  7 00:13:33 CET 2019
Thu Mar  7 00:13:34 CET 2019
^C
onetrix@mh-router:~$ date
Thu Mar  7 00:13:46 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:14:27 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:18:48 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:24:04 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:30:11 CET 2019
onetrix@mh-router:~$ <-- at about 00:40 no input is accepted
pressing ctrl-a works:
onetrix@mh-router:~$ date
Thu Mar  7 00:14:27 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:18:48 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:24:04 CET 2019
onetrix@mh-router:~$ date
Thu Mar  7 00:30:11 CET 2019
onetrix@mh-router:~$
[Q - quit connection]      [B - send break]
[A - send Ctrl-A prefix]   [R - autoconfigure rate]

what can i check else to find out what causes this issue?

the reason i need this running for long time is because im debugging another device and waiting/watching console for any log messages.

thanks, chris
 
r00t
Long time Member
Long time Member
Posts: 672
Joined: Tue Nov 28, 2017 2:14 am

Re: RB as serial console

Thu Mar 07, 2019 2:07 am

Maybe try a different USB2Serial cable with different (non Prolific) chip. I have had very bad experience with pl2302 based cables, they often stopped working for no reason and were very sensitive.. for example, when connecting it to the managed switch, USB stopped working every time switch was powered off and on again. USB hub port had to be reset or cable unplugged and plugged again for it to work again. Plus when you have to connect them to the Windows machine for testing something, Prolific drivers are pure garbage and constantly cause BSODs on hot-unplug - which is very annoying to work with in the field, when you just don't have time for all this mess... So far FTDI based cables seems to be much better, but YMMV...
 
vchrizz
just joined
Posts: 23
Joined: Sun Jul 10, 2016 11:07 am
Location: Austria, Vienna
Contact:

Re: RB as serial console

Wed Mar 20, 2019 1:11 am

thanks very much for the hint!
i replaced the prolific chipset cable for a ftdi chipset based cable as you recommended and now the issue is gone.
guess this is some important information that should be noted in the wiki, that prolific chipsets are that sensible and its better to use ftdi.
without that information i would still struggle with the issue without knowing the root cause is the prolific chip..
 
r00t
Long time Member
Long time Member
Posts: 672
Joined: Tue Nov 28, 2017 2:14 am

Re: RB as serial console

Thu Mar 21, 2019 12:06 am

Yes, so far I had no issues with FTDI usb to serial converters. They just work and while usually costing bit more, they have all RS232 signals for full hardware handshaking that some equipment may require.
Sadly it's sometimes hard to find what chipset cable uses before you buy it (often same looking cables come with different chips... Chinese clones everywhere).
It's even worse when actual equipment have Prolific converter integrated and you can't change it (like some power meters I had... all replaced by now because of annoying USB issues).
 
vchrizz
just joined
Posts: 23
Joined: Sun Jul 10, 2016 11:07 am
Location: Austria, Vienna
Contact:

Re: RB as serial console

Thu Mar 21, 2019 2:09 am

well, i didnt have problems finding serial usb converter cables with enough description to know which chipset is used. the problem was rather, that nearly all of them are prolific based. then i even noticed, the reason why original prolific drivers dont work and i have to use "prolific-compatible" drivers, is that my prolific cables are some china clones. ftdi converters are mostly sold on a small pcb as module - but not as complete cable with pins and usb type a connector. searching for ftdi chipset on amazon, from about some 20-30 different articles there is only one article which is a cable with usb a connector. similar on dx or aliexpress. for price comparison its not worth to mention, prolific cables go for about 5eur (+/-2eur depending on shop) and ftdi are 2-3eur more "expensive".
@mikrotik: i still think this information should be noted in the wiki to save time users debugging such cases.

Who is online

Users browsing this forum: the2masters and 28 guests