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 02-03-2017, 12:29 PM   #1
rob.rice
Senior Member
 
Registered: Apr 2004
Distribution: slack what ever
Posts: 1,076

Rep: Reputation: 205Reputation: 205Reputation: 205
is there a way to get /etc/rc.d/rc.inet? to use a different rc.inet.conf


so that's my question
slackware 14.2
 
Old 02-03-2017, 01:07 PM   #2
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
/etc/rc/d/rc.inet1 is just a shell script, so you could always change the configuration file that it sources. That occurs on line 12, the first non-comment line of the script. Don't blame me if you mess up something by doing this, though.
 
Old 02-03-2017, 02:39 PM   #3
rob.rice
Senior Member
 
Registered: Apr 2004
Distribution: slack what ever
Posts: 1,076

Original Poster
Rep: Reputation: 205Reputation: 205Reputation: 205
OK so I copy rc.inet? to some place
rename it to start.inet1
same with /etc/rc.d/rc.inet2
change it change name and path the new config file and the path and name of /etc/rc.d/rc.inet2

to use the new settings and to connect eth0 do a

" /etc/rc.d/rc.inet1 stop;./start.inet1 start"

to get back to normal

"./start.inet1 stop;/etc/rc.d/rc.inet1 start "

I don't need the changed network configuration
full time just temporarily

Last edited by rob.rice; 02-03-2017 at 02:50 PM.
 
Old 02-03-2017, 02:50 PM   #4
montagdude
Senior Member
 
Registered: Apr 2016
Distribution: Slackware
Posts: 2,011

Rep: Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619Reputation: 1619
I don't know if it depends on the version of Slackware or something, but I don't have a plain old /etc/rc.d/rc.inet. I have /etc/rc.d/rc.inet1 and /etc/rc.d/rc.inet2, as well as some /etc/rc.d/rc.inet1.conf* files and /etc/rc.d/rc.inetd. So it looks like you can just change line 12 of /etc/rc.d/rc.inet1 to source whatever configuration file you want, and then do:

Code:
/etc/rc.d/rc.inet1 restart
You could alternatively copy the script to a name you will remember and then edit it instead of just changing the value in place. That would probably be safer and less confusing later on if you forget what you did.

Last edited by montagdude; 02-03-2017 at 02:55 PM.
 
Old 02-03-2017, 03:39 PM   #5
rob.rice
Senior Member
 
Registered: Apr 2004
Distribution: slack what ever
Posts: 1,076

Original Poster
Rep: Reputation: 205Reputation: 205Reputation: 205
I want to go back and fourth between configurations as needed

I have a sane system that dose what I want it to I don't want to mess that up

I need to write a script that will connect to a flashed wifi
router then run firefox on the WEB GUI of a repeater-bridge
the HUGE PROBLEM is the ip-address,netmask and the gateway address all have to be set because there is NO! DHCP server
running on the disconnected reapeater-bridg
all IP addresses come from the host AP it's wirelessly
connected to

I can connect to NOW by doing a ifconfig wlan0 down configuring the wirded-connection using static IP addresses
and connecting to it with wicd-curses

BUT

I'm going to hand this thing over to a computer illiterate
there is no way in hell he could ever configure a connection
and open a dot-decmal web address with out running a script
 
  


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
inet.conf never start the ftp daemon wowy Linux - Newbie 10 03-17-2015 09:18 AM
how does rc.inet.conf relate to eth number and nic? Z038 Linux - Networking 3 12-21-2012 11:02 PM
Missing /etc/inet/resolv.conf and /etc/defaultrouter files fresh Solaris 8 install mwx Linux - Networking 4 01-27-2009 01:39 AM
inet<---eth1[LinuxBox_1]eth0<---e0[LinuxBox_2] : LinuxBox_2 hv no inet connection? Andrea_44 Linux - Networking 5 10-25-2006 08:18 PM
x11vnc as a inet.conf service vic102482 Solaris / OpenSolaris 4 05-04-2005 02:34 AM

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

All times are GMT -5. The time now is 05:45 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