初涉linux(四)之gdb及网络配置

4.1讲义
4.1.1gdb调试
gdb 调试可执行文件
要使用gdb,gcc必须加-g参数
l N //list 10 lines around the line N
l N,M //list the lines from N to M
b break //set breakpoint
b N if key==value //stop the line N when key=value
info break //list the breakpoints
del N //delete the breakpoint N
clear N //delete the breakpoint setted in the line N
r /start program
next ,n //execute next line,after starting
print 变量 //
where
continue //jump next breakpoint
until N
b N if i=M
step //jump into
watch i //****after runing
4.1.2网络服务
4.1.2.1基本操作
网络服务的开启部分,一般都是三步:
第一步:修改相应的网络配置服务
第二步:开启setsebool参数
第三步:重启服务
一般的网络服务开启大都如此,但是网络比较复杂,可变因素很多,
包括防火墙,或者特定服务特定系统等原因,每个的设置部分又有所
不同。

4.1.2.2NFS的配置(仅限于fedora8)
/etc/exports 加入/path/directory *(rw,sync,no_root_squash)
service nfs
mount -t hostname(ip):/path/directory /local/path/directory
4.1.2.3telnet的配置
/etc/xinetd.d/telnet disable=no
lokkit关闭防火墙,或者service iptables stop
setsebool telnetd_disable_trans=1
service xinetd restart
可使用secureCRT工具:建设不用root登录
4.1.2.4tftp的配置
/etc/xinetd.d/tftp disable=no
setsebool tftpd_disable_trans=1
service xinetd restart
只可从/tftproot下访问
4.2.1 问题
4.2.1.1gdb的display命令如何使用
([color=red]执行过程中display expression总显示expression的值[/color])
display expression
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值