Skip to main content

62 commands in Ubuntu



1. **ifconfig**: Display network interface information.
   Example: `ifconfig`

2. **ip addr**: Show IP addresses of network interfaces.
   Example: `ip addr show`

3. **ip route**: Display routing table information.
   Example: `ip route show`

4. **ping**: Test network connectivity.
   Example: `ping google.com`

5. **traceroute**: Trace the route to a destination.
   Example: `traceroute google.com`

6. **netstat**: Display network statistics and connections.
   Example: `netstat -an`

7. **ss**: Display socket statistics.
   Example: `ss -tuln`

8. **nslookup**: Perform DNS lookups.
   Example: `nslookup google.com`

9. **dig**: Another DNS lookup utility.
   Example: `dig google.com`

10. **route**: Manage the IP routing table.
    Example: `route -n`

11. **wget**: Download files from the web.
    Example: `wget https://example.com/file.txt`

12. **curl**: Transfer data to/from a server.
    Example: `curl https://example.com`

13. **ssh**: Securely connect to a remote host.
    Example: `ssh username@remote_host`

14. **scp**: Securely copy files between hosts.
    Example: `scp file.txt username@remote_host:/path/to/destination`

15. **telnet**: Connect to a remote host using the Telnet protocol.
    Example: `telnet remote_host`

16. **ftp**: Interact with remote FTP servers.
    Example: `ftp ftp.example.com`

17. **ifup**: Bring a network interface up.
    Example: `sudo ifup eth0`

18. **ifdown**: Bring a network interface down.
    Example: `sudo ifdown eth0`

19. **iwconfig**: Configure wireless network interfaces.
    Example: `iwconfig wlan0`

20. **hostname**: Display or set the system's hostname.
    Example: `hostname`

21. **ifstat**: Display interface statistics.
    Example: `ifstat`

22. **iftop**: Display bandwidth usage on an interface.
    Example: `iftop`

23. **arp**: Display or manipulate the ARP cache.
    Example: `arp -a`

24. **netcat (nc)**: Read and write data across network connections.
    Example: `nc -vz google.com 80`

25. **nmap**: Network discovery and security auditing.
    Example: `nmap -sP 192.168.1.0/24`

26. **route add**: Add a new route to the routing table.
    Example: `sudo route add -net 10.0.0.0/24 gw 192.168.1.1`

27. **route del**: Delete a route from the routing table.
    Example: `sudo route del default`

28. **iptables**: Configure firewall rules.
    Example: `sudo iptables -A INPUT -p tcp --dport 22 -j ACCEPT`

29. **ufw**: Uncomplicated Firewall management.
    Example: `sudo ufw enable`

30. **netcat (nc) listener**: Create a listening socket using netcat.
    Example: `nc -l -p 12345`

31. **netcat (nc) client**: Connect to a listening socket using netcat.
    Example: `nc remote_host 12345`

32. **lsof**: List open files and network connections.
    Example: `lsof -i`

33. **ipset**: Manage IP sets for firewall rules.
    Example: `sudo ipset create myset hash:ip`

34. **iftop**: Monitor network bandwidth usage in real-time.
    Example: `sudo iftop -i eth0`

35. **tcpdump**: Capture and analyze network packets.
    Example: `sudo tcpdump -i eth0 -n port 80`

36. **ifenslave**: Create a bonded interface (NIC teaming).
    Example: `sudo ifenslave bond0 eth0 eth1`

37. **mtr**: Network diagnostic tool that combines traceroute and ping.
    Example: `mtr google.com`

38. **ipcalc**: Calculate IP addresses, netmasks, and subnets.
    Example: `ipcalc 192.168.1.0/24`

39. **netplan**: Configure network settings using YAML files.
    Example: `/etc/netplan/01-netcfg.yaml`

40. **dhclient**: Obtain an IP address from a DHCP server.
    Example: `sudo dhclient eth0`

41. **host**: DNS lookup utility.
    Example: `host google.com`

42. **hostnamectl**: Control system hostname and related settings.
    Example: `hostnamectl set-hostname myhost`

43. **arping**: Send ARP requests to a host.
    Example: `arping -c 5 192.168.1.1`

