## Linux ### Pohyb po disku * ls , ls -1 , ls -al * cd, cd -, cd ~, pwd * mkdir | mkdir -p * touch | chmod | chown * man | info (man stranky k prikazum + knihovnam) ### Uzivatele a dalsi.. * w, who, id * su, sudo * usermod, passwd * adduser, deluser, addgroup, delgroup ### Sitovani * route, ifconfig * ip, ip link, ip address, ip route * iptables * ping, traceroute * whois, host, dig * netstat, netstat -tupln * ss, ss -l -t -n, ss -4 state listening * lsof -i :port, lsof -p pid * arp * tcpdump, tcpdump -i eth0, tcpdump host 1.1.1.1, tcpdump src 1.1.1.1, tcpdump port 3389 * nmap, nmap -sn 10.0.0.0/24, sudo nmap 10.0.0.50 -O * ssh, telnet * nc * curl, wget ### System * top, htop * free ### Prace se soubory * find * less * grep | grep -R * cat, sort, uniq, cut * nano, vim * sed, awk * df, du ## Windows ****** cmd * ipconfig * ipconfig /all * netstat * ping * tracert * ftp * route * route PRINT * route ADD 172.16.0.5 MASK 255.240.0.0 172.16.0.1 METRIC 5 IF 2 * route DELETE 172.16.0.5 * netsh interface ipv4 show interfaces * netsh interface ipv4 show config * netsh interface ipv4 set address name="..." source=static 172.16.0.4 255.240.0.0 172.16.0.1 * netsh interface ipv4 add address name="..." 172.16.0.4 255.240.0.0 SkipAsSource=True * netsh interface ipv4 set address name="Ethernet" source=dhcp * nslookup * ssh ****** PowerShell: * Get-NetIPAddress * Get-NetIPAddress | ft IPAddress, InterfaceAlias, SkipAsSource [, PrefixOrigin, ...] * New-NetIPAddress –IPAddress 172.16.0.4 –PrefixLength 12 –InterfaceAlias "Ethernet" –SkipAsSource $True * Test-NetConnection -ComputerName "www.seznam.cz" * Test-NetConnection "www.google.com" -Port 80 * Test-NetConnection "www.google.com" -Port 8077 * Test-NetConnection "www.google.com" -traceroute * Get-NetTCPConnection * Get-NetTCPConnection -State Listen * Get-DnsClient * Clear-DnsClientCache * Resolve-DnsName -Name "www.google.com" -Type AAAA * Resolve-DnsName -Name "seznam.cz" -Type MX