hillpig的个人博客分享 http://blog.sciencenet.cn/u/hillpig 畅想ing,思考ing,前行ing Email:bluevaley@gmail.com

博文

我使用的linux 常见命令

已有 3595 次阅读 2011-4-22 15:43 |个人分类:linux|系统分类:科研笔记| Linux

1.查看硬盘型号
[root@localhost postgres]# hdparm -i /dev/sda
结果如下:
/dev/sda:
Model=HITACHI, FwRev=SB4IC7UP, SerialNo=SB2441GJJBJZJE...

2.查看硬盘大小
在Red Hat Enterprise Linux 6下:
[root@localhost postgres]# dmesg|grep sd
结果如下:
sd 0:0:0:0: [sda] 312581808 512-byte logical blocks: (160 GB/149 GiB)...

3.增加lib搜索路径
最近发现postgis中用到的库有些是在/usr/local/lib中,而RHEL 6 却找不到,故使用:
[root@localhost postgres]# gedit /etc/ld.so.conf
修改这个文件,增加一行:/usr/local/lib,即最终的文件为:
include ld.so.conf.d/*.conf
/usr/local/lib
然后再重新载入一下:
[root@localhost postgres]# ldconfig
即可。
当然也可以通过命令:
[root@localhost postgres]# export LD_LIBRARY_PATH=/opt/gtk/lib:$LD_LIBRARY_PATH
临时修改,然后用下面的命令查看 LD_LIBRAY_PATH 的设置内容:
[root@localhost postgres]# echo $LD_LIBRARY_PATH

4.修改80端口转向8080端口
Tomcat: redirecting traffic from port 8080 to 80 using iptables
参考:http://glassonionblog.wordpress.com/2011/04/08/tomcat-redirecting-traffic-from-port-8080-to-80-using-iptables/
# netstat -ntl
# iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080
# iptables -t nat -L




在Linux环境下编译安装配置PostGIS/PostgreSQL全过程
http://blogold.chinaunix.net/u/12056/showart_2038794.html

加我私人微信,交流技术。




https://blog.sciencenet.cn/blog-419883-436174.html

上一篇:install virtualbox 4.0 on red hat enterprise linux(rhel) 6.0
下一篇:rhel6+postgresql8.4+postgis1.4+eclipse CDT3.6 调试环境搭建
收藏 IP: 223.72.72.*| 热度|

1 黄富强

该博文允许注册用户评论 请点击登录 评论 (0 个评论)

数据加载中...

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-4-23 23:20

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部