the IP protocol and IP addresses

learn more… | top users | synonyms

6
votes
3answers
3k views

Can't access select https sites on Linux over PPPoE

My internet connection used to be a direct LAN connection to my provider. Back then, everything would load fine on both Windows and Ubuntu (dual boot). However, a while ago they started needing me to ...
44
votes
13answers
30k views

How can I get my external IP address in bash?

I need to find my external IP address from a bash script. At the moment I use this function: myip () { lwp-request -o text checkip.dyndns.org | awk '{ print $NF }' } But it depends on ...
15
votes
6answers
11k views

How to get my own IP address and save it to a variable in a shell script?

How can I get my own IP address and save it to a variable in a shell script?
3
votes
1answer
6k views

Set Static IP in CentOS 6.4?

Most guides seem to revolve around modifying ifcfg-eth0, which doesn't exist on my system.. [root@Azaz07]# vi /etc/sysconfig/network-scripts/ifcfg-eth0 [root@Azaz07]# ls ...
3
votes
1answer
601 views

Route SSH to host through interface

Is it possible to route all outgoing requests for SSH (port 22) to mydynamicdns.afraid.org via wlan0 instead of eth0 when both are connected? Since my IP is dynamic, I would like to use a name ...
16
votes
2answers
1k views

Is there an easy way to programmatically extract IP address?

Is there an easy way to programmatically extract IP address, without tedious parsing of ifconfig? I would not mind simple command output processing using sed to do it but not processing multiline ...
4
votes
3answers
3k views

Send duplicate packets over two Internet connections

I need to duplicate an RTP stream over two different (non-reliable) Internet connections. On the receiver side, I will probably run a custom program that will use a buffer and rebuild the stream ...
5
votes
3answers
3k views

How to filter IPv4 and IPv6 addresses?

echo "1.1.1.1" | awk '/[0-9]*\.[0-9]*\.[0-9]*\.[0-9]*/ {print $1}' How can I filter IPv4 addresses in a script, and how can I filter IPv6 addresses. I mean more precisely then this so the oneliner ...
3
votes
3answers
7k views

Find out network traffic per IP

We have one central server which functions as an internet gateway. This server is connected to the internet, and using iptables we forward traffic and share the internet connection among all computers ...
38
votes
2answers
4k views

How does SSH connection survive a network restart?

From a Linux SSH shell, type /etc/init.d/network restart to restart the network service. I expect my SSH connection to die since the network service goes down. But it doesn't. Very cool. But how does ...
5
votes
2answers
2k views

Routing for multiple uplinks/providers

I have a PC with two internet connections. The first one is an Ethernet interface to connect to my local network and access internet via my router. The second one use a GSM modem to connect with ppp. ...
4
votes
2answers
2k views

How to know if a network interface is tap, tun, bridge or physical?

As far as i know, there are 4 main types of network interfaces in linux: tun, tap, bridge and physical. When i'm doing sys admin on machines running KVM, i usually come accross tap, bridge and ...
9
votes
1answer
314 views

Send a packet over the network even when its target is the local host

Under Linux if you send a packet to the address of one of its network interfaces, this packet is routed internally, it is never sent over the network. That's the right thing in 99.99% of the cases. ...
5
votes
3answers
1k views

Difference between 'ifconfig' and 'ip' commands

I read some articles/tutorials on 'ifconfig' command, most of them included a common statement - "ifconfig is deprecated by ip command" and suggested to learn ip command. But none of them ...
4
votes
1answer
8k views

What is kernel ip forwarding?

I have seen on many blogs, using this command to enable IP forwarding while using many network security/sniffing tools on linux echo 1 > /proc/sys/net/ipv4/ip_forward Can anyone explain me in ...
4
votes
2answers
2k views

Can't ping broadcast

We're running four computers connected to a hub (yes a hub not a switch) on Fedora 13. They were installed using images from a colleague that has recently left us to go back to school, they may have ...
4
votes
1answer
2k views

multigateway routing for specific src port

I have two gateway to access internet, somehow I want to load balancing it, so far its working, but some connection or service need persistent gateway IP to be used, so the client should never change ...
3
votes
4answers
6k views

IP of localhost

How does a Linux instance determine its IP address? That is, not the 127.0.0.1. Is this stored in file or does ifconfig somehow calculate it at every invocation? I managed to solve it just to show ...
11
votes
2answers
2k views

IP to Country console command

Is there a console command that takes an IP address as an input and shows its geographical information like city, country, ISP, etc.?
4
votes
1answer
137 views

Why is this static route not taking effect?

Original Question I am running Ubuntu and network manager. I have two different interfaces, eth0 and eth1. Network manager has (as far as I can tell) correctly added this manual route: ~$ ip route ...
4
votes
2answers
910 views

Discover MTU between me and destination IP

In a case I can use only UDP and ICMP protocols, how can I discover, in bytes, the path MTU for packet transfer from my computer to a destination IP?
1
vote
3answers
105 views

Enabling IP forwarding at kernel compile time

I am compiling a kernel for a router. I know a way to enable IP forwarding in an existing Linux system. At compile time, CONFIG_IP_FORWARD is said to do the same task. I am configuring version ...
0
votes
1answer
250 views

Unable to get embedded device to ping anything on the network

I have an embedded device, built using buildroot, kernel version 3.6.11 running busybox. The kernel is built with completely default options. I have configured the device according to what the network ...