LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 02-25-2016, 04:14 AM   #1
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Rep: Reputation: Disabled
Staring noip2 with boot


I have Slackware 14.1 64bit with multilib. I installed noip2 from SlackBuilds Repository. During a boot OS rc.local does not start noip2. /etc/rc.d/rc.local is set correctly with:

Code:
if [ -x /etc/rc.d/rc.noip2 ]; then
 . /etc/rc.d/rc.noip2 start
fi
Scripts in rc.local before this work properly, but after this script not work at all.

When I run /etc/rc.d/rc.local, after entering in KDE, noip2 working properly like all scripts in rc.local.
 
Old 02-25-2016, 04:43 AM   #2
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,097

Rep: Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174
Quote:
Originally Posted by fabula View Post
Code:
if [ -x /etc/rc.d/rc.noip2 ]; then
 . /etc/rc.d/rc.noip2 start
fi
if you add a "." before the script it means you source it and this way the start argument is never passed to the script.

you should be ok just removing that, like
Code:
if [ -x /etc/rc.d/rc.noip2 ]; then
  /etc/rc.d/rc.noip2 start
fi
 
Old 02-25-2016, 06:01 AM   #3
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
if you add a "." before the script it means you source it and this way the start argument is never passed to the script.

you should be ok just removing that, like
Code:
if [ -x /etc/rc.d/rc.noip2 ]; then
  /etc/rc.d/rc.noip2 start
fi
Thanks for the quick answer. First, I must say that I appreciate very much your work.
Now, rc.local start scripts before and after this code:
Code:
/etc/rc.d/rc.noip2 start
But in KDE:

user:
Code:
bash-4.2$ /etc/rc.d/rc.noip2 status
no-ip client daemon is not runnig
root:
Code:
bash-4.2$ /etc/rc.d/rc.noip2 status
no-ip client daemon is not runnig
 
Old 02-25-2016, 06:06 AM   #4
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,097

Rep: Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174
"status" doesn't seem to work (report the thing to the maintainer): to check if it's running do it with
Code:
ps aux | grep noip
 
Old 02-25-2016, 06:11 AM   #5
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
"status" doesn't seem to work (report the thing to the maintainer): to check if it's running do it with
Code:
ps aux | grep noip
Code:
bash-4.2$ ps aux | grep noip
1000      1449  0.0  0.0   7116   976 pts/1    S+   12:08   0:00 grep noip
 
Old 02-25-2016, 06:19 AM   #6
slacker1337
Member
 
Registered: Jun 2012
Location: Connecticut, USA
Distribution: Slackware
Posts: 148

Rep: Reputation: 40
Just to cover all the bases, are both /etc/rc.d/rc.local and /etc/rc.d/rc.noip2 set as executable?
 
Old 02-25-2016, 06:20 AM   #7
ponce
LQ Guru
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 7,097

Rep: Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174Reputation: 4174
it can be it errors something when launched: as the start script just execute it with its config file as an argument, I suppose you can also launch it manually from a root terminal
Code:
/usr/bin/noip2 -c /etc/no-ip2.conf
and see which error it spits.
check also the other command line options
Code:
$ noip2 --help
noip2: invalid option -- '-'

