Linux Ip ve Network İşlemleri
DNS değştirme, sabit IP kullanmak gibi işlemlerin Linux üzerinde gerçekleştirilmesi
Ethernet Kartları ve Özelliklerinin Detaysız Tespiti
Ethernet Kartları ve Özelliklerinin Detaylı Tespiti
Sistem Ipsi Hakkında Bilgi
# or
ip addr
# or
ip a
İp Ayarlarının Yapıldığı Dosyaya Girmek İçin
/etc/network/interfaces içinde Normal Olması Gereken
allow-hotplug eth0
iface eth0 inet dhcp
Dinamik IP Vermek İçin
allow-hotplug eth0
iface eth0 inet dhcp
iface lo inet loopback
auto eth0
iface eth0 inet dhcp
auto eth1
iface eth1 inet dhcp
auto eth2
iface eth2 inet dhcp
auto ath0
iface ath0 inet dhcp
auto wlan0
iface wlan0 inet dhcp
Static IP Vermek İçin
iface lo inet loopback
auto eth0
iface eth0 inet static
address 208.88.34.106
netmask 255.255.255.248
broadcast 208.88.34.111
network 208.88.34.104
gateway 208.88.34.110
dns-nameservers 127.0.0.1 8.8.4.4 8.8.8.8 209.244.0.3
iface lo inet loopback
auto eth0
iface eth0 inet static
address 192.168.10.5
netmask 255.255.255.0
network 192.168.10.0
broadcast 192.168.10.255
gateway 192.168.10.1
dns-nameservers 127.0.0.1 8.8.4.4 8.8.8.8 209.244.0.3
Dinamic İp Örneği
Static İP Örneği
- auto eth0 – enable at startup the eth0 interface
- iface eth0 inet static- consider that iface eth0 comes from interface eth0, inet tells you that the network configuration is IPv4 and static that your network interface has static ip adresses.
- address – the network’s IP address
- netmask – the network’s mask address
- network – the network’s address
- broadcast – the broadcast address
- gateway – the gateway address
Manuel olarak yapılandırıyorsanız, bunun gibi bir şey varsayılan ağ geçidini ayarlayacaktır (network, broadcast ve gateway isteğe bağlıdır):
iface eth0 inet static
address 192.0.2.7/24
gateway 192.0.2.254
Ddeğişikliğin etkili olması için networking
ve resolvconf
her ikisini de yeniden başlatın. Olmazsa, makineyi yeniden başlatmanız gerekir.
systemctl restart resolvconf
Var Olan Network Arayüzleri (eth) Listesini Almak İçin
veya
Biraz daha detaylı liste için
Ethernet Kartını Kapatmak ve Açmak İçin
ifdown eth1
ifconfig eth0 up
Ethernet Kartına IP Atamak İçin
#veya
ifconfig eth0 192.168.2.2 netmask 255.255.255.0 broadcast 192.168.2.255
Bağlantıları Güncellemek
sudo /etc/init.d/networking stop
sudo /etc/init.d/networking restart
DNS Ayarlarının Yapıldığı Dosyaya Girmek İçin
DNS Ayarlarını Değiştirmek
# I add this
nameserver 8.8.8.8
nameserver 8.8.4.4
Bu ayarların her açtığınızda değişmemesi için:
#Tekrar güncellenebilir hale getirmek için
#chattr -i /etc/resolv.conf
Şurada daha detaylı işlemler var.
Rout Tablosunu Göstermek
netstat - Display connections, routing tables, stats etc
Eğer netstat sisteminizde yoksa yüklemek için:
- List externally connected processes: netstat -punta
- -a: Show both listening and non-listening sockets.
- -p: Show PID of process owning socket
- -u: Show UDP
- -t: Show TCP
- -n: Show IP addresses only. Don't resolve host names
- -g: Show multi-cast group membership info
- -c: Continuous mode - update info every second
- -v: Verbose
- -e: Extended information
- -o: show network timer information
- List all connected processes: netstat -nap
- Show network statistics: netstat -s
- Display routing table info: netstat -rn
Bir başka komut
Display interface statistics: netstat -i
Ağdaki Tüm IP Listesini Almak:
Bu işlem aynı zamanda çakışan ip adreslerinide gösterir.
Bir IP üzerindeki Açık Portları bulmak için şuraya bakabilirsiniz.
Konfigrasyon Komutları Listesi
packages | popcon | size | type | description |
---|---|---|---|---|
ifupdown |
V:627, I:995 | 217 | config::ifupdown | standardized tool to bring up and down the network (Debian specific) |
ifplugd |
V:4, I:21 | 209 | , , | manage the wired network automatically |
ifupdown-extra |
V:0, I:1 | 100 | , , | network testing script to enhance "ifupdown " package |
ifmetric |
V:0, I:1 | 37 | , , | set routing metrics for a network interface |
guessnet |
V:0, I:0 | 422 | , , | mapping script to enhance "ifupdown " package via "/etc/network/interfaces " file |
ifscheme |
V:0, I:0 | 58 | , , | mapping scripts to enhance "ifupdown " package |
network-manager |
V:380, I:471 | 11584 | config::NM | NetworkManager (daemon): manage the network automatically |
network-manager-gnome |
V:159, I:408 | 5921 | , , | NetworkManager (GNOME frontend) |
wicd |
I:31 | 35 | config::wicd | wired and wireless network manager (metapackage) |
wicd-cli |
V:0, I:1 | 59 | , , | wired and wireless network manager (command-line client) |
wicd-curses |
V:0, I:4 | 175 | , , | wired and wireless network manager (Curses client) |
wicd-daemon |
V:26, I:35 | 962 | , , | wired and wireless network manager (daemon) |
wicd-gtk |
V:21, I:33 | 574 | , , | wired and wireless network manager (GTK+ client) |
iptables |
V:270, I:995 | 2569 | config::Netfilter | administration tools for packet filtering and NAT (Netfilter) |
iproute2 |
V:671, I:871 | 2585 | config::iproute2 | iproute2, IPv6 and other advanced network configuration: ip(8), tc(8), etc |
ifrename |
V:1, I:2 | 125 | , , | rename network interfaces based on various static criteria: ifrename(8) |
ethtool |
V:110, I:259 | 393 | , , | display or change Ethernet device settings |
iputils-ping |
V:254, I:996 | 100 | test::iproute2 | test network reachability of a remote host by hostname or IP address (iproute2) |
iputils-arping |
V:26, I:392 | 51 | , , | test network reachability of a remote host specified by the ARP address |
iputils-tracepath |
V:5, I:102 | 68 | , , | trace the network path to a remote host |
net-tools |
V:299, I:744 | 979 | config::net-tools | NET-3 networking toolkit (net-tools, IPv4 network configuration): ifconfig(8) etc. |
inetutils-ping |
V:0, I:2 | 350 | test::net-tools | test network reachability of a remote host by hostname or IP address (legacy, GNU) |
arping |
V:1, I:28 | 73 | , , | test network reachability of a remote host specified by the ARP address (legacy) |
traceroute |
V:63, I:960 | 154 | , , | trace the network path to a remote host (legacy, console) |
isc-dhcp-client |
V:255, I:973 | 673 | config::low-level | DHCP client |
wpasupplicant |
V:310, I:539 | 3352 | , , | client support for WPA and WPA2 (IEEE 802.11i) |
wpagui |
V:0, I:3 | 786 | , , | Qt GUI client for wpa_supplicant |
wireless-tools |
V:192, I:274 | 297 | , , | tools for manipulating Linux Wireless Extensions |
ppp |
V:264, I:510 | 1020 | , , | PPP/PPPoE connection with chat |
pppoeconf |
V:0, I:9 | 290 | config::helper | configuration helper for PPPoE connection |
pppconfig |
V:1, I:2 | 805 | , , | configuration helper for PPP connection with chat |
wvdial |
V:0, I:6 | 249 | , , | configuration helper for PPP connection with wvdial and ppp |
mtr-tiny |
V:6, I:55 | 152 | test::low-level | trace the network path to a remote host (curses) |
mtr |
V:5, I:40 | 206 | , , | trace the network path to a remote host (curses and GTK+) |
gnome-nettool |
V:3, I:91 | 2105 | , , | tools for common network information operations (GNOME) |
nmap |
V:36, I:292 | 4510 | , , | network mapper / port scanner (Nmap, console) |
zenmap |
V:4, I:12 | 2939 | , , | network mapper / port scanner (GTK+) |
tcpdump |
V:21, I:200 | 1192 | , , | network traffic analyzer (Tcpdump, console) |
wireshark |
I:61 | 69 | , , | network traffic analyzer (Wireshark, GTK+) |
tshark |
V:3, I:35 | 398 | , , | network traffic analyzer (console) |
tcptrace |
V:0, I:1 | 392 | , , | produce a summarization of the connections from tcpdump output |
snort |
V:0, I:1 | 1920 | , , | flexible network intrusion detection system (Snort) |
ntopng |
V:1, I:2 | 950 | , , | display network usage in web browser |
dnsutils |
V:71, I:591 | 719 | , , | network clients provided with BIND: nslookup(8), nsupdate(8), dig(8) |
dlint |
V:0, I:12 | 53 | , , | check DNS zone information using nameserver lookups |
dnstracer |
V:0, I:2 | 56 | , , | trace a chain of DNS servers to the source |
Kaynaklar
- http://www.cyberciti.biz/faq/setting-up-an-network-interfaces-file/
- http://askubuntu.com/questions/180925/how-to-setup-static-ip-in-ubuntu-server-12-04
- http://www.yolinux.com/TUTORIALS/LinuxTutorialNetworking.html
- https://wiki.debian.org/NetworkConfiguration
- http://www.thegeekstuff.com/2009/03/ifconfig-7-examples-to-configure-network-interface/
- https://www.debian.org/doc/manuals/debian-reference/ch05.en.html
- https://linuxconfig.org/how-to-set-a-static-ip-address-on-debian-10-buster
Apache PHP MYSQL Kurmak
LAMP (Linux Apache Mysql PHP) kurulup bazı ayarların yapılması
26,222 okuma,
Java Kurulumu
Sun Java yüklemek, yeni adıyla oracle Java yüklemenin yolları
25,710 okuma, 18/12/2014