Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Michael
On Friday, 19 April 2024 18:04:57 BST Dale wrote:

> I'm missing something.

I don't think you are.  Shutdown your main rig.  Pull the ethernet cable. 
Reboot.  If the main rig's config is the same as the old rig,

AND

the router addressing is analogous on both PCs, 

THEN

their behaviour and messages ought to be the same.

> 
> Dale
> 
> :-)  :-) 
> 
> P. S. Back to mowing grass. 



signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Dale
Michael wrote:
> On Friday, 19 April 2024 17:20:44 BST Dale wrote:
>> Matt Connell wrote:
>>> On Fri, 2024-04-19 at 09:05 -0500, Dale wrote:
 Basically, I want to be able to start/stop/restart enp3s0 as a
 service and have it in a runlevel. 
>>> You should just need to create a symlink at /etc/init.d/net.enp3s0 that
>>> points to /etc/init.d/net.lo and then you can do the usual rc-service
>>> stuff with it.
>> I did that and went from default to boot runlevel and back to default
>> again but I still couldn't restart with the net.enp3s0 file.  Luckily, I
>> shut the rig down a bit ago.  I went to mow some grass.  Using push
>> mower since battery went bad on riding mower.  Anyway, when I booted it
>> back up just now, it worked.  I can start/stop/restart with the enp3s0
>> file like on my main rig.  It still says it is defaulting to DHCP which
>> makes me think I'm still missing something.  It says, I'm typing this in
>> manually. 
>>
>>
>> Bringing up interface enp3s0
>> config_enp3s0 not specified; defaulting to DHCP
>>
>>
>> Then it continues bringing up the network.  I have this set:
>>
>> nas / # cat /etc/conf.d/net
>> config_enp3s0="dhcp"
>> dns_servers_enp3s0="8.8.8.8 8.8.4.4"
>> nas / #
>>
>>
>> Since I have it set to use DHCP already, why is it saying it is
>> defaulting to it?  Did I miss a file or something?   Shouldn't it just
>> use it without saying it is defaulting to it?  I don't recall seeing
>> this on my main rig. 
>>
>> Dale
>>
>> :-)  :-) 
> Normally you would use netifrc to configure a gateway and static IP address.  
> DHCP is a fallback, in case the static IP subnet has changed - e.g. because 
> you changed your home router.
>
> If you *are* using dhcpcd to obtain an IP address from the router then 
> arguably your don't need netifrc at all, as I explained in my other message 
> earlier.
>
> Regarding the messages you see on your main rig Vs the old rig, you can 
> compare the two PC's conf.net files for any differences.


That's thing.  I think they are the same.  Here is my main rig, fireball. 


root@fireball / # cat /etc/conf.d/net
config_enp3s0="dhcp"
dns_servers_enp3s0="8.8.8.8 8.8.4.4"
root@fireball / #


NAS box:

nas / # cat /etc/conf.d/net
config_enp3s0="dhcp"
dns_servers_enp3s0="8.8.8.8 8.8.4.4"
nas / #


One says it is defaulting, the other doesn't.  I've used grep to search,
I've looked everywhere I can think of that even might have some config
file for network stuff and I can't find any difference. 

On your other reply.  I think I did set up the router to set IP
addresses.  I know I did for my phone and printer.  That printer used to
drive me nuts.  Every time the power would blink, it wouldn't print.  No
IP address so can't access it except through that tiny little display
and the buttons on the printer.  What a drag.  o_O 

I'm missing something.  I set up the network on this rig almost a decade
ago.  I have very little memory of how I did it.  I always thought I
could just refer back to the install guide.  Didn't occur to me they
would remove stuff. 

Dale

:-)  :-) 

P. S. Back to mowing grass. 



Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Matt Connell
On Fri, 2024-04-19 at 17:34 +0100, Michael wrote:
> Configure static IP addresses for all your LAN devices on your home
> router.  Then set your devices to use DHCP to obtain an address from
> the router when they come up.  With a large number of devices which
> often change (e.g. guests in a hotel) this is inadvisable, but with a
> home LAN with a handful of devices  this is not too much of a chore.

