Posts

Showing posts with the label command

Using apt terminal command in Ubuntu

Using apt terminal command in Ubuntu Yes, you read that right, it is apt instead of apt-get . I was used with apt-get command to install, update and remove repositories packages. apt command compared to apt-get has a few advantages:  coloring and progress bar when you install or update a package. One downside of using apt command is the partial support of tab completion, which apt-get has mastered it. And I know that tab completion is very usefull. In terms of functionality, its almost the same as apt-get command. Even the commands are very similar. 1. Update repositories with apt: sudo apt update 2. List upgradable packages: sudo apt list --upgradable 3. Install/update a package: sudo apt install wget 4. Remove a package: sudo apt remove vim For more informations read the apt command manual: man apt download  file  now

Using the IP command

Using the IP command The command /bin/ip has been around for some time now. But people continue using the older command /sbin/ifconfig. ifconfig wont go away quickly, but its newer version, ip, is more powerful and will eventually replace it. So here are the basics of the new ip command. Assign a IP Address to Specific Interface: sudo ip addr add 192.168.50.5 dev eth1  Check an IP Address: sudo ip addr show  Remove an IP Address: sudo ip addr del 192.168.50.5/24 dev eth1  Enable Network Interface: sudo ip link set eth1 up  Disable Network Interface: sudo ip link set eth1 down   Check Route Table: sudo ip route show  Add Static Route: sudo ip route add 10.10.20.0/24 via 192.168.50.100 dev eth0  Remove Static Route: sudo ip route del 10.10.20.0/24  Add Default Gateway: sudo ip route add default via 192.168.50.100 download  file  now

Using apt get terminal command in Ubuntu

Using apt get terminal command in Ubuntu By using apt-get terminal command in Ubuntu, you will be able to serach, install, update and remove Ubuntu applications from repositories. To resynchronize the package index files from their sources via Internet, also known as repositories. You need to do this after each edit of your repositories file /etc/apt/sources.list : sudo apt-get update To install the newest versions of all packages currently installed on the system: sudo apt-get upgrade Install is followed by one or more packages (programs) desired for installation. If package is already installed it will try to update to latest version. sudo apt-get install package-name To uninstall a package: sudo apt-get remove package-name To uninstall a package and remove all of its settings: sudo apt-get remove --purge package-name If you have terminated an installation, you can clean it with: sudo apt-get clean All the terminal options for apt-get can be found running: sudo apt-get --help It wil...

Using ls and find command how to display only directories

Using ls and find command how to display only directories Following commands list only directories in the current directory. 1. #ls -l | grep ^d 2. #ls -d */ 3. #find -type d Ex: #find /tmp -type d Want only files to be listed.. use 1. #ls -l | grep -v ^d 2. #find -type f Ex: #find /tmp -type f download  file  now