Posts with the tag network setup
Setting up my Raspberry Pi for Raspberry Pi colocation by PCextreme.
# Change the root password: passwd # Full system upgrade: pacman -Syyu ## Extend the root partition as explained on http://goo.gl/kFOnW fdisk -c /dev/mmcblk0 # p d-2 n-p-2 w # on a newer Arch...
Getting IPv4 and IPv6 addresses of your local machine on Mac OS X 10.8 Mountain Lion is quite easy. Here is how it works:
IF='en0' # ← restrict to wired connection or do IF="" to get all # Get local IPv4 addresses (without...
Product Name: JetStream™ 8-Port Gigabit L2 Lite Managed Switch with 2 SFP Slots
Product Code: TL-SG3210
This is a cheap 8-port Gigabit switch if you consider its capabilities. It can be configured in many ways via the web interface or (in an automated way) via a CLI interface (Telnet / SSH like)....
This post describes hot to use dnsmasq as a local DNS server for faster caching and to resolve domain names in your private address space.
Installing dnsmasq is easy when you have Homebrew installed on your Mac:
brew update && brew install dnsmasq
And follow Homebrew's hints on...
A quite new and powerful alternative to the TP-Link TL-WR1043ND running OpenWrt is the Buffalo WZR-HP-AG300H.
About the Hardware
The Buffalo WZR-HP-AG300H contains a powerful set of hardware, maybe the strongest for SOHO routers currently on the market:
|Atheros AR7161@680MHz (MIPS)||128MB||32MB||4+1 using an Atheros AR8316 Gigabit Ethernet switch||2x -...|
This is a nice thing to do if you are in a hotel and want to redistribute a single WiFi connection to other computers.
The setup works as follows: The WiFi with the SSID
Telekom is the one being provided in the hotel. Here we can connect to it without encryption,...
About the Hardware
The TP-Link TL-WR1043ND contains a great set of hardware for its price:
|Atheros AR9132@400MHz (MIPS)||32MB||8MB||4+1||Yes||1 x 2.0||Yes||Yes|
Please refer to http://wiki.openwrt.org/toh/tp-link/tl-wr1043nd#hardware for further details on the hardware.
My hardware version is (DE)v1.0.
Via the System Preferences: Network pane
- Go to System Preferences → Network.
- Click on Ethernet (or AirPort)
- Click on the Configuration Wheel → Duplicate Service...
You can now configure each instance with different settings, and you're done.
On the Terminal
If you just need to quickly assign an IP/subnet alias to an interface, you can do...
In advanced computing you may encounter situations where you want to bind multiple IP addresses on one physical network interface. This post describes how to do it with Ubuntu Linux (should work with Debian too).
This method is temporary only as the additional IP address will be gone after...
Suppose we have the following setup:
- A Computer with Ubuntu installed and two physical network interfaces (might also be virtual, but that's advanced)
- We have an internet connection on this computer set up and working. Internet traffic goes out (and in) on the network interface
- We want to create a private subnet
denyhost can help keep out unwanted guests from your ssh server.
# # /etc/hosts.deny # ALL: ALL: DENY # End of file
# # /etc/hosts.allow # sshd: ALL EXCEPT /etc/hosts.evil # End of file
sudo aptitude install python-ipcalc
the needed module is /usr/share/pyshared/ipcalc.py
sudo aptitude install sipcalc
example usage: http://www.cyberciti.biz/faq/linux-subnet-calculator-cidr/
sudo aptitude install ipcalc
gip - IP calculator for gnome
sudo aptitude install gip
There exist a comparison of ethtool in linux with the equivalents in solaris command-by-command... It's great!
not available anymore... but here is an archived version: https://web.archive.org/web/20120918092833/http://hub.opensolaris.org/bin/view/Project+brussels/ethtool-dladm-comparison...
Edit the configuration file of the SSH daemon:
sudo gedit /etc/ssh/sshd_config
Change the line containing
PermitRootLogin yes to
PermitRootLogin no , save the file and restart the SSH server.
sudo /etc/init.d/ssh restart
My network interface is a Intel PRO/1000 PT Dual-Port-Server-Adapter (PCIe x4) (chipset: Intel 82571GB). It provides two physical links that I use both: One for my private subnet and one as the public interface to the public network (Internet via 100Mbit Ethernet at KHG, University of Frankfurt am Main). I...
This blog post has grown to large. Please refer to the more detailed posts on IPv6 tagged with ipv6:
DNS entries for IPv6 ready web sites
Arecord: normal domain to ip address resolution
MXrecord: email server lookup, must resolve to a server address that is resolved to an IP...
It's called MAC spoofing.
The commands do achieve it are:
- Bring down the interface and enter a new MAC address
- Bring up the interface
On Ubuntu Linux this can be achieved (for nic
eth1 and a new mac address of
00:14:11:12:34:15) like this:
sudo ifconfig eth1 down hw ether 00:14:11:12:34:15 sudo ifconfig eth1 up
If wireshark reports many wrong checksums, this can be caused by checksum calculations done by hardware which means that the wrong checksums reported by Wireshark are simply meaningless.
If you're sure, that's the problem, you may simple not care about wrong checksums:
- Turn off the checksum offloading in the network...
WOL – Wakeup Computers via LAN
to wake up the computers on the homenetwork use the following commands (execute on the router) connect to the router first:
And wake up the computer with the network interface with the MAC
00:11:24:xx:yy:zz (assuming it is in the network 192.168.1.1/24):
failback connection (routing):
advanced routing: http://lartc.org/howto/
secondary virtual interface on one physical interface: http://www.ubuntugeek.com/ubuntu-networking-configuration-using-command-line.html
default gateway: http://www.cyberciti.biz/faq/howto-debian-ubutnu-set-default-gateway-ipaddress/
static DNS with DHCP: https://help.ubuntu.com/community/StaticDnsWithDhcp and http://ubuntuforums.org/showthread.php?t=544383#2
multi homing (using two internet connections at the same time) using policy routing: http://www.debian-administration.org/article/Policy_routing
- redundant internet connections (but with default network...
When I inserted a new network card into my Linux computer, the new network interface was named with an incremented number at the end. I didn't want that as my network setup (firewall rules etc.) were set up for the former name. So I had to change the configuration to rename...
NetworkManager has a DBUS API, so other applications can use DBUS to communicate with it and change its settings. I found three different ways to do this on the command line using a CLI (command line interface):
As of 2010-12-18 the most actively maintained project is nmcli: http://fedoraproject.org/wiki/Features/NetworkManagerCmdline.
run netstat like this:
sudo netstat -lntup
and you get an output like this:
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State ...
Servers: 18.104.22.168 and 22.214.171.124
(Fast alternative: google dns, servers: 126.96.36.199 and 188.8.131.52. I use the google DNS servers when going online via my mobile phone using 3G network. It is by far faster than the DNS server of the network provider.)
Perl client to update the openDNS IP (if...
eth0 Link encap:Ethernet HWaddr 00:70:40:42:8A:60 inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0 UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU:1500 Metric:1 RX packets:160889...
Analyse the situation by taking a look at the configuration and stats:
ifconfig -a netstat -s
Check if your gateway and DNS servers are reachable. If only one of the dns servers is not reachable edit /etc/resolv.conf manually (will be overwritten by next network change).
To set the network interface eth1 to 100MBits...
install needed packages:
sudo aptitude install dnsmasq ipmasq dhcp3-server
auto lo iface lo inet loopback auto eth0 auto eth1 iface eth1 inet static address 192.168.0.1 netmask 255.255.255.0 broadcast 192.168.0.255 wireless-mode master wireless-essid HDFredistribution
Change in /etc/default/dhcp3-server the line
/etc/dhcp3/dhcpd.conf comment out the...
sudo aptitude install network-manager-openvpn network-manager-pptp network-manager-vpnc
The most useful three commands are:
ip link list ip address show ip route show
sudo aptitude install ddclient
Now configure the program:
sudo gedit /etc/ddclient.conf
Enter your DynDNS account data and computer setup:
pid=/var/run/ddclient.pid protocol=dyndns2 use=if, if=eth2 # the mode and network interface # DynDNS account: server=members.dyndns.org login=philippk password='sdf1dpw' philippk.ath.cx
And set ddclient to run automatically on startup:
sudo gedit /etc/default/ddclient
Set the mode of ddclient...
The installation of the port knocking daemon is quite simple:
sudo apt-get install knockd
To start the knockd daemon automatically: uncomment
Edit the config file
[options] logfile = /var/log/knockd.log [openSSH] sequence = <span...
Install the package ethtool:
sudo aptitude install ethtool
Add the ethtool command to your nic using its configuration in
/etc/network/interfaces (last line):
iface eth0 inet static address 192.168.100.90 netmask 255.255.255.0 gateway 192.168.100.1 pre-down /usr/sbin/ethtool -s eth0 wol...
if you want to search the domains / workgroups / shares of you MS Windows neighbourhood then do it using smb4k.
sudo apt-get install smb4k
set up your rules:
1.As 1st rule (INPUT 1) allow all traffic on loopback adapter lo (so your programs on localhost can communicate if all other traffic is blocked later)
sudo iptables -I INPUT 1 -i lo -j ACCEPT
2.Allow incoming traffic on port 80:
sudo iptables -A...
Setup of WPA encrypted WiFi using a text file based configuration
You find the important information on how to set it up in the documentation of wpasupplicant:
For example if you want to connect to a WLAN named "WLAN-AF6432" with WPA security, you first have to get the encryption...
You might want to remove the network manager if you want to set up your network interfaces using the configuration file
/etc/network/interfaces (in this case you just don't need Network Manager).
sudo aptitude remove network-manager
do not remove:!!!: ubuntu-desktop but do remove: knetworkmanager, network-manager-gnome und network-manager-kde...