[root@yrzl-cloud-aio ~]# sh b.sh
b.sh: line 12: warning: here-document at line 7 delimited by end-of-file (wanted `rui')
b.sh: line 13: syntax error: unexpected end of file
[root@yrzl-cloud-aio ~]#
[root@yrzl-cloud-aio ~]#
[root@yrzl-cloud-aio ~]# ls
anaconda-ks1.cfg  CentOS-7-x86_64-DVD-1511.iso  ifcfg-enp9s0  iso    ll    m.sh     packages  qinrui    rr    sou                   yr-cloud-picture-static-ip.iso
anaconda-ks.cfg   i                             ins-packages  k.sh   mmmm  n.sh     pgs       r         rrrr  wget-log
b.sh              ifcfg-enp8s0                  i.sh          ks.sh  mn    package  p.sh      rpmbuild  ruiy  yr-cloud-picture.iso
[root@yrzl-cloud-aio ~]#
[root@yrzl-cloud-aio ~]#
[root@yrzl-cloud-aio ~]# cat b.sh
#!/bin/bash
i=0
for ifMacs in `ifconfig  | grep ether | awk -F' ' '{print $2}' | head -n 2`
do
        #echo $ifMacs
        if [ -z /etc/udev/rules.d/70-persistent-ipoib.rules ];then
        cat >> /etc/udev/rules.d/70-persistent-ipoib.rules <<rui
        SUBSYSTEM==\"net\", ACTION==\"add\", DRIVERS==\"?*\", ATTR{address}==\"${ifMacs}\", ATTR{dev_id}==\"0x0\", ATTR{type}==\"1\", KERNEL==\"eth*\", NAME=\"eth{i}\"
        ruiy
        fi
i=$((i + 1))
done
[root@yrzl-cloud-aio ~]#

warning: here-document at line 7 delimited by end-of-file (wanted `rui')的更多相关文章

  1. bash报错./mq.sh: line 15: warning: here-document at line 10 delimited by end-of-file (wanted `eof')

    [root@localhost tmp]# ./mq.sh./mq.sh: line 15: warning: here-document at line 10 delimited by end-of ...

  2. input01.sh: line 11: warning: here-document at line 4 delimited by end-of-file (wanted `EOF') input01.sh: line 12: syntax error: unexpected end of file

    写了个脚本用cat>>EOF报错如下: input01.sh: line 11: warning: here-document at line 4 delimited by end-of- ...

  3. 解决Warning: unlink(/storage/cache/cache.catalog.language.1556158719): No such file or directory in /system/library/cache/file.php on line 68问题

    ytkah在调试opencart项目时提示Warning: unlink(/storage/cache/cache.catalog.language.1556158719): No such file ...

  4. Evaluation Warning : The document was created with Spire.PDF for .NET.

    由于使用  Spire.Pdf 生成的书签带有 Evaluation Warning : The document was created with Spire.PDF for .NET. 字样 但是 ...

  5. An error occurred at line: 1 in the generated java file问题处理

    tomcat6启动后,加载jsp页面报错,提示无法将jsp编译为class文件,主要报错信息如下: An error occurred at line: 1 in the generated java ...

  6. 报错:An error occurred at line: 22 in the generated java file The method getJspApplicationContext(ServletContext) is undefined for the type JspFactory

    org.apache.jasper.JasperException: Unable to compile class for JSP: An error occurred at line: 22 in ...

  7. -bash: warning: setlocale: LC_CTYPE: cannot change locale (zh_CN.UTF-8mb4): No such file or directory

    前几天登录服务器发现出现了这些个警告,一直没时间去处理他,今天难得有空,处理一下并记录下来,希望可以帮助到有需要的朋友. 警告信息如下: Last login: Tue May :: from 192 ...

  8. 解决UE4项目编辑器启动时出现LogLinker: Warning: Failed to load '/Game/FirstPersonBP/FirstPersonOverview': Can't find file.

    UE4版本:4.24.3源码编译版本 Windows10 + VS2019环境 LogLinker: Warning: Failed to load '/Game/FirstPersonBP/Firs ...

  9. shell函数中eof报错(warning: here-document at line 9 delimited by end-of-file (wanted `EOF'))

    在shell编写函数时,函数中有eof和EOF,如果是在sublime编写按照格式tab缩进会有以下报错 解决办法: 取消函数中的tab缩进,在运行即可

随机推荐

  1. jQuery——jQuery选择器

    基本选择器 # Id选择器 $(“#btnShow”)选择id为btnShow的一个元素 . 类选择器 $(“.liItem”)选择含有类liItem的所有元素 ele 标签选择器 $(“li”)选择 ...

  2. CaffeMFC:caffe.pb.h(2525): error C2059: syntax error : 'constant'

    下边的语句会报 syntax error : 'constant'. static const DimCheckMode STRICT = V1LayerParameter_DimCheckMode_ ...

  3. Java笔记整理列表

    整理Java相关知识点. 2018-11-20 1:Java入门学习 2:Java进阶

  4. 学不好Linux?我们分析看看正确的学习方法是什么-马哥教育

    2018年里,Linux运维的职位数量和平均薪资水平仍然持续了去年的强劲增幅,比很多开发岗位涨的都快.从研究机构的数据来看,Linux职位数量和工资水平涨幅均在IT行业的前五之列,比去年的表现还要好一 ...

  5. zoj 3314 CAPTCHA(纯模拟)

    题目 有些人用深搜写的,当然我这弱弱的,只理解纯模拟... 纯模拟,第一次写了那么长的代码,我自己也是够坚韧不拔的,,,,必须留念啊!!! 注意,G包含C,E包含L,R包含P,(照图说O应该不包含C, ...

  6. Centos 7中,防火墙配置端口规则

    注意:firewalld服务有两份规则策略配置记录,配置永久生效的策略记录时,需要执行"reload"参数后才能立即生效: Permanent:永久生效的 RunTime:现在正在 ...

  7. play snake on windows

    今天和人吃晚饭突然想起来 之前西佳佳老师说小学期会要求两星期撸一个小游戏 有人已经撸完一个俄罗斯方块了... 菜逼我决定从最简单的贪吃蛇玩起... 我是直接参考的这个博客 算是相当简单而且很Low的实 ...

  8. Android学习总结(5)——9个非常有用的Andorid 程序片段

    一,获取系统版本号: PackageInfo info = this.getPackageManager().getPackageInfo(this.getPackageName(), 0); int ...

  9. 玲珑杯1147 - 最后你还是AK了

    1147 - 最后你还是AK了 Time Limit:5s Memory Limit:256MByte DESCRIPTION 今天HHHH遇到了一颗树,这个树有nn个点(nn为偶数),每条边都有一个 ...

  10. Java SE 之 递归方法

    public void removeSon(String id, List<Dept> deptList) { String hql = "from Dept where par ...