Categoría: Linux

  • Configurar Sendmail para el envio a Gmail

    1. Install prerequisites yum install sendmail mailutils sendmail-bin 2. Create Gmail Authentication file mkdir -m 700 /etc/mail/authinfo/ cd /etc/mail/authinfo/ nano gmail-auth AuthInfo: «U:root» «I:YOUR GMAIL EMAIL ADDRESS» «P:YOUR PASSWORD» Replace the above email with your gmail or google apps email. In the next step we will need to create a hash map for the above authentication file:…

  • Optimizar servidor apache con muchos time wait

    Para ver cuantas conexiones tenemos activas netstat -nat | awk ‘{print $6}’ | sort | uniq -c | sort -n Se imprime algo asi:       1 established)       1 Foreign       3 FIN_WAIT2       5 LAST_ACK       6 CLOSING       9 SYN_RECV      10 ESTABLISHED      22 FIN_WAIT1      26 LISTEN     466 TIME_WAIT Para mirar la configuracion actual: cat /proc/sys/net/ipv4/tcp_fin_timeout cat…

  • Como saber la ip publica desde la linea de comandos

    Se queremos saber cual es mi ip (externa). Ejecutamos los siguiente: wget -qO- ifconfig.me/ip wget -qO- http://ipecho.net/plain Otra forma curl ifconfig.me curl -s http://ipecho.net/plain Esto nos reemplaza el sitio cualesmiip Tambien podemos realizarlo se esta manera curl https://ipinfo.io/ip Recordar añadir la ruta al servidor, si este no tiene default gateway route add -host 216.239.32.21 gw…

  • Setup Samba Domain Controller with LDAP Backend in Ubuntu 13.04 | Unixmen

    Setup Samba Domain Controller with LDAP Backend in Ubuntu 13.04 | Unixmen Origen: Setup Samba Domain Controller with LDAP Backend in Ubuntu 13.04 | Unixmen   Otro enlace https://wiki.samba.org/index.php/Samba_AD_DC_HOWTO

  • Grabar SSH y toda la salida de la terminal

    Si queremos grabar lo que hacemos en el term y ver la salida de nuestros comandos, utilizaremos el comando script. Primero editamos /etc/bashrc y al final agregamos la siguiente linea test «$(ps -ocommand= -p $PPID | awk ‘{print $1}’)» == ‘script’ || (script -f /t mp/ssh-$(date +»%d-%b-%y_%H-%M-%S»)_shell.log) En la carpera /tmp veremos todo lo realizado. Con esto…

  • OwnCloud – Backup en la nube propia

    1- Instalar Servidor Ubuntu 16.04 2- Bajar los repositorios

  • Instalar Servidor LDAP

    Primero instalar el servidor Ubuntu Server Ejecutar los siguientes comandos sudo apt-get update sudo apt-get install slapd ldap-utils Crear clave para el administrador del LDAP Ediat la configuracion del OpenLDAP server. nano /etc/ldap/ldap.conf

  • AGREGAR UN DISCO DURO NUEVO EN LINUX

    Buscar la posicion del disco esto lo podemos ver con: fdisk -l Nos mostrara todos los discos. Para nuestro ejemplo usaremos: /dev/sdb fdisk /dev/sdb Command (m for help): n (añade nueva partición) Command action e extended p primary partition (1-4) p (tiene que ser partición primaria) Partition number (1-4): 1 First cylinder (1-5580, default 1):…

  • Instalacion Software de Citas

    Bajar el software (requiere php 5.5 o superior) wget https://github.com/alextselegidis/easyappointments/archive/master.zip mkdir /var/www/html/citastemp mv master.zip citastemp/ cd citastemp unzip master.zip cd easyappointments-master/ mv src /var/www/html/citas cd .. chmod 777 -R citas Crear la base de datos mysql -p create database citas; Cambiar la configuración de la base de datos y del servidor nano config.sample.php const DB_HOST…