【转】CentOS系统操作下安装相关各种软件

时间:2023-03-10 05:04:11
【转】CentOS系统操作下安装相关各种软件

CentOS系统是非常强大经常应用的系统,我就对CentOS系统深入探讨学习,对大家概括讲述CentOS系统应用,希望对大家有用。虽然CentOS Linux使用了RHEL的源代码,但是由于这些源代码是Red Hat公司*发布的,因此CentOS Linux的发布是完全合法的,CentOS Linux的使用者也不会遇到任何的版权问题。CentOS面向那些需要企业级操作系统稳定性的人们,而且并不存在认证和支持方面的开销。

  • CentOS系统安装mysql

[root@mail build]#yum install mysql-server
     [root@mail build]#yum install mysql-devel

  • CentOS系统安装apache

   [root@mail build]#yum install httpd

  • CentOS系统安装php

     [root@mail build]#yum install php
     [root@mail build]#yum install php-mysql
     [root@mail build]#yum install php-gd
     [root@mail build]#yum install php-imap
     [root@mail build]#yum install vsftpd
     [root@mail build]#yum install clamav
     [root@mail build]#yum install spamassassin
     [root@mail build]#/usr/bin/freshclam

  • CentOS系统设置apache

  默认:User apache改为User postfix
     默认Group apache改为Group postfix
     默认AddDefaultCharset UTF-8改为AddDefaultCharset gb2312
     新加入:AddType application/x-httpd-php .phpAddType application/x-httpd-php-source .phps

  • CentOS系统安装phpMyAdmin

     [root@mail build]#tar –zxf ../src/phpMyAdmin-2.8.0.1.tar.gz
     [root@mail build]#mv phpMyAdmin-2.8.0.1 /var/www/html/dbadmin/
     [root@mail build]#cp /var/www/html/dbadmin/libraries/config.default.php /var/www/html/dbadmin/dbadmin/libraries/config.inc.php (line 1.)

  • CentOS系统设置数据库[root@mail build]#mysql

  Mysql> create datases postfix;
     Mysql> use mysql;
     Mysql> INSERT INTO user (host,user,password) VALUES('localhost','postfix','');
     Mysql> update user set password=password('postfix') where User='postfix';
     Mysql> GRANT ALL ON postfix.* TO postfix@localhost IDENTIFIED BY "postfix";
     Mysql> exit
     [root@mail build] tar –zxf ../src/webmail.tar.gz
     [root@mail build] mysql –u root –p postfix < Tmail.sql

  • 增加postfix的用户和组

     [root@mail build] groupadd -g 12345 postfix
     [root@mail build] useradd -u 12345 -g 12345 -c postfix -d/dev/null -s/sbin/nologin postfix
     [root@mail build] groupadd -g 54321 postdrop

以上介绍CentOS系统安装相关系统。