lshw –C networkip
ip link showip –s linkpingnmaptraceroutessnetstat/etc/hostname contains the system hostname
hostnamectl command
sudo hostnamectl set-hostname <new_ hostname>/etc/hosts contains a list of IP addresses and their corresponding hostnames
c:\windows\system32\drivers\etc\hosts on Windows/etc/hosts on Unix and MacOSip route to view the current routing tableip route [add | delete] <route>Debian and Ubuntu come with UFW (simplified firewall management utility) by default. UFW profiles are stored in /etc/ufw/applications.d/. You must use root (sudo) or a privileged user to make modifications to the firewall settings.
# UFW utility examples: ufw allow 22/tcp ufw allow profile ufw app list ufw app info ufw enable ufw disable
# UFW utility examples:
ufw allow 22/tcp
ufw allow profile
ufw app list
ufw app info
ufw enable
ufw disableDHCP stands for Dynamic Host Configuration Protocol. A DHCP server can send the following configuration information to clients for automatic configuration:
Please note that it is up to the DHCP client to configure the local settings. The DHCP server has no control over and cannot enforce which one of the provided configurations is used by the client.
DHCPdiscover packet to the networkDHCPoffer packetDHCPrequest to serverDHCPACKisc-dhcp-server
apt-get install isc-dhcp-serversudo service isc-dhcp-server.service [start|stop|enable|status]sudo systemctl [start|stop|enable|status] isc-dhcp-server.service/etc/default/isc-dhcp-server
INTERFACES=“ens34 ens38”/etc/dhcp/dhcpd.conf67/UDP through the firewall: sudo ufw allow 67/udpExample configuration file:
default-lease-time 600;
max-lease-time 7200; # Global declarations apply to all subnets
subnet 10.1.1.0 netmask 255.255.255.0 {
range 10.1.1.3 10.1.1.254; # IP Range available to be assigned to clients
option domain-name-servers 10.1.1.1, 8.8.8.8; # DNS Servers
option routers 10.1.1.1;
option domain-search “testdomain.mytld";
}
subnet 192.168.0.0 netmask 255.255.0.0 { # a known network, but not used by
} # the DHCP server
host printer {
hardware ethernet 00:16:d3:b7:8f:86; # Example of a reserved IP address
fixed-address 10.1.1.100; # filtered by MAC Address
}
host web-server {
hardware ethernet 00:17:a4:c2:44:22;
fixed-address 10.1.1.200;
}default-lease-time 600;
max-lease-time 7200; # Global declarations apply to all subnets
subnet 10.1.1.0 netmask 255.255.255.0 {
range 10.1.1.3 10.1.1.254; # IP Range available to be assigned to clients
option domain-name-servers 10.1.1.1, 8.8.8.8; # DNS Servers
option routers 10.1.1.1;
option domain-search “testdomain.mytld";
}
subnet 192.168.0.0 netmask 255.255.0.0 { # a known network, but not used by
} # the DHCP server
host printer {
hardware ethernet 00:16:d3:b7:8f:86; # Example of a reserved IP address
fixed-address 10.1.1.100; # filtered by MAC Address
}
host web-server {
hardware ethernet 00:17:a4:c2:44:22;
fixed-address 10.1.1.200;
}ufwnetstatssnmapethtool (legacy utilities)pingtracerouteiptables (back-end firewall and packet routing system)hostnamectl/etc/hostname/etc/hosts/etc/ufw/applications.d/etc/default/isc-dhcp-server/etc/dhcp/dhcpd.conf