免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2146 | 回复: 3
打印 上一主题 下一主题

有关echo命令 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2009-07-16 20:07 |只看该作者 |倒序浏览
主机升级, 要把一些script拷到新机器上, 在原来机器上工作好好的,但在新机器上怎么都不工作, echo 命令没有打开xterm窗口.


#!/bin/ksh
#  Script name: send.file
# to read from /transfer
# to use ftp transfer - rcp and rlogin disabled in Solaris 8
#   Script to compress files and copy to zz
# Files copied to /transfer at zz
echo "To transfer patients to zz press enter else press Control C"
read anykey
echo ""
echo  "The files available are:"
echo ""
cd /transfer
ls -C |more
echo ""
echo "Enter file to transfer to zz"
read pat
compress -f $pat
echo ""
echo "Transferring file - "$pat
ftp -i -n -v << EOT
open footscray
user han han
cd /transfer
binary
hash
put $pat.Z
bye
EOT
echo "Finished"
#
rsh zz uncompress /transfer/$pat.Z
exit


哪位帮我看看问题出在哪儿呢?

还有那个"EOT" 是什么意思呢?

谢谢

论坛徽章:
0
2 [报告]
发表于 2009-07-16 20:42 |只看该作者
检查执行用户的shell

论坛徽章:
0
3 [报告]
发表于 2009-07-17 15:21 |只看该作者
1.whether the user have the same path as perivous, which can recognize all your commands.
2. EOT like EOF which you can define whatever you like, start with Eot and end with EOT

论坛徽章:
2
丑牛
日期:2014-06-11 13:55:04ChinaUnix元老
日期:2015-02-06 15:16:14
4 [报告]
发表于 2009-07-17 15:23 |只看该作者
EOT你可以随便写,比如AAA,bbb,
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP