boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Unix版 - [转载] sed question
相关主题
[转载] 请教Sun Ultra 1 上的外置SCSI硬盘
Re: [转载] How to install Solaris 7 Over NT?
请诊断:
FreeBSD下,是否支持ultra SCSI 160
can SPARC Station 5 or 20 recognize IBM DMVS COMP IEC-950 LVD 9G scsi harddisk?
Re: just get a sparc 2, qing qiao: who know how to load os
Help! 在unix系统下如何用CD-writer制作CD?
实验室的unix机器不能boot起来了, 求救。。。
How to use tar to read file on tape?
[转载] 帮个忙:我的scsi光驱改不回来了
相关话题的讨论汇总
话题: 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版参与讨论
相关主题
[转载] 帮个忙:我的scsi光驱改不回来了
还是SUN的问题请教
[转载] Help installing SuSe on PowerEdge 1600sc
[转载] 如何启动没有软驱和CDROM的sun机器?
好象机子要玩蛋了.
blade 2500 internal SCSI disk
惨啊!all folders, programs, settings gone!
how to config my networks.
[转载] my /cgi-bin/ don't work!? help!
how to config keyboard in Solaris?
相关话题的讨论汇总
话题: scsi话题: sed话题: config话题: multi话题: lun