1827810 Members
2067 Online
109969 Solutions
New Discussion

Re: ifconfig problem

 
SOLVED
Go to solution
Jerry Chen_2
Contributor

ifconfig problem

I use Red Hat 7.2
when I use /usr/local/bin/
start-pppoe to connect network

it will show /sbin/ifconfig : no such file or directory
But when I check
/sbin/ifconfig ,
ifconfig is there
And when I use ifconfig eth0 to check network ,
it will also show bash:/sbin/ifconfig : no such file or directory .
Can any one help me?

JerryChen
7 REPLIES 7
Oren Amit
Advisor

Re: ifconfig problem

Hi,

What does ls -la /sbin/ifconfig return ?
U.SivaKumar_2
Honored Contributor
Solution

Re: ifconfig problem

Hi,
Does eth0 exists under /dev
directory.?
Also check the permission of
ifconfig executable.

regards,
U.SivaKumar
Innovations are made when conventions are broken
Peter Kloetgen
Esteemed Contributor

Re: ifconfig problem

Hi Jerry,

seems like /sbin/ifconfig is a symbolic link which points to a no longer existing file. Check this out usine ls -l /sbin/ifconfig. This should show you where the link is pointing to.

Allways stay on the bright side of life!

Peter
I'm learning here as well as helping
Mark Fenton
Esteemed Contributor

Re: ifconfig problem

Actually, ifconfig is reporting that it can't find some file or other that it needs. I ran into similar confusion with a script a few months back, the error message was like yours, /path/cmdname: no such file or directory, but the issue wasn't the command, but an argument passed to the command. Specifically, I had typoed the directory path to the file I was trying to pass to the command.

hth
Mark
Jerry Chen_2
Contributor

Re: ifconfig problem

Hi
I use ls -la /sbin/ifconfig,it return
rwxr-xr-x ..................
and there is no eth0 in /dev/...
and ifconfig is not symbolic link ...
JerryChen
Steven Mertens
Trusted Contributor

Re: ifconfig problem

hi

I thought it's normal that /dev/eth0 doesnt
exists because its actually an alias to
your ethernet driver. Correct me if i am
wrong.

regards,

Steven
Mark Fenton
Esteemed Contributor

Re: ifconfig problem

I think we're getting closer to the source of ifconfig's discontent.

What is the output of

# ifconfig

What it should be is something like:
eth0 Link encap:Ethernet HWaddr 00:90:27:91:DB:86
inet addr:aaa.bbb.ccc.ddd Bcast:aaa.bbb.ccc.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:7693205 errors:0 dropped:0 overruns:0 frame:0
TX packets:482814 errors:0 dropped:0 overruns:0 carrier:0
collisions:0
RX bytes:733504895 (699.5 Mb) TX bytes:63812303 (60.8 Mb)

eth1 Link encap:Ethernet HWaddr 00:A0:C9:05:F2:77
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
EtherTalk Phase 2 addr:8/35
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:796619 errors:0 dropped:0 overruns:0 frame:0
TX packets:651925 errors:0 dropped:0 overruns:6 carrier:0
collisions:0
RX bytes:137205783 (130.8 Mb) TX bytes:254992358 (243.1 Mb)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
EtherTalk Phase 2 addr:0/0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:1743106 errors:0 dropped:0 overruns:0 frame:0
TX packets:1743106 errors:0 dropped:0 overruns:0 carrier:0
collisions:0
RX bytes:373798800 (356.4 Mb) TX bytes:373798800 (356.4 Mb)

Where eth0 et al are replaced by your network devices (modem, whatever)

If you are only seeing output for the lo, then the problem is probably that you haven't loaded the driver for your ethernet adapter, and will need to check why.

# service network status

should return the status of your configured network devices. If there are none, you will need to configure them.

Let us know!
Mark