10 More Discussions You Might Find Interesting
1. Solaris
I have two ethernet interfaces nge0 and nge1.
An IP assigned on nge0 is 10.10.10.1/24 and on nge1 is 20.20.20.1/24. I want to make nge0 as primary interface.
My question here is,
1. Being nge0 as primary interface, if I ping to an IP 20.20.20.5, what will happen?
2. If the answer for the... (4 Replies)
Discussion started by: nthiruvenkatam
4 Replies
2. Shell Programming and Scripting
Hi
I am trying to create a script extracting the IP provided by ifconfig.
I tried with grep + awk but I am returned more than I need.
/sbin/ifconfig eth0 | grep "inet addr:" | awk '/inet addr:/ { print $2 }'
and returns
addr:10.15.1.64
How can I remove "addr:" string?... (9 Replies)
Discussion started by: manustone
9 Replies
3. Solaris
hi,
I am trying to configure one of my interfaces, but after reboot - i lose the changes to the netmask & broadcast address.
I have added an entry in /etc/netmasks, but it doesnt pick up the new settings. any ideas - much appreciated.
before reboot:
eri0:... (3 Replies)
Discussion started by: badoshi
3 Replies
4. IP Networking
I'm working on an AIX Unix LPAR (AIX 3.5 00C3C9904C00 as returned by uname -a)
I can access this box using telnet, port 22 using adress IP A and B
A=AA.AA.XX.XX and B=AA.AA.YYY.YYY
I can confirm these 2 are the same space, I can see
I can't find address B listed anywhere... so I wonder what... (1 Reply)
Discussion started by: Isax50
1 Replies
5. Shell Programming and Scripting
I'm a newbie to linux, so pleases forgive me!
I would like to find a script that I could use to extract a dynamic ip from the ppp0 and set it as a variable to be used in IPTables
basically, if ppp0 ip address is 10.10.10.20, I would like a script that would set a var to 10.10.10.0. of... (9 Replies)
Discussion started by: speedy3k
9 Replies
6. Shell Programming and Scripting
Hello All,
Can someone show me how to cat "only the IP address of e1000g0" using ifconfig -a.
i am trying to grep only the ip address (xx.xx.xx.xx) from the bunch of all other things like, broadcast address, IPV4, UP........and so on.
thanks (1 Reply)
Discussion started by: solaix14
1 Replies
7. Shell Programming and Scripting
hi,
i want to know how to grep inet address for below
below is the output of ifconfig command
/home/JA> ifconfig
eth0 Link encap:Ethernet HWaddr 00:11:0A:5B:2E:E9
inet addr:161.239.203.18 Bcast:161.239.203.127 Mask:255.255.255.128
UP BROADCAST RUNNING... (3 Replies)
Discussion started by: mail2sant
3 Replies
8. IP Networking
HI All,
My interface card has failed.If i am giving the command to uplumb it i am getting an error.
ce401001: flags=219040843<UP,BROADCAST,RUNNING,MULTICAST,DEPRECATED,IPv4,NOFAILOVER,FAILED,CoS> mtu 1500 index 3
inet 10.188.24.18 netmask ffffffc0 broadcast 10.188.24.63
# ifconfig... (2 Replies)
Discussion started by: sag71155
2 Replies
9. Linux
Hi,
I am running Fedora 7. I seem to remember there being a command to determine the primary dns. Can anyone help me find out what it is?
Thanks! (2 Replies)
Discussion started by: user23
2 Replies
10. Solaris
hi all
iam trying to set my eri0 interface but with little luck .
when i set the ip using ipconfig i always get "bad adress"..
moreover when i use ifconfig eri0 i can notice that the inet is 0.0.0.0 and the netmask 0
i am runnig solaris 9 on sparc .
any helpis highly appreciated ... ... (2 Replies)
Discussion started by: ppass
2 Replies
IP-ADDRESS(8) Linux IP-ADDRESS(8)
NAME
ip-address - protocol address management
SYNOPSIS
ip [ OPTIONS ] address { COMMAND | help }
ip address { add | del } IFADDR dev STRING
ip address { show | flush } [ dev STRING ] [ scope SCOPE-ID ] [ to PREFIX ] [ FLAG-LIST ] [ label PATTERN ]
IFADDR := PREFIX | ADDR peer PREFIX [ broadcast ADDR ] [ anycast ADDR ] [ label STRING ] [ scope SCOPE-ID ]
SCOPE-ID := [ host | link | global | NUMBER ]
FLAG-LIST := [ FLAG-LIST ] FLAG
FLAG := [ permanent | dynamic | secondary | primary | tentative | deprecated | dadfailed | temporary ]
DESCRIPTION
The address is a protocol (IP or IPv6) address attached to a network device. Each device must have at least one address to use the corre-
sponding protocol. It is possible to have several different addresses attached to one device. These addresses are not discriminated, so
that the term alias is not quite appropriate for them and we do not use it in this document.
The ip address command displays addresses and their properties, adds new addresses and deletes old ones.
ip address add - add new protocol address.
dev NAME
the name of the device to add the address to.
local ADDRESS (default)
the address of the interface. The format of the address depends on the protocol. It is a dotted quad for IP and a sequence of hexa-
decimal halfwords separated by colons for IPv6. The ADDRESS may be followed by a slash and a decimal number which encodes the net-
work prefix length.
peer ADDRESS
the address of the remote endpoint for pointopoint interfaces. Again, the ADDRESS may be followed by a slash and a decimal number,
encoding the network prefix length. If a peer address is specified, the local address cannot have a prefix length. The network
prefix is associated with the peer rather than with the local address.
broadcast ADDRESS
the broadcast address on the interface.
It is possible to use the special symbols '+' and '-' instead of the broadcast address. In this case, the broadcast address is
derived by setting/resetting the host bits of the interface prefix.
label NAME
Each address may be tagged with a label string. In order to preserve compatibility with Linux-2.0 net aliases, this string must
coincide with the name of the device or must be prefixed with the device name followed by colon.
scope SCOPE_VALUE
the scope of the area where this address is valid. The available scopes are listed in file /etc/iproute2/rt_scopes. Predefined
scope values are:
global - the address is globally valid.
site - (IPv6 only) the address is site local, i.e. it is valid inside this site.
link - the address is link local, i.e. it is valid only on this device.
host - the address is valid only inside this host.
ip address delete - delete protocol address
Arguments: coincide with the arguments of ip addr add. The device name is a required argument. The rest are optional. If no arguments
are given, the first address is deleted.
ip address show - look at protocol addresses
dev NAME (default)
name of device.
scope SCOPE_VAL
only list addresses with this scope.
to PREFIX
only list addresses matching this prefix.
label PATTERN
only list addresses with labels matching the PATTERN. PATTERN is a usual shell style pattern.
up only list running interfaces.
dynamic and permanent
(IPv6 only) only list addresses installed due to stateless address configuration or only list permanent (not dynamic) addresses.
tentative
(IPv6 only) only list addresses which have not yet passed duplicate address detection.
deprecated
(IPv6 only) only list deprecated addresses.
dadfailed
(IPv6 only) only list addresses which have failed duplicate address detection.
temporary
(IPv6 only) only list temporary addresses.
primary and secondary
only list primary (or secondary) addresses.
ip address flush - flush protocol addresses
This command flushes the protocol addresses selected by some criteria.
This command has the same arguments as show. The difference is that it does not run when no arguments are given.
Warning: This command (and other flush commands described below) is pretty dangerous. If you make a mistake, it will not forgive it, but
will cruelly purge all the addresses.
With the -statistics option, the command becomes verbose. It prints out the number of deleted addresses and the number of rounds made to
flush the address list. If this option is given twice, ip address flush also dumps all the deleted addresses in the format described in
the previous subsection.
EXAMPLES
ip address show dev eth0
Shows the addresses assigned to network interface eth0
ip addr add 2001:0db8:85a3::0370:7334/64 dev eth1
Adds an IPv6 address to network interface eth1
ip addr flush dev eth4
Removes all addresses from device eth4
SEE ALSO
ip(8)
AUTHOR
Original Manpage by Michail Litvak <mci@owl.openwall.com>
iproute2 20 Dec 2011 IP-ADDRESS(8)