Netkiller Linux 手札

Netkiller Linux 手札

Debian/Ubuntu Cookbook

Mr. Neo Chan, 陈景峰

 


中国广东省深圳市宝安区龙华镇
518109
+86 755 29812080
+86 755 29812080

文档出处
http://netkiller.8800.org/
http://netkiller.hikz.com/

版权声明

转载请与作者联系,转载时请务必标明文章原始出处和作者信息及本声明。

文档最近一次更新于 Wed Apr 29 12:49:15 UTC 2009

内容摘要

本文档讲述Linux系统涵盖了系统管理与配置包括:

  1. 域名服务器,代理服务器,防火墙,VPN

  2. WEB服务器 lighttpd apache fastcgi mod_php mod_perl

  3. 数据库服务器,mysql/mysql cluster postgresql

  4. 数据同步,镜像,备份,恢复

  5. 集群,负载均衡

 

对初学Linux的爱好者忠告

玩Linux最忌reboot(重新启动)这是windows玩家坏习惯

Linux 只要接上电源你就不要再想用reboot,shutdown,halt,poweroff命令,Linux系统和应用软件一般备有 reload,reconfigure,restart/start/stop...不需要安装软件或配置服务器后使用reboot重新引导计算机

在 Linux系统里SIGHUP信号被定义为刷新配置文件,有些程序没有提供reload参数,你可以给进程发送HUP信号,让它刷新配置文件,而不用 restart.通过pkill,killall,kill 都可以发送HUP信号例如: pkill -HUP httpd

 


鸣谢

目录