44. **ip neigh**: Display ARP cache entries.
    Example: `ip neigh show`

45. **ip tunnel**: Manage IP tunnels.
    Example: `sudo ip tunnel add mytunnel mode gre local 192.168.1.1 remote 192.168.2.1`

46. **ifrename**: Rename network interfaces.
    Example: `sudo ifrename eth0 myeth0`

47. **route -A inet6**: Manage IPv6 routing table.
    Example: `sudo route -A inet6 -n`

48. **dhclient6**: Obtain IPv6 address from DHCPv6 server.
    Example: `sudo dhclient6 eth0`

49. **netstat -s**: Display network statistics by protocol.
    Example: `netstat -s`

50. **ipset**: Manage IP sets for firewall rules.
    Example: `sudo ipset create myset hash:ip`

51. **vnstat**: Network traffic monitoring tool.
    Example: `vnstat -l`

52. **ethtool**: Display or change Ethernet device settings.
    Example: `ethtool eth0`

53. **iw**: Configure wireless devices and their settings.
    Example: `iw dev wlan0 scan`

54. **hostapd**: Host Access Point Daemon for creating wireless APs.
    Example: `sudo hostapd /etc/hostapd/hostapd.conf`

55. **iwlist**: List nearby wireless networks.
    Example: `iwlist wlan0 scan`

56. **ip maddr**: Manage multicast addresses.
    Example: `ip maddr show dev eth0`

57. **dnsdomainname**: Display the system's DNS domain name.
    Example: `dnsdomainname`

58. **resolvectl**: Control the system's DNS settings.
    Example: `resolvectl status`

59. **ss -s**: Display socket statistics by protocol.
    Example: `ss -s`

60. **iftop -i**: Monitor bandwidth usage of a specific interface.
    Example: `sudo iftop -i eth0`

61. **nload**: Monitor network traffic and bandwidth usage.
    Example: `nload eth0`

62. **tcpdump -i**: Capture packets on a specific interface.
    Example: `sudo

Comments

Popular posts from this blog

Program 6: Finding Prime Numbers in a Range

  ** Program 6: Finding Prime Numbers in a Range ** ```assembly .model small .stack 100h .data     start dw 1     end dw 20 .code     main proc         mov ax, start           ; Load 'start' into AX              find_primes:         inc ax                  ; Move to the next number         cmp ax, end             ; Compare with 'end'         jg end_prog             ; Jump to end if AX > 'end'                  mov cx, ax              ; Copy AX to CX   ...

4. Write a LEX Program to convert the substring abc to ABC from the given input string.

Sure, here's a LEX program that converts the substring "abc" to "ABC" in the given input string: ```lex %{ #include <stdio.h> %} %% .*abc.*    { printf("%s", yytext); }    /* Match and print everything containing 'abc' */ .         ;                            /* Ignore other characters */ %% int main() {     yylex();     return 0; } ``` Now, let's break down the code line by line: 1. `%{` and `%}`: These are used to enclose C code that should be included in the generated C code. In this case, it includes the standard input-output library (`<stdio.h>`). 2. `.*abc.*`: This is a regular expression pattern. It matches any sequence of characters that contains the substring "abc". 3. `{ printf("%s", yytext); }`: This is the action associated with the pattern. When the pattern is matched, the `yytext` variable contains the matched te...

ktu 2019 Cse Complier programing Lab Syllabus

 1Design and implement a lexical analyzer using C language to recognize all valid tokens  in the input program. The lexical analyzer should ignore redundant spaces, tabs and  newlines. It should also ignore comments. 2. Implement a Lexical Analyzer for a given program using Lex Tool. 3. Write a lex program to display the number of lines, words and characters in an input text. 4. Write a LEX Program to convert the substring abc to ABC from the given input string. 5. Write a lex program to find out the total number of vowels and consonants from the given  input string. 6. Generate a YACC specification to recognize a valid arithmetic expression that uses  operators +, – , *,/ and parenthesis. 7. Generate a YACC specification to recognize a valid identifier which starts with a letter  followed by any number of letters or digits.   8. Implementation of Calculator using LEX and YACC  9. Convert the BNF rules into YACC form and write code to generat...