特牛网址导航

解决sed -i报错:_sed -i \1报错-CSDN博客

网友收藏
文章浏览阅读382次。sed -i.bak '/.*CMDLINE_LINUX.*/s#(.*)"#\1 net.ifnames=0"#' /etc/default/grub然后一直报错: sed: -e expression #1, char 44: invalid reference \1 on `s’ command’s RHSsed -i -r '/.*CMDLINE_LINUX.*/s#(.*)"#\1 net.ifnames=0"#' /etc/default/grub后面才知道是需要加个 -r 因为 _sed -i \1报错
标签:sed -i \1报错