วันอังคารที่ 8 ธันวาคม พ.ศ. 2552

Ubuntu handy configuration and command after installation + apache PHP

Ubuntu

configuration after setup.

startup interface/fix ip on startup
> /etc/network/interfaces.
iface eth1 inet static
address 192.168.0.2
netmask 255.255.255.0
gateway 192.168.0.1

set name server
> /etc/resolv.conf
nameserver 204.11.126.131


install ssh for remote login
> openssh
sudo apt-get install openssh-client openssh-server


>adduser
sudo adduser username


>user / add/ super user (group admin) sodoer
sudo adduser xeon
sudo adduser xeon admin


>php5 + mysql
sudo apt-get install
  • php5
  • php5-cgi
  • php5-cli
  • php5-mysql
  • php5-memcache
  • php5-gd
  • php5-imagick

>apache
sudo apt-get install apache2-mpm-worker


>remove service from startup
update-rc.d -f apache2 remove

>add service
update-rc.d apache2 defaults

>more reading on services
http://www.debuntu.org/how-to-manage-services-with-update-rc.d


>NFS server
sudo apt-get install nfs-kernel-server
sudo /etc/init.d/nfs-kernel-server start

>NFS client
sudo apt-get install nfs-common
For more info about nfs : https://help.ubuntu.com/community/SettingUpNFSHowTo


>/etc/exports
/ubuntu *(ro,sync,no_root_squash)
/home *(rw,sync,no_root_squash)

>package management-install
#apt-get install packagename
-see update current version

# apt-cache policy apache2
apache2:
Installed: 2.2.8-1ubuntu0.3
Candidate: 2.2.8-1ubuntu0.14
Version table:
2.2.8-1ubuntu0.14 0
500 http://th.archive.ubuntu.com hardy-updates/main Packages
500 http://security.ubuntu.com hardy-security/main Packages
*** 2.2.8-1ubuntu0.3 0
100 /var/lib/dpkg/status
2.2.8-1 0
500 http://th.archive.ubuntu.com hardy/main Packages

Remark
*apache worker mpm not work with libapach2-php
using fcgid mod and php cgi

*NFS add host to /etc/hosts.allow
*snmpd change init opt /etc/default/snmpd
*all rp_filter need to be disable

ไม่มีความคิดเห็น:

แสดงความคิดเห็น