Mailing List Archive

/etc/resolv.conf
I just finished installing Gentoo on my laptop but I have one little
problem. I can't connect to the internet when I move somewhere else
because my /etc/resolv.conf file has the information for my home
network. Is there a way to have my system generate a new
/etc/resolv.conf automatically each time I boot up, or by running a
script, etc? Thanks everyone!!!

--
Free image hosting at http://www.rickserver.com

--
gentoo-user@gentoo.org mailing list
Re: /etc/resolv.conf [ In reply to ]
Such a way exists only if there's a way for the machine to know where
you are and what is appropriate for each location. How could it tell?

++ kevin


On Tue, 21 Sep 2004 23:33:30 -0400, Rick Hennigan <rhennigan@gmail.com> wrote:
> I just finished installing Gentoo on my laptop but I have one little
> problem. I can't connect to the internet when I move somewhere else
> because my /etc/resolv.conf file has the information for my home
> network. Is there a way to have my system generate a new
> /etc/resolv.conf automatically each time I boot up, or by running a
> script, etc? Thanks everyone!!!
>
> --
> Free image hosting at http://www.rickserver.com
>
> --
> gentoo-user@gentoo.org mailing list
>
>



--
Kevin O'Gorman, PhD
want a free gmail account? email me for an invitation

--
gentoo-user@gentoo.org mailing list
Re: /etc/resolv.conf [ In reply to ]
and there are quite a few scripts that will do just that, either by
"guessing" from what else is found on the network, or by the user saying
which environment is present.

but the easiest way is by using dhcp, which will populate
/etc/resolv.conf


On Tue, 21 Sep 2004 20:56:22 -0700
Kevin O'Gorman <kogorman@gmail.com> wrote:

> Such a way exists only if there's a way for the machine to know where
> you are and what is appropriate for each location. How could it tell?
>
> ++ kevin
>
>
> On Tue, 21 Sep 2004 23:33:30 -0400, Rick Hennigan <rhennigan@gmail.com> wrote:
> > I just finished installing Gentoo on my laptop but I have one little
> > problem. I can't connect to the internet when I move somewhere else
> > because my /etc/resolv.conf file has the information for my home
> > network. Is there a way to have my system generate a new
> > /etc/resolv.conf automatically each time I boot up, or by running a
> > script, etc? Thanks everyone!!!
> >
> > --
> > Free image hosting at http://www.rickserver.com
> >
> > --
> > gentoo-user@gentoo.org mailing list
> >
> >
>
>
>
> --
> Kevin O'Gorman, PhD
> want a free gmail account? email me for an invitation
>
> --
> gentoo-user@gentoo.org mailing list

--
Nick Rout <nick@rout.co.nz>


--
gentoo-user@gentoo.org mailing list
Re: /etc/resolv.conf [ In reply to ]
On Tuesday 21 September 2004 22:33, Rick Hennigan wrote:
> I just finished installing Gentoo on my laptop but I have one little
> problem. I can't connect to the internet when I move somewhere else
> because my /etc/resolv.conf file has the information for my home
> network. Is there a way to have my system generate a new
> /etc/resolv.conf automatically each time I boot up, or by running a
> script, etc? Thanks everyone!!!

I, too, have a home network though I connect directly from the notebook rather
than run the server 24/7. When I go to the offic and I am able to get on the
wireless network w/o touching the resolv.conf file at all. Perhaps you
should post your file so others can take a look & make an educated guess as
to what you might do.
--
..."Yogi" CH
Namasté Yoga Studio
"If music be the food of love, why can't rabbits sing?"


--
gentoo-user@gentoo.org mailing list
Re: /etc/resolv.conf [ In reply to ]
Rick Hennigan wrote:
> I just finished installing Gentoo on my laptop but I have one little
> problem. I can't connect to the internet when I move somewhere else
> because my /etc/resolv.conf file has the information for my home
> network. Is there a way to have my system generate a new
> /etc/resolv.conf automatically each time I boot up, or by running a
> script, etc? Thanks everyone!!!

Yes, there are multiple methods. There was a large thread that I
started here:
http://marc.theaimsgroup.com/?l=gentoo-user&m=108432193606940&w=2
and summarised here:
http://marc.theaimsgroup.com/?l=gentoo-user&m=108486469320272&w=2

One of the common ones did it automatically before your network was even
up, by looking at arps, the other did it based on what you selected
(home, work, wireless, etc) which you could choose at boot, or after
boot, or both or neither!!

