domingo, 26 de enero de 2014

How to Install the Dynamic Update Client NO-IP on Linux



his guide will walk you through the installation and setup of the Linux Dynamic Update Client (DUC) on a computer running Linux.  If you are using Ubuntu or Debian linux please check our support site for guides on their specific setup.
If you are using Ubuntu Linux, please click here.
Installing the Client:
The below commands should be executed from a terminal window (command prompt) after logging in as the “root” user.  You can become the root user from the command line by entering “sudo su -” followed by the root password on your machine.
Note: If you do not have privileges on the machine you are on, you may add the “sudo” command in from of steps (5 and 6)
  1. cd /usr/local/src
  2. wget http://www.no-ip.com/client/linux/noip-duc-linux.tar.gz
  3. tar xvzf noip-duc-linux.tar.gz
  4. cd no-ip-2.1.9
  5. make
  6. make install
If you get “make not found” or “missing gcc” then you do not have the gcc compiler tools on your machine.  You will need to install these in order to procede.
To Configure the Client: 
As root again (or with sudo) issue the below command:
  • /usr/local/bin/noip2 -C   (dash capital C, this will create the default config file)
You will then be prompted for your username and password for No-IP, as well as which host names you with to update.  Be careful, one of the questions is “Do you wish to update all hosts”.  If answered incorrectly this could effect host names in your account that are pointing at other locations.
Now the client is installed and configured, you just need to launch it.  Simply issue this final command to launch the client in the background:
  • /usr/local/bin/noip2
Read the README file in the no-ip-2.1.9 folder for instructions on how to make the client run at startup.  This varies depending on what Linux distribution you are running.



Correr el script siempre que reiniciemos la maquina

nano /etc/rc.local

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

/usr/local/bin/noip2


exit 0



Tambien con un cronjob cada 5 minutos
crontab -e
*/5 * * * *  /usr/local/bin/noip2

No hay comentarios:

Publicar un comentario