Sponsored Content
Special Forums IP Networking Setting up private and public ip on same machine. Post 302336653 by gratuitous_arp on Wednesday 22nd of July 2009 02:14:06 PM
Old 07-22-2009
I don't see how this will solve a bandwidth issue, but this is the answer to your question:

The 'ip' command will allow you to set multiple IP addresses on a single interface, whereas the 'ifconfig' command will replace an existing IP address with a specified new address.

So to add multiple address to an interface, use:

Code:
ip address add 192.168.1.1/24 dev eth0
ip address add 4.2.2.2/28 dev eth0

And don't forget to bring the link up:

Code:
ip link set eth0 up

To delete an IP address from the interface, replace "add" with "delete".
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

SSH public and private keys

Firstly, i apologise if i have posted in a wrong section of the forum. Please let me know which is the correct section my post should go to. I have to SCP a file from one server(server A) to another (server B). I read around that a secure way is to use public and private keys. Assuming my... (2 Replies)
Discussion started by: new2ss
2 Replies

2. UNIX for Dummies Questions & Answers

ssh public/private Keys

Hello, I have an issue with an outside party trying to deliver a file to our server via SFTP. I have setup the .ssh directory under the home directory for the user account that is being used and setup the authorized_keys file with correct permissons etc for .ssh directory and file. We... (2 Replies)
Discussion started by: richo king
2 Replies

3. UNIX for Dummies Questions & Answers

SSL Public key/Private question

Hi everyone, I have a quick/newb question: I know that a public key is used to encrypt data and a private key is used to decrypt data but who keeps the public/private keys?? Does the Web Server hold both? Does the Web Server have the public key and does the client have the private key? ... (3 Replies)
Discussion started by: tical00
3 Replies

4. Shell Programming and Scripting

SFTP - Private and Public keys

Hi All, I have a query....say on server A, I have generated the Private and Public keys and shared the public key with server B. Now i can surelyconnect(without password) from server A to server B..... but can i similarly connect from server B to server A as well Regards (1 Reply)
Discussion started by: Arpit Narula
1 Replies

5. Shell Programming and Scripting

sftp using private and public keys

hi guys , i have few files i have to do sftp, the public and private key work like a magic , no problem at all the syntax is as below sftp -0 identityfile=~/ure/blsl/loc2/.ssh/id_rsa_ssh1 ssh1@remote >log_dir/file.timestamp<<end lcd folder cd folder put * quit end ================ my... (3 Replies)
Discussion started by: rockymayavia
3 Replies

6. Virtualization and Cloud Computing

Private, Public and Hybrid Clouds

Hi all, Private, Public and Hybrid Clouds I'm now testing OpenStack; Home OpenStack Open Source Cloud Computing Software -Infrastructure as a Service (IaaS) -Platform as a Service (PaaS) -Software as a Service (SaaS) It is an Open Source software. I'm interested to know whether... (0 Replies)
Discussion started by: satimis
0 Replies

7. UNIX for Dummies Questions & Answers

Public and Private Key generation for scp

Hi, What tool is used to generate public and private keys for SCP? Do you have an example script that generates these keys, puts them in files and then another example script that references them from SCP? Thanks, (9 Replies)
Discussion started by: Astrocloud
9 Replies

8. Shell Programming and Scripting

Rsa public private key matching

Hi All, I have a requirement where i need to check if an rsa public key corresponds to a private key and hence return success or failure. Currently i am using the command diff <( ssh-keygen -y -e -f "$PRIVKEY" ) <( ssh-keygen -y -e -f "$PUBLICKEY" ) and its solving my purpose. This is in... (1 Reply)
Discussion started by: mritusmoi
1 Replies

9. UNIX for Advanced & Expert Users

Private and public key encryption

Hi, we have private and public key, encrypt file using public and want to decrypt using private key. can you please advise below commands are correct or other remedy if unix have? encrypt -a arcfour -k publickey.asc -i TESTFILE.csv -o TESTFILE00.csv decrypt -a arcfour -k privatekey.asc... (2 Replies)
Discussion started by: rizwan.shaukat
2 Replies

