LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 06-26-2008, 01:42 PM   #1
ashtank
LQ Newbie
 
Registered: Jun 2008
Posts: 4

Rep: Reputation: 0
Completely usb based serial console server, possible???


Hello and thanks for reading.

The idea is to setup a centralized server that I can access when my network is down and view all of the console messages sent out by all of the hosts on my network.

I've been doing a little reading and this seems possible, but I was wondering if it might be possible to, instead of buying these serial to usb cables, to have grub setup to redirect the serial console output to a usb device, so that I can just connect all of my hosts with normal usb cables?














Thoughts, comments and solutions are not only welcomed but encouraged and greatly appreciated.
 
Old 06-26-2008, 05:26 PM   #2
MS3FGX
Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 351Reputation: 351Reputation: 351Reputation: 351
I don't believe that you can get GRUB to understand such a configuration, and I know for sure that you shouldn't be directly connecting computers together with USB cables (A/M to A/M cables are actually out of the USB spec in the first place).
 
Old 06-26-2008, 06:39 PM   #3
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,812

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
I believe it is possible to use a USB serial port as a console device for 2.5+ kernels. AFAIK any messages prior to USB initialization will be lost.

As stated you can not directly connect two PCs via a regular USB cable for a couple of reasons.
You can only have one controller per bus and you will short out the 5 VDC power bus and possibly damage the computer. One possibility would be if your "USB device" would act like a specialized RS232 multiplexer. Each port would act like a RS232 device similar to many PDA and GPS devices. I am not aware of any such device.
 
Old 06-27-2008, 12:15 PM   #4
ashtank
LQ Newbie
 
Registered: Jun 2008
Posts: 4

Original Poster
Rep: Reputation: 0
let me clarify.

I wasn't planning on plugging the computers into each other directly, I was going to use a usb hub of some sort. Would that work or would it still blow up my computer?

Also based on this document http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/ and this document http://www.linuxdynasty.org/how-to-s...-on-linux.html

It would seem that I could redirect the console output to a usb device(i.e. ttyUSB0 or something).

As to the multi-plexer, one can purchase cables that can connect a RS232 to a usb port, hence the usb hub(multiplexer?).

but I'm trying to avoid buying these extra cables. I've got tons of usb cables lying around.
 
Old 06-27-2008, 02:08 PM   #5
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,812

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
A regular hub will not work because you can not have more then one controller on a bus. Each computer's USB port is a controller. Hubs are powered or distribute power from the computer so the possibility of damaging something is possible.

There are hub devices where you can connect multiple computers for sharing printers for example. These are manual/automatic switch devices for sharing a printer for example. These will not work either since the computers are isolated from each other and connecting them to the wrong port will not work either.

The device I was suggesting does not exist AFAIK but just an idea that would meet your requirements. I do not know of any other way except for USB-RS232 adapters.

Just curious under what circumstances would your network be down?
 
Old 06-27-2008, 03:02 PM   #6
ashtank
LQ Newbie
 
Registered: Jun 2008
Posts: 4

Original Poster
Rep: Reputation: 0
Power surge fries our UPS's and switches, causing our network to be down.

I guess our network being down isn't really what i'm trying to solve here. The end point I'd like to reach would be, when a host dies, crashes, shutsdown or explodes. I'd like to be able to take a look at the console output of maybe the last couple minutes before the host died. In the hope that it might shed light on why the host died.
 
Old 06-27-2008, 03:47 PM   #7
MS3FGX
Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 351Reputation: 351Reputation: 351Reputation: 351
In that case, a centralized log server would seem to be a much more realistic approach.
 
Old 07-31-2008, 03:33 PM   #8
ashtank
LQ Newbie
 
Registered: Jun 2008
Posts: 4

Original Poster
Rep: Reputation: 0
But what if the nic is the first thing to go down?
There wouldn't be any messages on the log server about what happened after the network connection was lost.

The same issue applies to the console port but I would suspect that the NIC is more likely to loose connection than the console port dying.
 
Old 07-31-2008, 05:38 PM   #9
frob23
Senior Member
 
Registered: Jan 2004
Location: Roughly 29.467N / 81.206W
Distribution: Ubuntu, FreeBSD, NetBSD
Posts: 1,449

Rep: Reputation: 47
Quote:
Originally Posted by ashtank View Post
But what if the nic is the first thing to go down?
There wouldn't be any messages on the log server about what happened after the network connection was lost.

The same issue applies to the console port but I would suspect that the NIC is more likely to loose connection than the console port dying.
It's an interesting suspicion but one I have never encountered in the real world. In the event that the NIC does go out, you can retrieve logs from the machine itself. But if the whole machine goes down before those logs can be written and before they can be sent over the network... a USB connection isn't going to provide more information either.

I use a serial console on one of my servers only for the one case where the network does go down and I need to log into that (still functioning) machine and bring the network back up. Of course, it doesn't just go down... unless I am playing with it.

A centralized log server, as mentioned above: will meet all the requirements you're seeking, has little in the way of configuration setup and maintainance, and is not going to require additional hardware/cables which add another layer of possible failure.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using USB<->Serial and serial gender changer to transmit data between computers JoeyAdams Linux - Hardware 4 04-17-2008 05:15 AM
Configuring a USB to Serial Cable to connect to a console port on a HP Procurve jamtech Linux - Networking 3 01-22-2008 07:30 AM
LXer: Interactive and completely browser-based services from IBM R&D LXer Syndicated Linux News 0 09-27-2006 09:21 PM
LXer: Linux-based device server sprouts USB interface LXer Syndicated Linux News 0 08-11-2006 04:54 PM
zoom external serial with usb to serial adapter foustware Linux - Hardware 1 12-07-2003 02:02 AM


All times are GMT -5. The time now is 09:46 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration