How to disable SELINUX ?
vi /etc/selinux/config
SELINUX=disabled
How to turn off the firewall?
chkconfig --level 2345 iptables off
chkconfig --level 2345 ip6tables off
reboot
Cannot browse the Windows Network?
The following commands will allow you to mount a windows share.
yum install samba samba-client samba-common samba-swat
mkdir /mnt/ex2
mount -t cifs //ex2/ii /mnt/ex2 -o user=administrator
chkconfig --level 345 mysqld on
service mysqld start
mysql
create database kaimingTest;
GRANT ALL PRIVILEGES ON "." TO 'root'@'localhost';
Download Drupal package and extract it to a directory, e.g. /var/www/html
vi httpd.conf
DocumentRoot /var/www/html
cp /var/www/html/sites/default/default.settings.php /var/www/html/sites/default/settings.php
chkconfig --level 345 httpd on
service httpd start
set permissions
chown -R apache:apache /var/www/html/sites/default
chmod -R a+rwx /var/www/html/sites/default
The dom extension is part of php-xml package. Download php-xml and install it.
yum install php-xml
yum -y install php-gd
Step 1:
download the backup package, e.g. backup-8.17.2011_16-04-43_vanarts.tar.gz
Extract the package
Extract the homedir.tar package
Move the public_html directory to /var/www
chown -R apache:apache /var/www/public_html/sites/default
chmod -R a+rwx /var/www/public_html/sites/default
Step 2:
From existing vanarts web server:
mysqldump -uroot –p password --all-databases > data.sql
Step 3:
From the new Fedora computer:
scp root@166.199.140.191:/root/data.sql .
mysql
create database mydatabase
mysql mydatabase< data.sql
mysql
drop user 'vanarts'@'localhost';
create user 'vanarts'@'localhost' IDENTIFIED BY 'password';
grant all privileges on *.* to 'vanarts'@'localhost';
UPDATE mysql.user SET Password=PASSWORD('MyNewPass') WHERE User='root'; FLUSH PRIVILEGES;
Step 4:
vi /etc/httpd/conf/httpd.conf
DocumentRoot /var/www/public_html
service httpd restart
http://localhost/
The main page shows.However, when you click on the menu or links, NOT FOUND.
Step 5: solution
vi /etc/httpd/conf/httpd.conf
<Directory /var/www/public_html>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
</Directory>
All menu and links work!!!!!
SSL certificate binding to new server
from httpd.conf, find out the existing SSL configuration
scp vanarts.com.crt .
scp vanarts.com.key .
scp vanarts.com.cabundle .
cp vanarts.key /etc/pki/tls/private
cp vanarts.crt /etc/pki/tls/certs
cp gd_bundle /etc/pki/tls/certs
vi /etc/httpd/conf.d/ssl.conf
SSLCertificateKeyFile /etc/pki/tls/private/vanarts.key
SSLCertificateFile /etc/pki/tls/certs/vanarts.crt
SSLCertificateChainFile /etc/pki/tls/certs/gd_bundle.crt
/sbin/service httpd restart