由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Unix版 - [转载] sed question
相关主题
[转载] 请教Sun Ultra 1 上的外置SCSI硬盘How to use tar to read file on tape?
Re: [转载] How to install Solaris 7 Over NT?[转载] 帮个忙:我的scsi光驱改不回来了
请诊断:还是SUN的问题请教
FreeBSD下,是否支持ultra SCSI 160[转载] Help installing SuSe on PowerEdge 1600sc
can SPARC Station 5 or 20 recognize IBM DMVS COMP IEC-950 LVD 9G scsi harddisk?[转载] 如何启动没有软驱和CDROM的sun机器?
Re: just get a sparc 2, qing qiao: who know how to load os好象机子要玩蛋了.
Help! 在unix系统下如何用CD-writer制作CD?blade 2500 internal SCSI disk
实验室的unix机器不能boot起来了, 求救。。。惨啊!all folders, programs, settings gone!
相关话题的讨论汇总
话题: scsi话题: sed话题: config话题: multi话题: lun
进入Unix版参与讨论
1 (共1页)
i****d
发帖数: 7
1
【 以下文字转载自 Linux 讨论区 】
【 原文由 Iamold 所发表 】
file1.txt contains
asdfasdf
adsf
asdfasdfsdf
#ifdef CONFIG_SCSI_MULTI_LUN
static int max_scsi_luns = 32;
#else
static int max_scsi_luns = 1;
#endif
I want to replace lines from CONFIG_SCSI_MULTI_LUN to #endif
how to do this by using sed?
the following command yielded a wrong output...
sed '/CONFIG_SCSI_MULTI_LUN/,/endif/{c\
#ifdef CONFIG_SCSI_MULTI_LUN\
static int max_scsi_luns = 32;\
#else\
static int max_scsi_luns = 1;\
#endif
;}' file1.txt > output.txt
1 (共1页)
进入Unix版参与讨论
相关主题
惨啊!all folders, programs, settings gone!can SPARC Station 5 or 20 recognize IBM DMVS COMP IEC-950 LVD 9G scsi harddisk?
how to config my networks.Re: just get a sparc 2, qing qiao: who know how to load os
[转载] my /cgi-bin/ don't work!? help!Help! 在unix系统下如何用CD-writer制作CD?
how to config keyboard in Solaris?实验室的unix机器不能boot起来了, 求救。。。
[转载] 请教Sun Ultra 1 上的外置SCSI硬盘How to use tar to read file on tape?
Re: [转载] How to install Solaris 7 Over NT?[转载] 帮个忙:我的scsi光驱改不回来了
请诊断:还是SUN的问题请教
FreeBSD下,是否支持ultra SCSI 160[转载] Help installing SuSe on PowerEdge 1600sc
相关话题的讨论汇总
话题: scsi话题: sed话题: config话题: multi话题: lun