01-22-2014, 09:35 AM
Here is a file i created over the years, and i have used many times in the recent past to install the entire Centos to a machine (or VM). I used Centos Windows to make things Easier to start and running the servers..
Guide Installing Centos and server
1st. Install CentOS Must be i386 version and not 64, install as DESKTOP,
2
CentOS-6.5-i386-bin-DVD1.iso <-- is 32 bit with Kernal
do a update,
yum update
then do the following exactly
install mono before anything else if it messes up u will have to reinstall CentOs
--INSTALLING MONO
Installing Dependencies¶
All of the required dependencies are available via the Yum package manager.
First: youll have to add the epel rpm:
wget 2
rpm -Uvh epel-release-6-8.noarch.rpm
After the epel repo has been added, the following can be executed:
yum install bison gettext glib2 freetype fontconfig libpng libpng-devel libX11 libX11-devel glib2-devel libgdi* libexif glibc-devel urw-fonts java unzip gcc gcc-c++ automake autoconf libtool make bzip2 wget
Downloading and Compiling
In some cases, you may want to use a prefix of /opt/mono - this will require you to either add this directory to your PATH environment variable, or explicitly specify the full path to Mono when you want to run it.
Then run the following as root:
cd /usr/local/src
wget 2
make && make install
Instead of ./configure --prefix=/opt/mono (as discussed above). If you get an "Out of memory" error while running make on memory-limited systems, try running the following to allow higher virtual memory usage:
ulimit -v unlimited
mono CashServer.exe
MySQL Installation:
yum install mysql mysql-server
Then we create the system startup links for MySQL (so that MySQL starts automatically whenever the system boots) and start the MySQL server:
chkconfig --levels 235 mysqld on
/etc/init.d/mysqld start
Set passwords for the MySQL root account:
mysql_secure_installation
~[root@server1 ~]# mysql_secure_installation ~
When It Asks To Set MySQL Pass [y/N] choose N
_________________________________________________________________________________________________
Installing Apache2
yum install httpd
Now configure your system to start Apache at boot time...
chkconfig --levels 235 httpd on
... and start Apache:
Installing PHP5
We can install PHP5 and the Apache PHP5 module as follows:
yum install php
We must restart Apache afterwards:
/etc/init.d/httpd restart
_________________________________________________________________
Testing PHP5 / Getting Details About Your PHP5 Installation
The document root of the default web site is /var/www/html. We will now create a small PHP file (info.php) in that directory and call it in a browser. The file will display lots of useful details about our PHP installation, such as the installed PHP version.
vi /var/www/html/info.php
shift i -- to insert
<?php
phpinfo();
?>
esc
shift :x -- saves it all
_________________________________________________________________________________________________
Getting MySQL Support In PHP5
To get MySQL support in PHP, we can install the php-mysql package. Its a good idea to install some other PHP5 modules as well as you might need them for your applications. You can search for available PHP5 modules like this:
yum search php
APC can be installed as follows:
yum install php-pecl-apc
Now restart Apache2:
/etc/init.d/httpd restart
__________________________________________________________________________________________________
Installing phpMyAdmin
First we enable the RPMforge repository on our CentOS system as phpMyAdmin is not available in the official CentOS 6.3 repositories:
Import the RPMforge GPG key:
rpm --import 2
On i386 systems:
yum install 2
easyer to just download to a flash drive, but i have added them to this package, after downloading double click and install
then phpMyAdmin can now be installed as follows:
yum install phpmyadmin
vi /etc/httpd/conf.d/phpmyadmin.conf
Now we configure phpMyAdmin. We change the Apache configuration so that phpMyAdmin allows connections not just from localhost (by commenting out all. add # to everything in between
press shift I then edit file.
<Directory "/usr/share/phpmyadmin">
# <leave all this alone>
# <leave all this alone>
# <leave all this alone>
</Directory>
press ESC so you get back to command mode, then do.
press-> :x (quit and save)
or
-> :w and
-> :q or
-> :wq
Next we change the authentication in phpMyAdmin from cookie to http:
vim /usr/share/phpmyadmin/config.inc.php
you see something like this add in the HTTP like below:
/* Authentication type */
$cfg[servers][$i][auth_type] = http;
First press ESC so you get back to command mode, then do.
:x (quit and save)
or
:w and
:q or
:wq
Restart Apache:
/etc/init.d/httpd restart
Afterwards, you can access phpMyAdmin under 2 ip/phpmyadmin/ or 2
if you still cant connect ...turn your firewall off untill you understand it better.
To get Ip Adress
ifconfig
to connect Navicat to phpmyadmin goto phpmyadmin 2 , then click on Privileges and add a user with full access ..goto navicat on your windows pc and all the connection with the login and password you made...connect on your pc get on naivcat and install the DB...
create 3 tables
newproject_data
newproject_db
newproject_db_auth
before starting the server go into your fold of the server and right click each file or all of them and make sure they all have full access
start the server on the centos side it will reply back you are still missing a few files like
libmysqlclient.so.12 -- fix run MySQL-shared-compat-5.1.49-1.rhel5.i386.rpm
libssl.so.6 -- fix run openssl098e-0.9.8e-17.SEL6.i686.rpm
these packages are add to this folder ...
Openssl098e-xxxxxxxxxx.rpm
rpmforge-release-xxxxxxxx.rpm
and a few others ...after you should be able to start the server .....with OUT CASHSERVER ,but first do SSL install before u do MONO to install the cash server.
OpenSSH Installations under CentOS Linux
To install the server type:
yum -y install openssh-server
Start the service:
chkconfig sshd on
service sshd start
Make sure port 22 is opened:
netstat -tulpn | grep :22
Firewall Settings
Edit /etc/sysconfig/iptables (IPv4 firewall),
vi /etc/sysconfig/iptables
Add the line
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT
Save and close the file. Restart iptables:
service iptables restart
Download WinSCP for windows to connect to the Linux ssh server
Open WinSCP to be greeted with a login window, so click the NEW button (on the left find Connection -> Tunnel (click the Tunnel) then tick the box to connect through SSH tunnel an fill in the info.
Host = vbox lan ip
User = root
Pass = root password (reverse) if the pre-installed "snapshot" you can download.
Save!
Connect!
Hope this helps others and make things Easier ... As you can tell above i install Mono first before anything ...Since it can ***** up so easy this will assure you will get Cash server up and running 100% ....
Thanks CDWriter