This is what I do, for the sake of the argument. I never touch client
configuration on anything; the router is the boss. Much easier that way
in my experience.



Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Michael
On Friday, 19 April 2024 17:20:44 BST Dale wrote:
> Matt Connell wrote:
> > On Fri, 2024-04-19 at 09:05 -0500, Dale wrote:
> >> Basically, I want to be able to start/stop/restart enp3s0 as a
> >> service and have it in a runlevel. 
> > 
> > You should just need to create a symlink at /etc/init.d/net.enp3s0 that
> > points to /etc/init.d/net.lo and then you can do the usual rc-service
> > stuff with it.
> 
> I did that and went from default to boot runlevel and back to default
> again but I still couldn't restart with the net.enp3s0 file.  Luckily, I
> shut the rig down a bit ago.  I went to mow some grass.  Using push
> mower since battery went bad on riding mower.  Anyway, when I booted it
> back up just now, it worked.  I can start/stop/restart with the enp3s0
> file like on my main rig.  It still says it is defaulting to DHCP which
> makes me think I'm still missing something.  It says, I'm typing this in
> manually. 
> 
> 
> Bringing up interface enp3s0
> config_enp3s0 not specified; defaulting to DHCP
> 
> 
> Then it continues bringing up the network.  I have this set:
> 
> nas / # cat /etc/conf.d/net
> config_enp3s0="dhcp"
> dns_servers_enp3s0="8.8.8.8 8.8.4.4"
> nas / #
> 
> 
> Since I have it set to use DHCP already, why is it saying it is
> defaulting to it?  Did I miss a file or something?   Shouldn't it just
> use it without saying it is defaulting to it?  I don't recall seeing
> this on my main rig. 
> 
> Dale
> 
> :-)  :-) 

Normally you would use netifrc to configure a gateway and static IP address.  
DHCP is a fallback, in case the static IP subnet has changed - e.g. because 
you changed your home router.

If you *are* using dhcpcd to obtain an IP address from the router then 
arguably your don't need netifrc at all, as I explained in my other message 
earlier.

Regarding the messages you see on your main rig Vs the old rig, you can 
compare the two PC's conf.net files for any differences.

signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Michael
On Friday, 19 April 2024 17:26:43 BST Dale wrote:
> Michael wrote:
> > On Friday, 19 April 2024 15:05:47 BST Dale wrote:
> >> Anyway, while investigating this, I realized the network setup is not
> >> like on my old rig.  Heck, I couldn't even figure out how to restart it
> >> other than switching to the boot runlevel and back to default, or
> >> rebooting.  After a bit, I think I can restart DHCP and it restart the
> >> network.  I figured out the cable was unplugged before trying that.  I'm
> >> wanting to set up the NAS box network the same way as my main rig.
> >> That's the old manual way.  I went back to the install handbook, that's
> >> what I followed when installing on my main rig.  Thing is, it has been
> >> updated and the old way isn't all there.  I followed what little bit is
> >> there but it defaults back to the new way.  I'm sure I'm missing some
> >> file I need to edit but I can't figure out which one it is.  So, is
> >> there a way to get the old instructions again?  The ones I followed
> >> several years ago for my main rig?  I tried searching but it seems they
> >> all gone.  Maybe there is a place I'm not aware of tho.  Basically, I
> >> want to be able to start/stop/restart enp3s0 as a service and have it in
> >> a runlevel.
> > 
> > Without knowing what you refer to as 'The Old Way' Vs 'The New Way', or
> > how
> > your 'main rig', Vs your 'old rig' may have been configured, I'll try to
> > make a guess, or two:
> > 
> > 1. Old Way = netifrc
> > 
> > You configure /etc/conf.d/net using the well commented example provided
> > in:
> > 
> > /usr/share/doc/netifrc-*/net.example.bz2
> > 
> > You symlink your interface enp3s0 to the net.lo netifrc init script and
> > add it to the default runlevel:
> > 
> > ln -s /etc/init.d/net.lo /etc/init.d/net.enp3s0
> > rc-update add net.enp3s0 default
> > 
> > then (re)start, check the status, or stop your newly configured interface,
> > e.g.:
> > 
> > rc-service -v net.enp3s0 status
> > rc-service -v net.enp3s0 restart
> > 
> > More detailed info than you should ever need and all on one page, is
> > provided here:
> > 
> > https://wiki.gentoo.org/wiki/Netifrc
> > 
> > 
> > 2. New Way = DHCP (?)
> > 
> > Although dhcp can be configured as a fallback option within
> > /etc/conf.d/net in addition to static addresses, gateways, etc., it can
> > also be set up as a standalone service without netifrc.  Emerge dhcpcd
> > and add it to the default runlevel.
> > 
> > If you have set static IP address(es) at your home router for the old box
> > and its MAC address, then that's all you need to do before you run:
> > 
> > rc-service -v dhcpcd restart
> > 
> > If you prefer to not set up a configuration for your old rig on the
> > router,
> > then you can add a static IP address in your /etc/dhcpcd.conf.
> > 
> > Again, more  info than you should need is provided here:
> > 
> > https://wiki.gentoo.org/wiki/Dhcpcd
> > 
> > HTH, otherwise ask if you get stuck.
> 
> Rebooting the NAS box improved things.  See reply to Matt.  By old way,
> I mean using a symlink to net.lo with the interface/card name such as
> enp3s0 to start/stop/restart the service.  It still uses DHCP to get
> connection info but I'd also like to specify the IP address if I can.  I
> like to set those so that they don't change even if I move cables
> around.  Main rig, NAS box, cell phone and printer.  The printer really
> gets upset when something changes. 
> 
> I think I should have used the word "older" instead of "old".  ROFL  :-D 
> 
> Dale
> 
> :-)  :-) 

OKey, dOKey, you can:

Configure static IP addresses for all your LAN devices on your home router.  
Then set your devices to use DHCP to obtain an address from the router when 
they come up.  With a large number of devices which often change (e.g. guests 
in a hotel) this is inadvisable, but with a home LAN with a handful of devices 
this is not too much of a chore.

Alternatively, you can configure each of your devices with static IP 
addresses.  The URLs I sent you explain how to do this.  For a couple of PCs 
this should take less than 5 minutes, inc. restarting the NIC service, or a 
reboot to make sure all works as intended on statup.

signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Dale
Michael wrote:
> On Friday, 19 April 2024 15:05:47 BST Dale wrote:
>
>> Anyway, while investigating this, I realized the network setup is not
>> like on my old rig.  Heck, I couldn't even figure out how to restart it
>> other than switching to the boot runlevel and back to default, or
>> rebooting.  After a bit, I think I can restart DHCP and it restart the
>> network.  I figured out the cable was unplugged before trying that.  I'm
>> wanting to set up the NAS box network the same way as my main rig. 
>> That's the old manual way.  I went back to the install handbook, that's
>> what I followed when installing on my main rig.  Thing is, it has been
>> updated and the old way isn't all there.  I followed what little bit is
>> there but it defaults back to the new way.  I'm sure I'm missing some
>> file I need to edit but I can't figure out which one it is.  So, is
>> there a way to get the old instructions again?  The ones I followed
>> several years ago for my main rig?  I tried searching but it seems they
>> all gone.  Maybe there is a place I'm not aware of tho.  Basically, I
>> want to be able to start/stop/restart enp3s0 as a service and have it in
>> a runlevel. 
> Without knowing what you refer to as 'The Old Way' Vs 'The New Way', or how 
> your 'main rig', Vs your 'old rig' may have been configured, I'll try to make 
> a guess, or two:
>
> 1. Old Way = netifrc
>
> You configure /etc/conf.d/net using the well commented example provided in:
>
> /usr/share/doc/netifrc-*/net.example.bz2
>
> You symlink your interface enp3s0 to the net.lo netifrc init script and add 
> it 
> to the default runlevel:
>
> ln -s /etc/init.d/net.lo /etc/init.d/net.enp3s0
> rc-update add net.enp3s0 default
>
> then (re)start, check the status, or stop your newly configured interface, 
> e.g.:
>
> rc-service -v net.enp3s0 status
> rc-service -v net.enp3s0 restart
>
> More detailed info than you should ever need and all on one page, is provided 
> here:
>
> https://wiki.gentoo.org/wiki/Netifrc
>
>
> 2. New Way = DHCP (?)
>
> Although dhcp can be configured as a fallback option within /etc/conf.d/net 
> in 
> addition to static addresses, gateways, etc., it can also be set up as a 
> standalone service without netifrc.  Emerge dhcpcd and add it to the default 
> runlevel.
>
> If you have set static IP address(es) at your home router for the old box and 
> its MAC address, then that's all you need to do before you run:
>
> rc-service -v dhcpcd restart
>
> If you prefer to not set up a configuration for your old rig on the router, 
> then you can add a static IP address in your /etc/dhcpcd.conf.
>
> Again, more  info than you should need is provided here:
>
> https://wiki.gentoo.org/wiki/Dhcpcd
>
> HTH, otherwise ask if you get stuck.


Rebooting the NAS box improved things.  See reply to Matt.  By old way,
I mean using a symlink to net.lo with the interface/card name such as
enp3s0 to start/stop/restart the service.  It still uses DHCP to get
connection info but I'd also like to specify the IP address if I can.  I
like to set those so that they don't change even if I move cables
around.  Main rig, NAS box, cell phone and printer.  The printer really
gets upset when something changes. 

I think I should have used the word "older" instead of "old".  ROFL  :-D 

Dale

:-)  :-) 


Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Dale
Matt Connell wrote:
> On Fri, 2024-04-19 at 09:05 -0500, Dale wrote:
>> Basically, I want to be able to start/stop/restart enp3s0 as a
>> service and have it in a runlevel. 
> You should just need to create a symlink at /etc/init.d/net.enp3s0 that
> points to /etc/init.d/net.lo and then you can do the usual rc-service
> stuff with it.
>
>

I did that and went from default to boot runlevel and back to default
again but I still couldn't restart with the net.enp3s0 file.  Luckily, I
shut the rig down a bit ago.  I went to mow some grass.  Using push
mower since battery went bad on riding mower.  Anyway, when I booted it
back up just now, it worked.  I can start/stop/restart with the enp3s0
file like on my main rig.  It still says it is defaulting to DHCP which
makes me think I'm still missing something.  It says, I'm typing this in
manually. 


Bringing up interface enp3s0
config_enp3s0 not specified; defaulting to DHCP


Then it continues bringing up the network.  I have this set:

nas / # cat /etc/conf.d/net
config_enp3s0="dhcp"
dns_servers_enp3s0="8.8.8.8 8.8.4.4"
nas / #


Since I have it set to use DHCP already, why is it saying it is
defaulting to it?  Did I miss a file or something?   Shouldn't it just
use it without saying it is defaulting to it?  I don't recall seeing
this on my main rig. 

Dale

:-)  :-) 



SOLVED: Re: [gentoo-user] Getting WiFi to work

2024-04-19 Thread Peter Humphrey
On Tuesday, 9 April 2024 14:23:31 BST I wrote:

> I want to move my Intel i5 NUC box to a place where Ethernet is not
> available, nor like to become so. That means I have to get WiFi working,
> but I've had no success so far. The wiki pages are many, confusing and
> contradictory, so I'd like the panel's advice on the way to proceed.

Just reporting back.

I built a new system - using NetworkManager (after all I've said about it!) - 
now that it's so much quicker using binpkgs.

It all went fairly smoothly, taking one step at a time through changing 
several USE flags, installing various tools, and finally, adding the new wlan0 
interface to shorewall.

The machine can now boot with either wired or wireless network, or both.

Thank you, all who helped.

-- 
Regards,
Peter.






Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Michael
On Friday, 19 April 2024 15:05:47 BST Dale wrote:

> Anyway, while investigating this, I realized the network setup is not
> like on my old rig.  Heck, I couldn't even figure out how to restart it
> other than switching to the boot runlevel and back to default, or
> rebooting.  After a bit, I think I can restart DHCP and it restart the
> network.  I figured out the cable was unplugged before trying that.  I'm
> wanting to set up the NAS box network the same way as my main rig. 
> That's the old manual way.  I went back to the install handbook, that's
> what I followed when installing on my main rig.  Thing is, it has been
> updated and the old way isn't all there.  I followed what little bit is
> there but it defaults back to the new way.  I'm sure I'm missing some
> file I need to edit but I can't figure out which one it is.  So, is
> there a way to get the old instructions again?  The ones I followed
> several years ago for my main rig?  I tried searching but it seems they
> all gone.  Maybe there is a place I'm not aware of tho.  Basically, I
> want to be able to start/stop/restart enp3s0 as a service and have it in
> a runlevel. 

Without knowing what you refer to as 'The Old Way' Vs 'The New Way', or how 
your 'main rig', Vs your 'old rig' may have been configured, I'll try to make 
a guess, or two:

1. Old Way = netifrc

You configure /etc/conf.d/net using the well commented example provided in:

/usr/share/doc/netifrc-*/net.example.bz2

You symlink your interface enp3s0 to the net.lo netifrc init script and add it 
to the default runlevel:

ln -s /etc/init.d/net.lo /etc/init.d/net.enp3s0
rc-update add net.enp3s0 default

then (re)start, check the status, or stop your newly configured interface, 
e.g.:

rc-service -v net.enp3s0 status
rc-service -v net.enp3s0 restart

More detailed info than you should ever need and all on one page, is provided 
here:

https://wiki.gentoo.org/wiki/Netifrc


2. New Way = DHCP (?)

Although dhcp can be configured as a fallback option within /etc/conf.d/net in 
addition to static addresses, gateways, etc., it can also be set up as a 
standalone service without netifrc.  Emerge dhcpcd and add it to the default 
runlevel.

If you have set static IP address(es) at your home router for the old box and 
its MAC address, then that's all you need to do before you run:

rc-service -v dhcpcd restart

If you prefer to not set up a configuration for your old rig on the router, 
then you can add a static IP address in your /etc/dhcpcd.conf.

Again, more  info than you should need is provided here:

https://wiki.gentoo.org/wiki/Dhcpcd

HTH, otherwise ask if you get stuck.


signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Matt Connell
On Fri, 2024-04-19 at 09:05 -0500, Dale wrote:
> Basically, I want to be able to start/stop/restart enp3s0 as a
> service and have it in a runlevel. 

You should just need to create a symlink at /etc/init.d/net.enp3s0 that
points to /etc/init.d/net.lo and then you can do the usual rc-service
stuff with it.



[gentoo-user] Handbook and question about manual network setup

2024-04-19 Thread Dale
Howdy,

I'm playing around with my NAS box again.  I ran into a network issue. 
I sorta forgot I unplugged the network cable so obviously, it made it
difficult to ssh into the thing from my main rig.  After hooking up a
monitor and keyboard, I found the problem and plugged the network cable
back in.  ROFLMBO  Told y'all I forget stuff. 

Anyway, while investigating this, I realized the network setup is not
like on my old rig.  Heck, I couldn't even figure out how to restart it
other than switching to the boot runlevel and back to default, or
rebooting.  After a bit, I think I can restart DHCP and it restart the
network.  I figured out the cable was unplugged before trying that.  I'm
wanting to set up the NAS box network the same way as my main rig. 
That's the old manual way.  I went back to the install handbook, that's
what I followed when installing on my main rig.  Thing is, it has been
updated and the old way isn't all there.  I followed what little bit is
there but it defaults back to the new way.  I'm sure I'm missing some
file I need to edit but I can't figure out which one it is.  So, is
there a way to get the old instructions again?  The ones I followed
several years ago for my main rig?  I tried searching but it seems they
all gone.  Maybe there is a place I'm not aware of tho.  Basically, I
want to be able to start/stop/restart enp3s0 as a service and have it in
a runlevel. 

Also, I'd like to get the install handbook as one large page.  My
intention is to save it locally for future reference as it is now.  I
may even print a copy.  I looked at all the places that have different
options but can't find the whole thing as one large page.  I looked
under several drop down menus and such.  A long time ago, it was a
option.  I just can't find it now.  May that option isn't available
anymore.  I wish I had a copy of the one from several years ago.  Back
when I installed on my main rig. 

Some network info.  Lines that are commented out are options I tried but
didn't work.  It was worth a shot.  o_O 


nas / # grep -r '!net' /etc/
/etc/rc.conf:rc_hotplug="!net.*"
nas / # grep -r 'enp3s0' /etc/
/etc/resolv.conf:# Generated by dhcpcd from enp3s0.dhcp
/etc/conf.d/net:config_enp3s0="dhcp"
/etc/conf.d/net:dns_servers_enp3s0="8.8.8.8 8.8.4.4"
/etc/conf.d/net:#config_enp3s0="10.0.0.5"
nas / #nas / # ifconfig -s enp3s0
Iface  MTU    RX-OK RX-ERR RX-DRP RX-OVR    TX-OK TX-ERR TX-DRP
TX-OVR Flg
enp3s0   1500    16802  0  0 0 17196  0 
0  0 BMRU
nas / #


Thoughts?  If I had the old install info, I think I could get it to
work.  I did last time.  ;-)

Dale

:-)  :-)