README.NetConsole 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. In U-Boot, we implemented the networked console via the standard
  2. "devices" mechanism, which means that you can switch between the
  3. serial and network input/output devices by adjusting the 'stdin' and
  4. 'stdout' environment variables. To switch to the networked console,
  5. set either of these variables to "nc". Input and output can be
  6. switched independently.
  7. On the host side, please use this script to access the console:
  8. +++++++++++++++++++++++++++++++++++++++++++
  9. #! /bin/bash
  10. TARGET_IP=$1
  11. stty -icanon -echo intr ^T
  12. nc -u -l -p 6666 < /dev/null &
  13. nc -u ${TARGET_IP} 6666
  14. stty icanon echo intr ^C
  15. +++++++++++++++++++++++++++++++++++++++++++
  16. For Linux, the network-based console needs special configuration.
  17. Minimally, the host IP address needs to be specified. This can be
  18. done either via the kernel command line, or by passing parameters
  19. while loading the netconsole.o module (when used in a loadable module
  20. configuration). Please refer to Documentation/networking/logging.txt
  21. file for the original Ingo Molnar's documentation on how to pass
  22. parameters to the loadable module.
  23. The format of the kernel command line parameter (for the static
  24. configuration) is as follows:
  25. netconsole=[src-port]@[src-ip]/[<dev>],[tgt-port]@<tgt-ip>/[tgt-macaddr]
  26. where
  27. src-port source for UDP packets
  28. (defaults to 6665)
  29. src-ip source IP to use
  30. (defaults to the interface's address)
  31. dev network interface
  32. (defaults to eth0)
  33. tgt-port port for logging agent
  34. (defaults to 6666)
  35. tgt-ip IP address for logging agent
  36. (this is the required parameter)
  37. tgt-macaddr ethernet MAC address for logging agent
  38. (defaults to broadcast)
  39. Examples:
  40. netconsole=4444@10.0.0.1/eth1,9353@10.0.0.2/12:34:56:78:9a:bc
  41. or
  42. netconsole=@/,@192.168.3.1/
  43. Please note that for the Linux networked console to work, the
  44. ethernet interface has to be up by the time the netconsole driver is
  45. initialized. This means that in case of static kernel configuration,
  46. the respective Ethernet interface has to be brought up using the "IP
  47. Autoconfiguration" kernel feature, which is usually done by defaults
  48. in the ELDK-NFS-based environment.
  49. To browse the Linux network console output, use the 'netcat' tool invoked
  50. as follows:
  51. nc -u -l -p 6666