linux 日常使用记录

来源:互联网 发布:iphone7怎么信任软件 编辑:程序博客网 时间:2024/05/15 12:29

1. ubuntu/redhat 下ssh命令重启命令:/etc/rc.d/init.d/sshd restart

2. linux  下apache 配置文件默认地址:/etc/httpd/conf/httpd.conf
3. linux 下apache的重启方法:/etc/init.d/httpd  restart 

4. 查看系统的THP的状态: cat /sys/kernel/mm/transparent_hugepage/enabled

 5. dpkg 提示linux-generic错误时,可能是软件安装失败导致的,系统状态混乱,需要卸载一些软件。运行如下命令:

sudo apt autoremove

6. linux下安装本地deb文件的一个很好的工具:gdebi,可以自动下载依赖。

7. 安装软件源时,如果提示说no pulic key,,可以尝试获取key.

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 8D5A09DC9B929006

8. when run sudo apt-get update ,security.ubuntu.com  can be very slow or stunked. this can be pass around by gedit  /etc/gai.conf. then unmomment this line.

##    For sites which prefer IPv4 connections change the last line to#precedence ::ffff:0:0/96  100

9. ubuntu 动态链接库的添加:修改/etc/ld.so.conf文件,新添加一行你要添加的动态链接库路径即可。 可以解决在IDE里无法使用已安装软件的so文件(明明存在却说找不到,如theano GPU配置后,IDE里老是提示cuda-7.5.so不存在,但是其实是有这个文件。)

...................................................不断更新维护中,...................................................................................

1 0
原创粉丝点击