10. UNIX for Advanced & Expert Users

Encryption command required for public /private

Hi, i generate private and public key using below command. ssh-keygen -t rsa can you please share command for encryption and decryption file using above generated keys. Regards, (4 Replies)
Discussion started by: rizwan.shaukat
4 Replies
IP-NEIGHBOUR(8) 						       Linux							   IP-NEIGHBOUR(8)

NAME
ip-neighbour - neighbour/arp tables management. SYNOPSIS
ip [ OPTIONS ] neigh { COMMAND | help } ip neigh { add | del | change | replace } { ADDR [ lladdr LLADDR ] [ nud STATE ] | proxy ADDR } [ dev DEV ] ip neigh { show | flush } [ proxy ] [ to PREFIX ] [ dev DEV ] [ nud STATE ] [ vrf NAME ] STATE := { permanent | noarp | stale | reachable | none | incomplete | delay | probe | failed } DESCRIPTION
The ip neigh command manipulates neighbour objects that establish bindings between protocol addresses and link layer addresses for hosts sharing the same link. Neighbour entries are organized into tables. The IPv4 neighbour table is also known by another name - the ARP ta- ble. The corresponding commands display neighbour bindings and their properties, add new neighbour entries and delete old ones. ip neighbour add add a new neighbour entry ip neighbour change change an existing entry ip neighbour replace add a new entry or change an existing one These commands create new neighbour records or update existing ones. to ADDRESS (default) the protocol address of the neighbour. It is either an IPv4 or IPv6 address. dev NAME the interface to which this neighbour is attached. lladdr LLADDRESS the link layer address of the neighbour. LLADDRESS can also be null. nud STATE the state of the neighbour entry. nud is an abbreviation for 'Neighbour Unreachability Detection'. The state can take one of the following values: permanent the neighbour entry is valid forever and can be only be removed administratively. noarp the neighbour entry is valid. No attempts to validate this entry will be made but it can be removed when its lifetime expires. reachable the neighbour entry is valid until the reachability timeout expires. stale the neighbour entry is valid but suspicious. This option to ip neigh does not change the neighbour state if it was valid and the address is not changed by this command. none this is a pseudo state used when initially creating a neighbour entry or after trying to remove it before it becomes free to do so. incomplete the neighbour entry has not (yet) been validated/resolved. delay neighbor entry validation is currently delayed. probe neighbor is being probed. failed max number of probes exceeded without success, neighbor validation has ultimately failed. ip neighbour delete delete a neighbour entry The arguments are the same as with ip neigh add, except that lladdr and nud are ignored. Warning: Attempts to delete or manually change a noarp entry created by the kernel may result in unpredictable behaviour. Particu- larly, the kernel may try to resolve this address even on a NOARP interface or if the address is multicast or broadcast. ip neighbour show list neighbour entries to ADDRESS (default) the prefix selecting the neighbours to list. dev NAME only list the neighbours attached to this device. vrf NAME only list the neighbours for given VRF. proxy list neighbour proxies. unused only list neighbours which are not currently in use. nud STATE only list neighbour entries in this state. NUD_STATE takes values listed below or the special value all which means all states. This option may occur more than once. If this option is absent, ip lists all entries except for none and noarp. ip neighbour flush flush neighbour entries This command has the same arguments as show. The differences are that it does not run when no arguments are given, and that the default neighbour states to be flushed do not include permanent and noarp. With the -statistics option, the command becomes verbose. It prints out the number of deleted neighbours and the number of rounds made to flush the neighbour table. If the option is given twice, ip neigh flush also dumps all the deleted neighbours. EXAMPLES
ip neighbour Shows the current neighbour table in kernel. ip neigh flush dev eth0 Removes entries in the neighbour table on device eth0. SEE ALSO
ip(8) AUTHOR
Original Manpage by Michail Litvak <mci@owl.openwall.com> iproute2 20 Dec 2011 IP-NEIGHBOUR(8)
All times are GMT -4. The time now is 02:22 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy