Solaris

우분투 apm설치 완벽본

알 수 없는 사용자 2008. 2. 28.
728x90

1. WOL TEST


2. 기본 툴 설치

 - zlib설치
    1) ftp://ftp.superuser.co.kr/etc/zlib-1...
    2) ./confiugre
    3 )make
    4) make install

 - libpng 설치
    1) ftp://ftp.superuser.co.kr/etc/libpng-1...
    2) cd 압축푼 디렉토리
    3) cp scripts/makefile.linux makefile
    4) make test
    5 )make install
   
  - freetype 설치
    1) ftp://ftp.superuser.co.kr/etc/freetype....
    2) cd 압축푼 디렉토리
    3) ./configure
    4) make
    5) make install

  - jpeg 설치
    1) ftp://ftp.superuser.co.kr/etc/jpegsrc.v6b..
    2) cd 압축푼 디렉토리
    3) ./configure --enable-shared --enable-static
    4) make
    5) mkdir /usr/local/man/man1
    6) make install

  - gd 설치
    1) ftp://ftp.superuser.co.kr/etc/gd....
    2) cd 압축푼 디렉토리
    3) ./configure
    4) make
    5) make install

  - libxml2 설치
    1) ftp://ftp.superuser.co.kr/etc/libxml2-...
    2) cd 압축푼 디렉토리
    3) ./configure
    4) make
    5) make install


3. MYSQL 설치
 
 1) wget ftp://ftp.superuser.co.kr/mysql/mysql....
 2) 압축 풀고 해당 디렉토리로 이동
 3) ./configure --prefiex=/usr/local/mysql --localstatedir=/usr/local/mysql/data --with-charset=euckr --enable-thread-safe-client
 4) make
 5) make install
 6) cd /usr/local/mysql/bin
 7) ./mysql_install_db   (/usr/local/mysql/data 과 생성되었는지 확인)
 8) useradd -M mysql
 9) chown -R mysql:mysql /usr/local/mysql/data
 10) /usr/local/mysql/bin/mysqld_safe &  (실행)
 11) cd /usr/local/mysql/bin
 12) ./mysqladmin -u root password 원하는비번
 13) ./mysql -u root -p mysql
 


 4. 아파치 설치

 1) wget ftp://ftp.superuser.co.kr/apache/httpd...
 2) 압축풀고 해당 디렉토리로 이동
 3) vi server/mpm/prefork/prefork.c
 4) DEFAULT_SERVER_LIMIT 1280
 5) vi server/mpm/worker/worker.c
 6) DEFAULT_SERVER_LIMIT 20
 7) ./configure --prefix=/usr/local/apache2 --enable-so --with-rpm=worker
 8) make
 9) make install
 10) vi /usr/local/apache2/conf/httpd.conf
      - DocumentRoot "/var/www/html"
      - Userdir www
      - <Directory /home/*/public_html> 주석해제 public_html -> www
      - DirectoryIndex index.html index.htm index.php index.php3 index.cgi
      - AddType application/x-httpd-php .php .phtml
      - AddType application/x-httpd-php-source .phps
 11) /usr/local/apache2/bin/apachectl start
 
 

 5. PHP 설치

 1) wget ftp://ftp.superuser.co.kr/php/php-...
 2) 압축풀고 해당 디렉토리로 이동
 3) ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql=/usr/local/mysql --with-freetype-dir --with-zlib-dir --with-jpeg-dir --with-gd --disable-debug
 4) make
 5) make install
 6) 컴파일이 끝난 디렉토리에 php.ini-dist 파일을 cp php.ini-dist /usr/local/lib/php.ini


6. PHP ZendOptimizer 설치

 1) wget ftp://ftp.superuser.co.kr/ZendOptimizer/Zend...
 2) 압축 풀고 해당 디렉토리로 이동
 3) ./install.sh
 4) OK -> EXIT -> Yes -> (/usr/local/Zend) OK -> (/usr/local/lib) OK -> Yes -> (/usr/local/apache2/bin)OK -> OK -> YES
 
 
 6. PHP 동작 확인 테스트
 <?
 phpinfo();
 ?>
 
 
 
 7. 부팅시 APM 자동 실행 설정

1) vi /etc/rc.d/rc.local
   - touch /var/lock/subsys/local (default)
   - /usr/local/mysql/bin/mysqld_safe & (add)
   - /usr/local/apache2/bin/apachectl start (add)
 
 
 
 8. 웹ssh설정
 
  1) vi /etc/ssh/sshd_config
      - Allowusers root 아이디1 아이디2


 9. vsftp설정
 
 1) vi /etc/vsftpd/vi vsftpd.conf
    - anonymous_enable=NO
    - local_enable=YES
    - ftp_banner=Welcome to ~~~
    - chroot_list_enable=YES
    - chroot_local_user=YES
 2) vi /etc/vsftpd/chroot_list 생성
       root
       setf
       아이디
       아이디2

 3) 쉘 권한이 없는 사용자에게 ftp사용권한
     - vi /etc/pam.d/vsftpd
         -- #auth       required     pam_shells.so (주석처리)      
      
 
 
10. 크론 설정

 1) crontab -e
 2) 5 * * * * touch /root/pgh_pgh12345


11. 시작 메세지 설정
     /etc/issue.net
     /etc/motd


12. 삼바 설정
 1) /etc/rc.d/init.d/smb stop
 2) vi /etc/samba/smb.conf
     - security = user
     - [아이디]
         comment = 어쩌고저쩌고
         path = /home/아이디
         valid users = 아이디
         writeable = yes
         browseable = yes
         printable = no
         create mask = 0750
         
  3) smbpasswd -a 아이디
 


13. 보안설정

--------------------not sure ---------------
su  유저에 관하여
chmod 4750 /bin/su
/etc/group내의 wheel그룹에 관리자계정 등록
(예 : wheel:x:10:root,papa)
chown root:wheel /bin/su
chattr +i /bin/su

원위치
chattr -i /bin/su
chmod 4755 /bin/su
passwd
----------------------------------------------

명령어 제한
chmod 750 /usr/sbin/useradd
chmod 750 /usr/bin/top
chmod 750 /sbin/fdisk
chmod 750 /sbin/mkfs
chmod 750 /sbin/fsck

chown root:wheel /usr/sbin/useradd
chown root:wheel /usr/bin/top
chown root:wheel /sbin/fdisk
chown root:wheel /sbin/mkfs
chown root:wheel /sbin/fsck

chattr +i /usr/sbin/useradd
chattr +i /usr/bin/top
chattr +i /sbin/fdisk
chattr +i /sbin/mkfs
chattr +i /sbin/fsck



14. quota 설정

 1) vi /etc/fstab
 2) LABEL=/home /home ext3 defaults,quotauser 1 2
 3) touch /home/quota.user
 4) chmod 600 /home/quota.user
 5) mount -o remount /home
 6) cd /home
 7) touch quota.user
 8) chmod 600 quota.user
 9) quotacheck -a -m
 10) truncate. Can's save ....
 11) quotacheck -a -m
 12) convertquota -u /home
 13) edquota -u 아이디
 14) soft, hard(단위 kilobyte)
 15) 명령어
       - edquota -u 아이디
       - repquota -a 현재사용현
       - user02 사용자의 설정을 user01과 같게 하는 명령어로
       - edquota -p  user01 user02


15. 위키설치

16. webssh

17. gallery


 마운트
 mount -t ext3 /dev/hdc /win

aptitude update
aptitude dist-upgrade




useradd abc -g linux
를 하게되면 abc 라는 아이디는 linux 그룹에 속하게 생성이 됩니다.


그룹변경
usermod -g 새그룹이름 사용자ID


소유자|소유그룹 변경
                (소유자:소유그룹)
chown -R neopgh:neopgh test_dir/

728x90

댓글