USAGE: noip2 [ -C [ -F][ -Y][ -U #min]
        [ -u username][ -p password][ -x progname]]
        [ -c file][ -d][ -D pid][ -i addr][ -S][ -M][ -h]

Version Linux-2.1.9
Options: -C               create configuration data
         -F               force NAT off
         -Y               select all hosts/groups
         -U minutes       set update interval
         -u username      use supplied username
         -p password      use supplied password
         -x executable    use supplied executable
         -c config_file   use alternate data path
         -d               increase debug verbosity
         -D processID     toggle debug flag for PID
         -i IPaddress     use supplied address
         -I interface     use supplied interface
         -S               show configuration data
         -M               permit multiple instances
         -K processID     terminate instance PID
         -z               activate shm dump code
         -h               help (this text)
you can also open two other terminals executing the following commands when you execute it like above and see eventual output in /var/log/messages and /var/log/syslog flowing
Code:
tail -f /var/log/messages
tail -f /var/log/syslog

Last edited by ponce; 02-25-2016 at 06:24 AM.
 
Old 02-25-2016, 06:23 AM   #8
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by slacker1337 View Post
Just to cover all the bases, are both /etc/rc.d/rc.local and /etc/rc.d/rc.noip2 set as executable?
yes
 
Old 02-25-2016, 06:27 AM   #9
slacker1337
Member
 
Registered: Jun 2012
Location: Connecticut, USA
Distribution: Slackware
Posts: 148

Rep: Reputation: 40
I also recall (it's been a while), that I had to run the noip2 setup before I could get the service to start correctly. Essentially, your service could be attempting to start but, because it hasn't been configured with your noip username/password, it's failing.
 
Old 02-25-2016, 06:54 AM   #10
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by slacker1337 View Post
I also recall (it's been a while), that I had to run the noip2 setup before I could get the service to start correctly. Essentially, your service could be attempting to start but, because it hasn't been configured with your noip username/password, it's failing.
no-ip.conf is created. This is ok. When I execute /etc/rc.d/rc.noip2 start from KDE IP adress is renewed...
 
Old 02-25-2016, 07:08 AM   #11
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by ponce View Post
it can be it errors something when launched: as the start script just execute it with its config file as an argument, I suppose you can also launch it manually from a root terminal
Code:
/usr/bin/noip2 -c /etc/no-ip2.conf
and see which error it spits.
check also the other command line options
[code]$ noip2 --help
noip2: invalid option -- '-'

.......

you can also open two other terminals executing the following commands when you execute it like above and see eventual output in /var/log/messages and /var/log/syslog flowing
Code:
tail -f /var/log/messages
tail -f /var/log/syslog

Code:
/usr/bin/noip2 -c /etc/no-ip2.conf
Code:
tail -f /var/log/messages
noip2[1362]: v2.1.9 daemon started with NAT enabled

an my ip is renewed....

But on boot nothing happened...
 
Old 02-25-2016, 07:15 AM   #12
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
How do you connect to your internet? If it is wireless with wicd/NetworkManager, it could be that you're not connected to the internet when the script originally runs, since (I believe) you usually don't connect until the GUIs come up. From other posts on the forum, it sounds like Network Manager will allow you to run scripts after it connects to the network, so you could have it run noip2 that way.
 
1 members found this post helpful.
Old 02-25-2016, 07:29 AM   #13
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bassmadrigal View Post
How do you connect to your internet? If it is wireless with wicd/NetworkManager, it could be that you're not connected to the internet when the script originally runs, since (I believe) you usually don't connect until the GUIs come up. From other posts on the forum, it sounds like Network Manager will allow you to run scripts after it connects to the network, so you could have it run noip2 that way.
My connection is cable/NetworkManager. How can I run script after it connects to the network.
 
Old 02-25-2016, 07:55 AM   #14
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
That I don't know. I've never used Network Manager. I'd imagine it'd be in Network Manager's settings, but you might need to enable a passwordless sudo for it to work properly (since I imagine noip2 requires root to start).
 
Old 02-25-2016, 08:45 AM   #15
fabula
Member
 
Registered: Dec 2011
Location: Croatia
Distribution: Slackware, Salix
Posts: 30

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by bassmadrigal View Post
That I don't know. I've never used Network Manager. I'd imagine it'd be in Network Manager's settings, but you might need to enable a passwordless sudo for it to work properly (since I imagine noip2 requires root to start).
I think that Network Manager is not problem. When I restarted my system to Default runlevel (id:3:initdefault, DHCP gave me IP address, but noip2 did not update the DNS.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to install noip2 client on WD MyBook Live Cubytus32 Linux - Newbie 2 12-15-2013 12:43 PM
Staring up WLAN process at Boot andy g Linux - General 1 06-24-2007 11:40 AM
noip2 & IP address BerlinBadger Linux - Networking 1 12-02-2005 12:40 PM
Start noip2 process at boot up kt8993 Mandriva 1 05-06-2005 10:47 PM
Mandrake 9.2, Boot process stops at Staring ALSA Version 0.9.6 stever Mandriva 2 02-02-2004 11:47 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 11:53 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration