LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 10-15-2012, 11:32 PM   #1
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Rep: Reputation: 4
IPv6 start up scripts


I was wondering if there are any IPv6 startup scripts readily available for Slackware 14. I am looking for something similar to /etc/rc.d/rc.inet1 -- and hoping that eventually it will become part of the standard Slackware.
 
Old 10-16-2012, 03:14 AM   #2
wildwizard
Member
 
Registered: Apr 2009
Location: Oz
Distribution: slackware64-14.0
Posts: 875

Rep: Reputation: 282Reputation: 282Reputation: 282
Quote:
Originally Posted by drlukacs View Post
I was wondering if there are any IPv6 startup scripts readily available for Slackware 14. I am looking for something similar to /etc/rc.d/rc.inet1 -- and hoping that eventually it will become part of the standard Slackware.
As far as a client PC is concerned there is no need for anything, IPv6 has been designed from the ground up to have automatic configuration.

If you plug a Slackware 14.0 or even 13.37 (possibly several older versions as well) into an network that has been setup for IPv6 the Slackware machine will get an IPv6 address and use it without the user doing a thing.
 
Old 10-16-2012, 03:22 AM   #3
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Original Poster
Rep: Reputation: 4
Quote:
Originally Posted by wildwizard View Post
As far as a client PC is concerned there is no need for anything, IPv6 has been designed from the ground up to have automatic configuration.
Stateless auto-configuration works perfectly for clients.

But what about servers, which have to have a fixed IP number (e.g., nameserver, mail server, web server, etc.)?
 
Old 10-16-2012, 03:38 AM   #4
Thom1b
Member
 
Registered: Mar 2010
Location: France
Distribution: Slackware
Posts: 484

Rep: Reputation: 336Reputation: 336Reputation: 336Reputation: 336
Quote:
Originally Posted by drlukacs View Post
But what about servers, which have to have a fixed IP number (e.g., nameserver, mail server, web server, etc.)?
I agree with you, it could be nice to have the possibility to set manually ipv6. But auto-configuration set an ip using mac address. If you don't change it, your auto ipv6 will never change.
 
Old 10-16-2012, 03:54 AM   #5
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Original Poster
Rep: Reputation: 4
Quote:
Originally Posted by Thom1b View Post
I agree with you, it could be nice to have the possibility to set manually ipv6. But auto-configuration set an ip using mac address. If you don't change it, your auto ipv6 will never change.
Yup. So, I am looking for Slackware-style init scripts to do the trick.

So far, I found only this, but it is only for connecting to a tunnel broker, and not really for configuring existing interfaces with one (or more!) IPv6 addresses.
 
Old 10-16-2012, 05:38 AM   #6
FeyFre
Member
 
Registered: Jun 2010
Location: Ukraine, Vinnitsa
Distribution: Slackware
Posts: 351

Rep: Reputation: 30
drlukacs, there is no such init script in Slackware. I did tried to rise this question almost year ago, but without results. Then I decided it is better to create it myself and share with community later.
 
Old 10-16-2012, 05:59 AM   #7
wildwizard
Member
 
Registered: Apr 2009
Location: Oz
Distribution: slackware64-14.0
Posts: 875

Rep: Reputation: 282Reputation: 282Reputation: 282
Quote:
Originally Posted by drlukacs View Post
But what about servers, which have to have a fixed IP number (e.g., nameserver, mail server, web server, etc.)?
The IP is static if the hardware stays the same and the network it is connected to stays the same.

If you change the hardware it's not too hard to update the DNS records to match.

If you change the network then your static IP is just as useless as the stateless autoconfig one.
 
Old 10-16-2012, 06:03 AM   #8
jtsn
Member
 
Registered: Sep 2011
Posts: 922

Rep: Reputation: 480Reputation: 480Reputation: 480Reputation: 480Reputation: 480
Quote:
Originally Posted by drlukacs View Post
I was wondering if there are any IPv6 startup scripts readily available for Slackware 14. I am looking for something similar to /etc/rc.d/rc.inet1 -- and hoping that eventually it will become part of the standard Slackware.
Currently you have the following options:

1. Use NetworkManager (included in Slackware 14) to statically configure IPv6
2. Install Quagga and use the zebra daemon for IPv6 configuration
3. Deploy your own scripts (using /sbin/ip).

For option 3 I would recommend to create a rc.ipv6 script and insert a call to it into rc.inet1, so it works like rc.wireless.
 
Old 10-16-2012, 10:35 AM   #9
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Original Poster
Rep: Reputation: 4
Quote:
Originally Posted by FeyFre View Post
I did tried to rise this question almost year ago, but without results. Then I decided it is better to create it myself and share with community later.
Would you consider sharing the script that you created?
 
Old 10-16-2012, 11:00 AM   #10
FeyFre
Member
 
Registered: Jun 2010
Location: Ukraine, Vinnitsa
Distribution: Slackware
Posts: 351

Rep: Reputation: 30
drlukacs, (un)fortunately IPv6 wasn't required for my work, so I did not created any suitable solution. Sorry if I gave You false hope.
 
Old 10-16-2012, 11:41 AM   #11
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Original Poster
Rep: Reputation: 4
Quote:
Originally Posted by jtsn View Post
Currently you have the following options: [...]
3. Deploy your own scripts (using /sbin/ip).

For option 3 I would recommend to create a rc.ipv6 script and insert a call to it into rc.inet1, so it works like rc.wireless.
I like option 3. I have a couple of questions about your suggestion to make it work like rc.wireless:

-- Where would it make the most sense to insert such a call?
-- How would such an approach deal with adding tunnels and/or various routing policies?
-- What behaviour would you expect in terms of dhcpcd? (Does the latest version of dhcpcd support IPv6?)
 
Old 10-16-2012, 12:48 PM   #12
jtsn
Member
 
Registered: Sep 2011
Posts: 922

Rep: Reputation: 480Reputation: 480Reputation: 480Reputation: 480Reputation: 480
Quote:
Originally Posted by drlukacs View Post
Where would it make the most sense to insert such a call?
In if_up() where the call to rc.wireless is.

Quote:
How would such an approach deal with adding tunnels and/or various routing policies?
Like PPP and VPN, this is out of the scope of rc.inet1. For complex router setups you should use quagga.

Quote:
What behaviour would you expect in terms of dhcpcd? (Does the latest version of dhcpcd support IPv6?)
It does. In Slackware 14.0 it configures IPv6 automatically, if the ipv6 module is loaded early enough (say by initrd).
 
Old 10-19-2012, 10:18 PM   #13
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Original Poster
Rep: Reputation: 4
IPv6 startup scripts -- comments are welcome

I wrote a script following the suggestions from the forum:

http://dl.dropbox.com/u/6403337/IPv6/rc.ipv6

http://dl.dropbox.com/u/6403337/IPv6/rc.inet1

http://dl.dropbox.com/u/6403337/IPv6/rc.ipv6.conf

I would definitely welcome any comments and suggestions on how to improve it. I have a couple of concrete questions:

1. Is it better to have a separate rc.ipv6.conf (following the model of rc.wireless), or would it make more sense to include the variables in
rc.inet1.conf?

2. The script rc.ipv6 assumes that it gets IFNAME from rc.inet1 (just as rc.wireless does). Is it a good assumption, or should it create IFNAME independently? In the first case, should that warning be displayed if rc.ipv6 is run from anywhere but rc.inet1?

3. I have not created stop functions, because if a device is taken down in rc.inet1, then there is no need to take it down once more in rc.ipv6. However, if rc.ipv6 is made into a more stand-alone script, then this may make sense -- one might want to just turn off IPv6 on a particular device without wanting the device to be taken down. Same thing with the default gateway.

Opinions?
 
Old 11-21-2012, 05:37 AM   #14
leigh8904
LQ Newbie
 
Registered: Nov 2012
Location: Melbourne, Australia
Distribution: Slackware + FreeBSD
Posts: 26

Rep: Reputation: Disabled
Hi.

Another option is to embed static IPv6 configuration into rc.inet1 and rc.inet1.conf. To that end I have created two patches, which are available from: freeshell.de/~lwedding/slackware-14.0/.

rc.inet1.patch is a patch which can be applied to an installed system; although it may fail for rc.inet1.conf due to your local configuration, but it should be easy to manually fix.

network-scripts.patch is a patch for the source for network-scripts package (part of "n" package set).

Hope this is useful to someone.

Note: URL above is not clicky as this is my first post, and URLs are not allowed for first post.
 
Old 11-21-2012, 08:15 AM   #15
drlukacs
Member
 
Registered: Oct 2012
Location: Halifax, NS, Canada
Distribution: Slackware
Posts: 34

Original Poster
Rep: Reputation: 4
Quote:
Originally Posted by leigh8904 View Post
Hi.

Another option is to embed static IPv6 configuration into rc.inet1 and rc.inet1.conf. To that end I have created two patches, which are available from: freeshell.de/~lwedding/slackware-14.0/.
I like the idea of patching the network scrips, but:

1) It appears that it will work only if you do not use DHCP for IPv4. In real life, one may be using DHCP for IPv4, and static settings for IPv6.

2) The script does not allow adding multiple IPv6 addresses to the same interface.

3) The script does not add a default gateway...
 
  


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
Start up scripts? penguinHugger Linux - General 2 12-14-2008 09:14 AM
Start Up Scripts deepgrewal SUSE / openSUSE 2 08-26-2007 02:25 PM
debian start up scripts? pgte3 Debian 7 08-25-2004 06:42 PM
Start up scripts??? caged Slackware 7 06-02-2004 11:58 PM
Start Up Scripts in Linux clintonm9 Linux - Software 3 06-24-2003 09:37 AM

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

All times are GMT -5. The time now is 08:55 PM.

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