• Check it out - we have a chatbot! Go ask TuxBot a question in the Ask Tuxbot section!

How to connect internet automatically during startup?

luofeiyu

New Member
Joined
Jul 4, 2021
Messages
1
Reaction score
0
Credits
17
The os recognize my ethernet device as `enp6s0`.

ifconfig -a
enp6s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.31.22 netmask 255.255.255.0 broadcast 192.168.31.255

My home network structure:

isp ---- moden ---- router ---- pc

I had already binding my pc mac address with `192.168.31.22` in router setting,router ip locates `192.168.31.1`.
Everytime i boot pc ,it can't connect the internet automatically,i have click connect button on wcid network manager gui.

It is no use to set the `/etc/network/interfaces` as below:

Setting as static ip.

auto lo
iface lo inet loopback
auto enp6s0
iface enp6s0 inet static
address 192.168.31.22
netmask 255.255.255.0
gateway 192.168.31.1
dns-nameservers 192.168.31.1

setting as dhcp.

auto lo
iface lo inet loopback
auto enp6s0
iface enp6s0 inet dhcp
 

Attachments

  • connect.png
    connect.png
    38.7 KB · Views: 187


Condobloke

Well-Known Member
Joined
Apr 30, 2017
Messages
5,901
Reaction score
4,908
Credits
36,880
g'day, Welcome toLinux.org

Why do you use wicd as opposed to network manager ?

Wicd is a network connection manager that can manage wireless and wired interfaces, similar and an alternative to NetworkManager.Wicd is written in Python and GTK.Wicd can also run from the terminal in a curses interface, requiring no X server session or task panel

Does it connect normally via network manager?

And...seeing the crystal ball is not working today, what exactly is 'your os'....and any other details you may think pertinent.
 
Last edited:

MatsuShimizu

Well-Known Member
Joined
Jan 14, 2021
Messages
403
Reaction score
583
Credits
8,788
I assume that you are using Debian because you are posting in Debian subforum.
Run these commands:
sudo apt-get install inxi
inxi -Nni
Then, post the results from your terminal here.
 
MALIBAL Linux Laptops

Linux Laptops Custom Built for You
MALIBAL is an innovative computer manufacturer that produces high-performance, custom laptops for Linux.

For more info, visit: https://www.malibal.com

Members online


Latest posts

Top