sudo passwd
sudo nano /etc/netplan/00-installer-config.yaml
sudo apt install apache2
sudo ufw allow in "Apache Full"
sudo apt install mysql-server
sudo apt install php libapache2-mod-php php-mysql php-intl
sudo apt install phpmyadmin
sudo apt install php-cli
sudo systemctl restart apache2
sudo nano /var/www/html/info.php
------------agregar por lo siguiente -------
<?php
phpinfo();
?>
--------------------------------------------
su -
sudo mysql -u root -p
CREATE USER 'mateo'@'%' IDENTIFIED BY 'mateo';
GRANT ALL PRIVILEGES ON *.* TO 'mateo'@'%' WITH GRANT OPTION;
FLUSH PRIVILEGES;
EXIT;
********************************************
**************** MOODLE ********************
********************************************
cd /var/www/html
sudo wget -c https://download.moodle.org/download.php/direct/stable39/moodle-3.9.tgz
sudo apt install php-curl php-gd php-intl php-mbstring php-soap php-xml php-xmlrpc php-zip
sudo tar xzvf moodle-3.9.tgz
sudo chown -R www-data:www-data moodle/
sudo mkdir /var/www/moodledata
sudo chown www-data:www-data /var/www/moodledata
sudo mysql -u root -p
create database moodledb character set utf8mb4 collate utf8mb4_unicode_ci;
create user moodleusr@localhost identified by 'mateo';
grant all privileges on moodledb.* to moodleusr@localhost;
FLUSH PRIVILEGES;
exit;
systemctl restart apache2
http://192.168.207.144/moodle/my/
********************************************
************** WORDPRESS *******************
********************************************
sudo mysql -u root -p
CREATE DATABASE wordpressDB DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
create user wordpressusr@localhost identified by 'mateo';
grant all privileges on wordpressDB.* to wordpressusr@localhost;
FLUSH PRIVILEGES;
exit;
cd /var/www/html
curl -O https://wordpress.org/latest.tar.gz
tar xzvf latest.tar.gz
rm -r latest.tar.gz
touch /var/www/html/wordpress/.htaccess
chmod 660 /var/www/html/wordpress/.htaccess
cp /var/www/html/wordpress/wp-config-sample.php /var/www/html/wordpress/wp-config.php
mkdir /var/www/html/wordpress/wp-content/upgrade
sudo cp -a /var/www/html/wordpress/. /var/www/html/wp-content/upgrade
curl -s https://api.wordpress.org/secret-key/1.1/salt/
----------------(copiar la salida del comando API)--------------
nano /var/www/html/wordpress/wp-config.php
------cambiar el nombre de servidor x wordpressDB
------usuario x wordpressusr
------password x mateo
----------(pegar en vez de los otos API)--------------
systemctl restart apache2
http://192.168.207.144/wordpress/wp-admin/
********************************************
***************** JOOMLA *******************
********************************************
mysql -u root -p
CREATE DATABASE joomlaDB;
create user joomlausr@localhost identified by 'mateo';
GRANT ALL PRIVILEGES ON joomlaDB.* TO 'joomlausr'@'localhost';
FLUSH PRIVILEGES;
EXIT;
cd /var/www/html
sudo wget https://downloads.joomla.org/cms/joomla4/4-0-3/Joomla_4-0-3-Stable-Full_Package.zip
sudo apt install unzip
sudo unzip Joomla_4-0-3-Stable-Full_Package.zip -d /var/www/html/joomla
sudo chown -R www-data: /var/www/html/joomla
nano /etc/apache2/sites-available/joomla.conf
---------------------------------------------
<VirtualHost *:80>
ServerAdmin admin@tu_dominio.com
DocumentRoot /var/www/html/joomla/
ServerName tu_dominio.com
ServerAlias www.tu_dominio.com
<Directory /var/www/html/joomla/>
Options FollowSymlinks
AllowOverride All
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
---------------------------------------------
a2ensite joomla.conf
systemctl restart apache2
********************************************
***************** QUAGA ********************
********************************************
sudo apt-get install quagga
sudo apt install quagga-doc
sudo nano /etc/sysctl.conf
------- descomentar --------
net.ipv4.ip_forward=1
----------------------------
cp /usr/share/doc/quagga-core/examples/zebra.conf.sample /etc/quagga/zebra.conf
cp /usr/share/doc/quagga-core/examples/ripd.conf.sample /etc/quagga/ripd.conf
cp /usr/share/doc/quagga-core/examples/vtysh.conf.sample /etc/quagga/vtysh.conf
cp /usr/share/doc/quagga-core/examples/bgpd.conf.sample /etc/quagga/bgpd.conf
cp /usr/share/doc/quagga-core/examples/ospfd.conf.sample /etc/quagga/ospfd.conf
sudo chown quagga:quagga /etc/quagga/*.conf
sudo chown quagga:quaggavty /etc/quagga/vtysh.conf
sudo chmod 640 /etc/quagga/*.conf
mkdir /var/log/quagga/
chown quagga:quagga /var/log/quagga/
touch /var/log/zebra.log
chown quagga:quagga/var/log/zebra.log
touch /var/log/ripd.log
chown quagga:quagga /var/log/ripd.log
touch /var/log/ospfd.log
chown quagga:quagga /var/log/ospfd.log
sudo service zebra start
sudo service bgpd start
sudo service ripd start
sudo service ospfd start
sudo systemctl is-enabled zebra.service
sudo systemctl is-enabled bgpd.service
sudo systemctl is-enabled ripd.service
sudo systemctl is-enabled ospfd.service
sudo systemctl enable zebra.service
sudo systemctl enable bgpd.service
sudo systemctl enable ripd.service
sudo systemctl enable ospfd.service
##conectar a zebra
telnet localhost 2601
##conectar a rip
telnet localhost 2602
##conectar a ospf
telnet localhost 2604
##conectar a bgp
telnet localhost 2605
********************************************
******************* DNS ********************
********************************************
sudo apt-get install bind9
sudo nano /etc/bind/named.conf.local
zone "enruta.ec" {
type master;
file "/etc/bind/db.enruta.ec";
};
zone "0.0.20.in-addr.arpa" {
type master;
file "/etc/bind/db.20.0.0";
};
#para verificar que este bien la configuracion
named-checkconf
cp db.local db.enruta.ec
cp db.127 db.20.0.0
nano /etc/bind/db.enruta.ec
---------------------------------------------
;
; BIND data file for local loopback interface
;
$TTL 604800
@ IN SOA server.enruta.ec. root.enruta.ec. (
2 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS server.enruta.ec.
@ IN A 20.0.0.132
www IN A 20.0.0.132
server IN A 20.0.0.132
--------------------------------------------
named-checkzone enruta.ec /etc/bind/db.enruta.ec
nano /etc/bind/db.20.0.0
------------------------------------------
;
; BIND reverse data file for local loopback interface
;
$TTL 604800
@ IN SOA server.enruta.ec. root.enruta.ec. (
1 ; Serial
604800 ; Refresh
86400 ; Retry
2419200 ; Expire
604800 ) ; Negative Cache TTL
;
@ IN NS server.enruta.ec.
www IN A server.enruta.ec.
1 IN PTR server.enruta.ec.
-------------------------------------------
--1 IN PTR server.enruta.ec.--
#el "1" es el ultimo octecto de la ip
-------------------------------------------
named-checkzone 0.0.20.in-addr.arpa /etc/bind/db.20.0.0
nano named.conf.options
----------------------------------------
forwarders {
8.8.8.8;
};
----------------------------------------
sudo systemctl restart bind9
nano /etc/resolv.conf
-----poner ip del servidor
----- en vez de localhost poner enruta.ec
**********************adicionales *************************
dig -x server.enruta.ec
nslookup 20.0.0.132
No hay comentarios.:
Publicar un comentario