linux环境下如何调试程序(学习笔记)

1、先看了一篇文档:https://blog.csdn.net/wfdtxz/article/details/7368357

2、又看了一篇文档:https://www.cnblogs.com/ChinaHook/p/6083876.html

在通过两篇文档查看之后还是没有解决问题,之前出现得问题都是软件包冲突或者软件包错误等问题
  最后发现是因为自己yum源配置得问题:
           同事帮忙解决问题的过程

[root@localhost douer]# cat /etc/yum.repos.d/
bak/               epel.repo          epel-testing.repo  media.repo
[root@localhost douer]# cat /etc/yum.repos.d/media.repo
[test]
name=CentOS7
baseurl=file:///mnt
enabled=1
gpgcheck=1
gpgkey=file:///mnt/RPM-GPG-KEY-CentOS-7
[root@localhost douer]# ls /mnt/
mnt
[root@localhost douer]# cd /mnt/
[root@localhost mnt]# ls
mnt
[root@localhost mnt]# ll
total 0
-rw-r--r--. 1 root root 0 Jun 15 09:47 mnt
(reverse-i-search)`mount': ^Cunt /dev/cdrom /mnt/
[root@localhost mnt]# umount mnt ##把原来的mnt卸载
umount: mnt: not mounted
[root@localhost mnt]# cd
[root@localhost ~]# umount
anaconda-ks.cfg       .bashrc               .dbus/                .pki/                 .xauthTEMFui
.bash_history         .cache/               initial-setup-ks.cfg  .tcshrc
.bash_logout          .config/              original-ks.cfg       .viminfo
.bash_profile         .cshrc                package/              .xauthHrUhpk
[root@localhost ~]# umount /mnt/
umount: /mnt/: not mounted
[root@localhost ~]# umount /mnt/mnt
umount: /mnt/mnt: not mounted
[root@localhost ~]# cd /mnt/
[root@localhost mnt]# ls
mnt
[root@localhost mnt]# cat mnt
[root@localhost mnt]# ll
total 0
-rw-r--r--. 1 root root 0 Jun 15 09:47 mnt
[root@localhost mnt]# rm -f mnt
[root@localhost mnt]# cd
[root@localhost ~]# mount
mount            mount.fuse       mount.nfs        mountpoint
mount.cifs       mount.glusterfs  mount.nfs4       mountstats
[root@localhost ~]# mount
mount            mount.fuse       mount.nfs        mountpoint
mount.cifs       mount.glusterfs  mount.nfs4       mountstats
[root@localhost ~]# mount /dev/sr0 /mnt/ ##重新进行挂载
mount: /dev/sr0 is write-protected, mounting read-only
[root@localhost ~]# ls /mnt/
CentOS_BuildTag  EULA  images    LiveOS    repodata              RPM-GPG-KEY-CentOS-Testing-7
EFI              GPL   isolinux  Packages  RPM-GPG-KEY-CentOS-7  TRANS.TBL
[root@localhost ~]# yum makecache   ##进行本地缓存
Loaded plugins: fastestmirror, langpacks
epel/x86_64/metalink                                                                                   | 8.3 kB  00:00:00
test                                                                                                   | 3.6 kB  00:00:00
(1/10): epel/x86_64/group_gz                                                                           |  74 kB  00:00:00
(2/10): epel/x86_64/prestodelta                                                                        |  781 B  00:00:01
(3/10): test/group_gz                                                                                  | 155 kB  00:00:00
(4/10): test/filelists_db                                                                              | 6.6 MB  00:00:00
(5/10): test/primary_db                                                                                | 5.6 MB  00:00:00
(6/10): test/o
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值