Semi-automation Script Based on Sleep
The following script auto login to server 49, send 2 commands and exit from the server.
- Create a automation script named "auto.sh":
echo "open 10.0.2.49 -l gcp"
sleep 2
echo "gcp"
sleep 1
echo "ls"
sleep 1
echo "pwd"
sleep 3
echo "hadoop fs -put /home/boco/gdpp/91/ hdfs://cloud216:8020/user/boco/gsp/yyyy > mylog"
sleep 3
echo "exit"
Make the script executable: chmod 755 auto.sh;
$ ./auto.sh|telnet
Ref: http://stackoverflow.com/questions/7013137/automating-telnet-session-using-bash-scripts
Semi-automation Script Based on Sleep的更多相关文章
- Automation Script For Percona Xtrabackup FULL/Incremental
This is my first post in 2019, and Im starting with a MySQL solution. In MySQL world, implementing a ...
- Automation Testing - Best Practice(书写规范)
Coding Standards Coding Standards are suggestions that will help us to write automation Scripts code ...
- BlackArch-Tools
BlackArch-Tools 简介 安装在ArchLinux之上添加存储库从blackarch存储库安装工具替代安装方法BlackArch Linux Complete Tools List 简介 ...
- VCAP5-DCA – What’s new?
see also: 韩国人的教材:http://ddii.pe.kr/ Section 1.1 – Implement and Manage complex storage Determine use ...
- Expect Command And How To Automate Shell Scripts Like Magic
In the previous post, we talked about writing practical shell scripts and we saw how it is easy to w ...
- pdf 中内容的坐标系
PDF Page Coordinates (page size, field placement, etc.) AcroForm, Basics, Automation Page coordinate ...
- Linux Expect自动交互脚本
https://likegeeks.com/expect-command/ In the previous post, we talked about writing practical shell ...
- splash-简介及入门
splash 1. splash简介 Splash是一个JavaScript渲染服务,是一个带有HTTP API的轻量级浏览器,同时它对接了Python中的Twisted和QT库.利用它,我 ...
- MySQL集群搭建(5)-MHA高可用架构
1 概述 1.1 MHA 简介 MHA - Master High Availability 是由 Perl 实现的一款高可用程序,出现故障时,MHA 以最小的停机时间(通常10-30秒)执行 mas ...
随机推荐
- ps 快速替换背景颜色
1.打开图片: 点击工具栏上的"选择"--色彩范围--按[delete]
- CentOS-yum安装Nginx
查看系统版本 $ cat /etc/redhat-release Nginx 不在默认的 yum 源中,使用官网的 yum 源 $ rpm -ivh http://nginx.org/packages ...
- pybot参数
p.p1 { margin: 0; font: 12px "Helvetica Neue" } p.p2 { margin: 0; font: 12px "Helveti ...
- 使用Hugo框架搭建博客的过程 - 主题配置
前言 博客部署完成后,恭喜你可以发表第一篇:Hello world!但是LoveIt这么好用的主题,不配置一番可惜了. 基本功能配置 主题配置最好参考已有的配置,比如LoveIt作者写的介绍,还有主题 ...
- 视图:DBA_TAB_PARTITIONS 分区表视图
Column Datatype 释义 Description TABLE_OWNER VARCHAR2(128) 表的owner Owner of the table TABLE_NAME VARCH ...
- 使用Nginx将请求转发至Google Analytics实现后端数据统计
前言 Google Analytics 加载缓慢是本博客在国内访问缓慢的原因之一.虽然通过使用大公司的 ga.js 的 CDN ,可以很大程度上加快加载 ga.js 文件的速度( ga.js 的更新频 ...
- Python之手把手教你用JS逆向爬取网易云40万+评论并用stylecloud炫酷词云进行情感分析
本文借鉴了@平胸小仙女的知乎回复 https://www.zhihu.com/question/36081767 写在前面: 文章有点长,操作有点复杂,需要代码的直接去文末即可.想要学习的需要有点耐心 ...
- 一行代码打印python之禅
就这一句: import this 输出: The Zen of Python, by Tim Peters Beautiful is better than ugly. Explicit is be ...
- 传统.NET 4.x应用容器化体验(3)
上一篇我们自己通过编写Dockerfile来编译部署一个ASP.NET MVC应用程序到Windows Container,这一篇我们来试着将.NET 4.x的镜像推送到harbor私有镜像仓库. 1 ...
- Java学习之注解篇
Java学习之注解篇 0x00 前言 续上篇文章,这篇文章就来写一下注解的相关内容. 0x01 注解概述 Java注解(Annotation)又称Java标注,是JDK5.0约会的一种注释机制. 和J ...