[U-Boot-Users] Unclear points on NETCONSOLE script

Hi all,
I tested netconsole on RPXlite DW and succeeded. But still several unclear points in mind. All for the doc/README.Netconsole itself.
1. $1 should be replaced as TARGET IP or not?
+++++++++++++++++++++++++++++++++++++++++++ #! /bin/bash
TARGET_IP=$1
stty -icanon -echo intr ^T nc -u -l -p 6666 < /dev/null & nc -u ${TARGET_IP} 6666 stty icanon echo intr ^C +++++++++++++++++++++++++++++++++++++++++++
If I used the above script on my RED HAT 7.3 host PC, u-boot console could switch to host console but any input didn't work. When $1 was replaced as TARGET IP like 192.168.0.11, the above script can work right. Is the given script a common one or should be fixed as TARGET_IP=<TARGET_IP>?
2. mpc5200 should be changed as TARGET IP or not?
+++++++++++++++++++++++++++++++++++++++++++ #! /bin/bash
stty icanon echo intr ^T ./ncb & nc -u mpc5200 6666 stty icanon echo intr ^C kill 0 +++++++++++++++++++++++++++++++++++++++++++
This script can only work right when mpc5200 is changed by TARGET IP like 192.168.0.11. So, should mpc5200 tagged with <TARGET IP> as well?
3. Why use Ctrl + T rather than Ctrl + C to interrupt the script status?
In both scripts, only Ctrl + T can interrupt script status. Why not Ctrl + C? This one should be more common to use. Can we change it for more reasonable?
Input is welcome. I am willing to send a patch to correct them if need:-)
Best regards,
Sam
_________________________________________________________ Do You Yahoo!? 150万曲MP3疯狂搜,带您闯入音乐殿堂 http://cn.rd.yahoo.com/mail_cn/tag/yisou/music/*http://music.yisou.com/ 美女明星应有尽有,搜遍美图、艳图和酷图 http://cn.rd.yahoo.com/mail_cn/tag/yisou/image/*http://image.yisou.com 1G就是1000兆,雅虎电邮自助扩容! http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1...

In message 20050331143606.88702.qmail@web15910.mail.cnb.yahoo.com you wrote:
I tested netconsole on RPXlite DW and succeeded. But still several unclear points in mind. All for the doc/README.Netconsole itself.
- $1 should be replaced as TARGET IP or not?
No. This is a shell script, so the shell will substitute the first argiument to the script here.
If I used the above script on my RED HAT 7.3 host PC, u-boot console could switch to host console but any input didn't work. When $1 was replaced as TARGET IP like 192.168.0.11, the above script can work right. Is the given script a common one or should be fixed as TARGET_IP=<TARGET_IP>?
Just call it and pass the IP address (or host name, assuming DNS is working) as first parameter.
- mpc5200 should be changed as TARGET IP or not?
Yes (or host name, assuming DNS is working)
- Why use Ctrl + T rather than Ctrl + C to interrupt
the script status?
Because ^C is used by U-Boot, too, and we need a (simple) way to pass it through while still being able to terminate the script.
In both scripts, only Ctrl + T can interrupt script status. Why not Ctrl + C? This one should be more
Because ^C is passed through to the U-Boot console.
common to use. Can we change it for more reasonable?
This is perfectly reasonable - pressing ^C at the U-Boot console does what is reasonablke: terminating the running U-Boot command (instead of throwing you out of the remote session).
Best regards,
Wolfgang Denk
participants (2)
-
Sam Song
-
Wolfgang Denk