自述
本文目的 内容简介 读者对象 写给读者 作者简介 联系作者
1. Introduction
Open Source and License Distribution information Linux Installation
I. System
2. Directory and File
ls - list directory contents rm - remove files or directories
-bash: /bin/rm: Argument list too long
grep, egrep, fgrep, rgrep - print lines matching a pattern find - search for files in a directory hierarchy date and time
3. Locale
time zone to change system date/time Language
4. Device manager
Device information
dmesg - print or control the kernel ring buffer dmidecode - DMI table decoder 鉴别eth(x) usb device
console / terminal
serial console console timeout TUI (Text User Interface) framebuffer disable x window
Harddisk
Show partition Create partition Format partition Mount partition estimate disk / directory / file space usage
Removable Storage
usb flash CD / DVD
loop devices Network
Network adapter Ethernet Interfaces Mask Gateway sysctl bonding
5. Packages
Debian / Ubuntu 包管理工具
Search Installation Update Remove Status dpkg-reconfigure
tar - GNU tar / compress and decompress
tar examples gzip b2zip
zip, zipcloak, zipnote, zipsplit - package and compress (archive) files RAR
6. Service
update-rc.d runlevel xinetd - replacement for inetd with many enhancements Scheduled Tasks
crontab - maintain crontab files for individual users at, batch, atq, atrm - queue, examine or delete jobs for later execution
7. Profile
shell
8. Permission
User
Add a new user remove an existed user
Group
Add a new group Add a user to the group
9. Process
ps - report a snapshot of the current processes pstree - display a tree of processes pid jobs
& Ctrl + Z jobs fg / bg nohup - run a command immune to hangups, with output to a non-tty
10. Monitor
uptime - Tell how long the system has been running. Memory vmstat - Report virtual memory statistics temperature/voltage/fan strace - trace system calls and signals lsof - list open files input/output statistics
11. X Window
取消开机启动画面 Automatic login Download Software Firefox
II. Network Application
12. network tools
curl / w3m / lynx nmap tcpdump rdesktop - A Remote Desktop Protocol client
13. DNS/Bind
bind9 Load Balancing view tools
14. Proxy Server
Socks 5 Apache Proxy Squid - Internet Object Cache (WWW proxy cache)
源码安装 debian/ubuntu 安装 配置 Squid 管理 禁止页面被Cache Squid 实用案例
Web page proxy
Surrogafier CGIproxy PHPProxy BBlocked Glype Zelune
15. News Group (innd)
User Authentication
16. NET SNMP (Simple Network Management Protocol)
安装SNMP 例出MBI Cacti
17. tcpdump - A powerful tool for network monitoring and data acquisition
监控网络但排除 SSH 22 端口 mysql
III. Security
18. OpenSSH
maximum number of authentication disable root SSH login Automatic SSH / SSH without password disable password authentication Putty OpenSSH Tunnel
SOCKS v5 Tunnel
OpenSSH for Windows
19. ACL - Access Control List
getfacl - get file access control lists setfacl - set file access control lists
set default remove
backup and restore
20. Firewall
sysctl - configure kernel parameters at runtime
net.ipv4.ip_forward
iptables - administration tools for packet filtering and NAT
refresh chains list chains chains admin INPUT Rule Chains OUTPUT Rule Chains Forward NAT IPV6
ulogd - The Netfilter Userspace Logging Daemon ufw - program for managing a netfilter firewall
DHCP Samba
Firewall GUI Tools Shorewall Tools
21. VPN
ip tunnel
ipv4
OpenVPN (openvpn - Virtual Private Network daemon)
Openvpn Server Openvpn Client OpenVPN GUI for Windows 源码安装
openswan - IPSEC utilities for Openswan strongswan - IPSec utilities for strongSwan ipsec-tools - IPsec tools for Linux
22. Stunnel - universal SSL tunnel 23. FreeRADIUS
ldap mysql WAP2 Enterprise
24. Kerberos
CentOS 安装 Install by apt-get 生成kerberos的本地数据库
IV. File Transfer
25. wget - retrieves files from the web 26. axel - A light download accelerator - Console version 27. ncftp
batch command ncftpget ncftpput
28. FileZilla 29. vsftpd - The Very Secure FTP Daemon 30. ProFTPD + MySQL / OpenLDAP 用户认证
Proftpd + MySQL Proftpd + OpenLDAP
31. Pure-FTPd + LDAP + MySQL + PGSQL + Virtual-Users + Quota 32. rsync - fast remote file copy program (like rcp)
install with source install with aptitude upload download mirror step by step to learn rsync rsync examples
backup to a central backup server with 7 day incremental backup to a spare disk mirroring vger CVS tree automated backup at home Fancy footwork with remote file lists
rsync for windows
33. tsync 34. Unison File Synchronizer
local remote config
35. csync2
server node test Advanced Configuration
V. Web Application
36. Lighttpd and fastcgi
quick install with aptitude to compile and then install lighttpd
shell script
Module
simple-vhost enable fastcgi ssl redirect rewrite alias.url auth compress module mod_expire
fastcgi
PHP Python Perl
37. LAMP
Install
Compile and then install Apache Quick install apache with aptitude XAMPP for Linux
Apache 调优
worker
Module
Alias / AliasMatch Redirect / RedirectMatch Rewrite deflate mod_expires Apache Log 跟踪用户的cookie
PHP 5 Mod Perl
38. Tomcat 安装与配置
install java install tomcat Connector mod_jk mod_proxy_ajp RewriteEngine 连接 Tomcat Testing file Script 1 Shell Script 2
39. Application Service
Zope JBoss - JBoss Enterprise Middleware
40. Web Server Optimization
ulimit php.ini
Resource Limits File Uploads Session Shared
APC Cache (php-apc - APC (Alternative PHP Cache) module for PHP 5) Zend Optimizer eaccelerator Memcached khttpd
41. Web Analysis
综合测试 awstats webalizer
42. Nginx
VI. Storage And Backup/Restore
43. Samba
install share test user smbfs Security consideration
44. Network Storage - Openfiler
Accounts Volumes
RAID iSCSI
Quota Shares
45. Amanda: Open Source Backup 46. inotify
inotify-tools Incron - cron-like daemon which handles filesystem events
47. Distributed Filesystem
DRBD (Distributed Replicated Block Device)
disk and partition Installation configure Starting Using
Coda
VII. Cluster
49. Linux Virtual Server
环境配置 VS/NAT VS/TUN VS/DR
配置文件
ipvsadm script debug ipvsadm monitor
50. keepalived
安装 test
51. heartbeat+ldirectord
VIII. Monitor and Assistant
52. System
Webmin logwatch nulog
53. Network
Cacti BIG BROTHER Nagios Bandwidth
54. Web
awstats webalizer
55. Zenoss 56. Ganglia
IX. Multimedia
57. ImageMagick
install convert
批量转换 resize
58. How to add metadata to digital pictures from the command line 59. broadcast streaming
gnump3d - A streaming server for MP3 and OGG files icecast2 - Ogg Vorbis and MP3 streaming media server
installation from source
shoutcast PeerCast
60. To convert multimedia format
To convert .rm files to .mp3 encode to Macromedia Flash format
X. Shell
61. Bash
prompt pipes (FIFOs) conditions if and case
if case
Loops for, while and until
for while until
Functions
Local variables
User interfaces 仅供参考
to convert utf-8 from gb2312 code 使用内存的百分比 查找文件并删除 xargs find and replace
XI. Instant messaging
62. IRC - Internet Relay Chat 63. jabber 64. Voice over IP
Gnu Gatekeeper
Gnu Gatekeeper Install Gnu Gatekeeper Configure Gnu Gatekeeper Test
Asterisk (OpenSource Linux PBX that supports both SIP and H.323) OpenSER SIP Server
65. exim4 - meta-package to ease Exim MTA (v4) installation
install configure FAQ
Mailing to remote domains not supported
66. Open Source Distributed Computing
Boinc (berkeley 分布式计算平台) ubuntu apt-get 安装
A. 案例
大型网站架设指南 基于LVS的集群邮件系统
B. 附录
CentOS / Redhat Notes
useful command mysql
参考文档
C. 历史记录
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值