Posts

Linux tips: Find the DNS Nameservers (DHCP)

Linux tips: Find the DNS Nameservers (DHCP) If you're looking for the DNS servers (IP) for your ISP through your working (DHCP) internet connection: Step 1: #  cat /var/lib/dhcp/dhclient.leases Step 2: (a) Look for your interface's name (e.g: eth0/eth1/wlan0) that's connected to internet (b) Look under: option domain-name-servers xxx.xxx.xxx.xxx, yyy.yyy.yyy.yyy (Tested working on Linux Mint 18.3).

Linux Tips: No internet on DHCP

Linux Tips: No internet on DHCP (Wifi) if you can't access the internet (on your router) despite getting a successful DHCP lease, Step 1: #  cd /etc/resolvconf/resolv.conf.d/ Step 2: Add (to base file) your ISP's DNS Nameservers - (the below ip(s) are examples): nameserver 172.17.5.68 nameserver 172.17.5.36 (Assumption: This is tested (working) on Linux Mint 18.3; you have an valid ip address (from DHCP) ).   Further info: If you're willing to use Google DNS Nameservers instead: // IPv4 nameserver 8.8.8.8 nameserver 8.8.4.4 // IPv6 nameserver 2001:4860:4860::8888 nameserver 2001:4860:4860::8844

Linux Tips: Adding Launcher on XFCE

Linux Tips: Adding Launcher on XFCE If you encounter a problem in starting a Launcher (added on XFCE) because of permission issues, try this (tested working on Linux Mint 18.3): Step 1: Open /usr/share/applications/ in your preferred file manager. Step 2: Drag the name (title) of the program that you want to the XFCE desktop. Step 3: Click on the newly created launcher & mark it executable when prompted. Step 4: Launch it again! Done.

Linux Tips: checking if software package is already installed

Linux Tips: checking if software package is already installed If your're using a variation of Linux Mint, to find out if a particular package is already installed: // e.g.: Check if network-manager is already installed on Linux Mint # apt-cache policy network-manager

Linux tips: Reset History size

Linux tips: Reset History size // To display history size # set | grep HIST // Change  HISTFILESIZE, HISTSIZE inside .bashrc # cd ~/.bashrc // Amend  .bashrc HISTFILESIZE=8000 HISTSIZE=8000 // Tested working on Linux Mint 18.3

Linux tips: Ways to restart your network/wifi

Linux tips: Ways to restart your network/wifi If you are experiencing problems with your network (before doing any of the below commands), // Display what devices are (i.e. Wifi/Ethernet/Loopback) on the network: # nmcli dev Method 1: // Turn Wifi off # nmcli radio wifi off // Turn Wifi on # nmcli radio wifi on Method 2: // Restart NetworkManager (systemd) service # systemctl restart NetworkManager.service Method 3: // Disable Wifi (i.e. wlan0) # ifconfig wlan0 down or # ifdown wlan0 down // Enable Wifi (i.e. wlan0) # ifconfig wlan0 up or # ifup wlan0  Method 4: // Force restart of network manager (for wired/wireless issues) # /etc/init.d/network-manager force-reload Method 5: // Add the following to: /etc/NetworkManager/NetworkManager.conf // Reason: Mac address randomization feature in Network Manager // contributed to downing (wifi) networks. [ifupdown] managed=true   [device] wifi.scan-rand-mac-address=no  

Linux tips: (Basic) Systemd services commands

Linux tips: (Basic) Systemd services commands // (1a) Display all active Systemd units # systemctl list-units or // (1b) Same as 1(a) # systemctl // To start Systemd service # systemctl start ???????.service // To stop Systemd service # systemctl stop ??????.service // To restart a running Systemd service # systemctl restart ??????.service // (2a) To reload config files for a Systemd service # systemctl reload ??????.service or  // (2b) Same functionality as (2a) except it will restart Systemd service as well # systemctl reload-or-restart ??????.service // To start Systemd service at boot # systemctl enable ??????.service // To stop Systemd service at boot # systemctl disable ??????.service // To check on status of Systemd service # systemctl status ??????.service // To show dependencies of a Systemd service # systemctl list-dependencies ??????.service