HTH,
--
Iain


--
gentoo-user@gentoo.org mailing list
Re: /etc/resolv.conf [ In reply to ]
Rick Hennigan wrote:
> I just finished installing Gentoo on my laptop but I have one little
> problem. I can't connect to the internet when I move somewhere else
> because my /etc/resolv.conf file has the information for my home
> network. Is there a way to have my system generate a new
> /etc/resolv.conf automatically each time I boot up, or by running a
> script, etc? Thanks everyone!!!
>

'netenv' is a possible solution. It works great on debian.
I've not tried it yet on a gentoo portable, but, I will be soon.

http://netenv.sourceforge.net/netenv-en.html

I do not think it's an ebuild (yet) but if some saavy dev tries it,
maybe it could become an ebuild.....


James


--
gentoo-user@gentoo.org mailing list
Re: /etc/resolv.conf [ In reply to ]
Rick Hennigan wrote, On 22.09.2004 05:33:
> I just finished installing Gentoo on my laptop but I have one little
> problem. I can't connect to the internet when I move somewhere else
> because my /etc/resolv.conf file has the information for my home
> network. Is there a way to have my system generate a new
> /etc/resolv.conf automatically each time I boot up, or by running a
> script, etc? Thanks everyone!!!
>

Just right now found this:

For laptop users: different network configurations
http://forums.gentoo.org/viewtopic.php?t=90752

bye Thilo


--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
I'm using DHCP and it updates my resolv.conf automagically. (It's
actually a pain because the domain isn't setup right.) Are you using
DHCP or do you manually configure your network?

--Kurt




> Rick Hennigan wrote, On 22.09.2004 05:33:
>> I just finished installing Gentoo on my laptop but I have one little
>> problem. I can't connect to the internet when I move somewhere else
>> because my /etc/resolv.conf file has the information for my home
>> network. Is there a way to have my system generate a new
>> /etc/resolv.conf automatically each time I boot up, or by running a
>> script, etc? Thanks everyone!!!
>>
>
> Just right now found this:
>
> For laptop users: different network configurations
> http://forums.gentoo.org/viewtopic.php?t=90752
>
> bye Thilo
>
>
> --
> gentoo-user@gentoo.org mailing list
>
>



--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
Thilo Six wrote:
> Rick Hennigan wrote, On 22.09.2004 05:33:
>
>> I just finished installing Gentoo on my laptop but I have one little
>> problem. I can't connect to the internet when I move somewhere else
>> because my /etc/resolv.conf file has the information for my home
>> network. Is there a way to have my system generate a new
>> /etc/resolv.conf automatically each time I boot up, or by running a
>> script, etc? Thanks everyone!!!
>>
>
> Just right now found this:
>
> For laptop users: different network configurations
> http://forums.gentoo.org/viewtopic.php?t=90752
>
> bye Thilo
>
>
> --
> gentoo-user@gentoo.org mailing list
>
>

netenv is very clean and handles dns and many other issues. Maybe some
developer will take a look at netenv and create an ebuild....?

http://netenv.sourceforge.net/netenv-en.html

James



--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
On Wednesday 22 September 2004 04:13 pm, wireless wrote:
> netenv is very clean and handles dns and many other issues. Maybe some
> developer will take a look at netenv and create an ebuild....?
>
> http://netenv.sourceforge.net/netenv-en.html

Or you could and submit the ebuild.. :)

Jeff
Re: Re: /etc/resolv.conf [ In reply to ]
Jeff Smelser wrote:
> On Wednesday 22 September 2004 04:13 pm, wireless wrote:
>
>>netenv is very clean and handles dns and many other issues. Maybe some
>>developer will take a look at netenv and create an ebuild....?
>>
>>http://netenv.sourceforge.net/netenv-en.html
>
>
> Or you could and submit the ebuild.. :)
>
> Jeff

OK, I'm game, although fairly new to gentoo. Early, somebody posted a
link:

http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&chap=0

Which I have glanced at. It does seem to offer ideas, but, not a
complete guide. Are there any other references or examples on turning
a tarball of source into an ebuild?

Any other forums, besides this one, for help on creating ebuilds?

James



--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
Check /usr/portage/skel.ebuild for a model ebuild, then man 1,5 ebuild.
I used some of the docs on the Gentoo site and looked at a bunch of
ebuilds when I started. Just take it one step at a time - ebuild is your
friend here. Check man ebuild and you see you can use ebuild to work in
stages - fetch, then unpack, then ... .

On Wed, 22 Sep 2004, wireless
wrote:

> Jeff Smelser wrote:
>> On Wednesday 22 September 2004 04:13 pm, wireless wrote:
>>
>>> netenv is very clean and handles dns and many other issues. Maybe some
>>> developer will take a look at netenv and create an ebuild....?
>> Jeff
>
> OK, I'm game, although fairly new to gentoo. Early, somebody posted a link:
>
> http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&chap=0
>
> Which I have glanced at. It does seem to offer ideas, but, not a complete
> guide. Are there any other references or examples on turning a tarball of
> source into an ebuild?
>
> Any other forums, besides this one, for help on creating ebuilds?
>
> James
>
>
>
> --
> gentoo-user@gentoo.org mailing list
>
>

--
Brett I. Holcomb

--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
Brett I. Holcomb wrote:
> Check /usr/portage/skel.ebuild for a model ebuild, then man 1,5 ebuild.
> I used some of the docs on the Gentoo site and looked at a bunch of
> ebuilds when I started. Just take it one step at a time - ebuild is
> your friend here. Check man ebuild and you see you can use ebuild to
> work in stages - fetch, then unpack, then ...

Thanks for the additional info. I'm reading now, and will give it a whirl.


James




--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
Don't get discouraged. I don't know what your background is but take it a
step at a time. I started out with a cvs ebuild which wasn't the smartest
way to go <G>. I just went through one step at a time. Tell ebuild to do
install and see where it breaks. Keep that up till you have a working
copy in the install directory.

That's what is so neat about portage. You can use ebuild packagename
install and it will do everything but actually install it to your system
so you can play with it and not break your system.

Also look at setting up PORTDIR_OVERLAY in /etc/make.conf and look at the
FEATURES in /etc/make.conf. You can set them so they won't remove the
files that portage uses to build the app. If you use the ebuild ...
install then you can go in and make sure everything is setup the way it's
supposed to be in the image directory.

Also get familiar with some of the eclasses (/usr/portage/eclass).

Have fun!

On Wed, 22 Sep 2004, wireless wrote:

> Brett I. Holcomb wrote:
>> Check /usr/portage/skel.ebuild for a model ebuild, then man 1,5 ebuild. I
>> used some of the docs on the Gentoo site and looked at a bunch of ebuilds
>> when I started. Just take it one step at a time - ebuild is your friend
>> here. Check man ebuild and you see you can use ebuild to work in stages -
>> fetch, then unpack, then ...
>
> Thanks for the additional info. I'm reading now, and will give it a whirl.
>
>
> James
>
>
>
>
> --
> gentoo-user@gentoo.org mailing list
>

--
Brett I. Holcomb

--
gentoo-user@gentoo.org mailing list
Re: Re: /etc/resolv.conf [ In reply to ]
Brett I. Holcomb wrote:
> Don't get discouraged. I don't know what your background is but take it
> a step at a time. I started out with a cvs ebuild which wasn't the
> smartest way to go <G>. I just went through one step at a time. Tell
> ebuild to do install and see where it breaks. Keep that up till you
> have a working copy in the install directory.
>
> That's what is so neat about portage. You can use ebuild packagename
> install and it will do everything but actually install it to your system
> so you can play with it and not break your system.
>
> Also look at setting up PORTDIR_OVERLAY in /etc/make.conf and look at
> the FEATURES in /etc/make.conf. You can set them so they won't remove
> the files that portage uses to build the app. If you use the ebuild ...
> install then you can go in and make sure everything is setup the way
> it's supposed to be in the image directory.
>
> Also get familiar with some of the eclasses (/usr/portage/eclass).
>
> Have fun!
>
Thanks for all the ideas. I am going to finish reading everything I
can find, maybe ask a question or 2 on the 'big picture' approach, and
then go off and do this.... That's what I see so far that is missing,
the overall development semantic of how to use ebuild, hacking bash
commands, then using cvs to upload and emerge to actually go thru the
process of (testing) downloading and installing the newly created
ebuild. Maybe I'll document this example (netenv) so it can be
reviewed by others and a documented example will exist. So far the
reading is providing good information and the process seems to be
reasonable.

thanks to everyone, for the ideas and encouragement.

James




--
gentoo-user@gentoo.org mailing list