![]() |
|
SOME EVERGREEN USEFUL LINUX COMMANDS - Printable Version +- Post4VPS Forum | Free VPS Provider (https://post4vps.com) +-- Forum: VPS Discussion (https://post4vps.com/Forum-VPS-Discussion) +--- Forum: Tutorials (https://post4vps.com/Forum-Tutorials) +--- Thread: SOME EVERGREEN USEFUL LINUX COMMANDS (/Thread-SOME-EVERGREEN-USEFUL-LINUX-COMMANDS) |
SOME EVERGREEN USEFUL LINUX COMMANDS - sagher - 03-13-2017 Hello Friends: Today i wish to share with you some very easy but useful commands for linux Debian/Ubuntu . The experts can't really like it but newbies really want to know those commands. two most used commands as everyone know as "apt-get update , apt-get upgrade" so with this you can install any package with "apt-get install [package name] But mostly we got problem when we wish to uninstall or remove any app who misbehave or unused. and mostly running apps are difficult to be remove with simple remove command. so i like to share some special commands. if you victim with broken package. try this sequence of any one of those. Code: sudo apt-get cleanit will clean registry or cache. Code: sudo dpkg --configure -ait will auto configure package list again. Code: sudo apt-get autoremoveThis command simply helps you to remove broken package. but mostly with this command you reply from server that package not found. try to reinstall or etc.... then you try this command to install selected package again with good complete files. Code: sudo apt-get upgrade && sudo apt-get -f install"-f" is use for force process. you can use it for various process.you can also use it as simple as Code: sudo apt-get -f install package_name #(force install)but if you again get any error you try this Code: sudo dpkg --remove --force-remove-reinstreq package_nameit will again try to force remove your unwanted package. at the end try this to purge if your package are distributed on different places. and simple remove command can't collect full data. Code: sudo apt-get autoremove --purgeremoving package with all cache and check the availability on package list. Code: sudo rm -rf /var/cache/apt/archives/nodejs_0.10.28-1chl1~trusty1_amd64.debalso this if above are mot works. Code: sudo dpkg -i --force-overwrite /var/cache/apt/archives/nodejs_0.10.28-1chl1~trusty1_amd64.debHope you like it and it's makes your work more easy to install and remove any package.. Regards Sagher RE: SOME EVERGREEN USEFUL LINUX COMMANDS - YOuNeS_Dz - 03-13-2017 can you please make one for cent os ? some commands wont work on cent os :3 RE: SOME EVERGREEN USEFUL LINUX COMMANDS - sagher - 03-14-2017 @YOuNeS_Dz : can you please define me which one are not working for you. then i try to fix it as per centOS. But remember one thing. "apt-get" command are only for Debian and Ubuntu. for CentOS you can use "yum" command to install something. RE: SOME EVERGREEN USEFUL LINUX COMMANDS - Vuluts - 03-14-2017 for Centos just change the"apt-get" command into "yum", if you experience some errors you can post it here and our brothers can help you out. RE: SOME EVERGREEN USEFUL LINUX COMMANDS - YOuNeS_Dz - 03-17-2017 Well, the problem was here Code: sudo apt-get -f install package_name #(force install)i forget to put sudo : .. now done, thank you
RE: SOME EVERGREEN USEFUL LINUX COMMANDS - sagher - 03-18-2017 Some Basic Commands For CentOS are not too different as Debian or Ubuntu. For example Code: yum install <package name>Used to remove specified packages, along with any other packages dependent on the packages being removed. Code: yum provides <file name>Used to determine which packages provide a specific file or feature. Code: yum search <keyword>This command is used to find any packages containing the specified keyword in the description, summary, packager and package name fields of RPMs in all repositories. Code: yum localinstall <absolute path to package name/s>Second is to install RPM packages. if you have backup of package Use -ivh switch along with rpm command as shown below Code: # cd /root/rpmsIf directly from web link.But for this you need to have the proper link of the rpm you want to download or install: Code: # rpm -ivh ftp://ftp.pbone.net/mirror/ftp.centos.org/6.5/os/i386/Packages/cvs-1.11.23-16.el6.i686.rpmif not don normally then use force installation method.Use --force argument along with -ivh switch as shown below to install forcefully without dependencies Code: # rpm -ivh vsftpd-2.2.2-11.el6_4.1.i686.rpm --forceFinally. Upgrading or removing the RPM packages.Use -Uvh switch along with rpm command Upgrade: Code: # rpm -q vsftpdRemove: You can uninstall a package using -e switch along with rpm command Code: # rpm -qa | grep cvsUse an extra argument --nodeps along with rpm command to remove/uninstall a package without dependencies Code: # rpm -e vsftpd-2.2.2-11.el6_4.1.i686 --nodepsRegards: Sagher RE: SOME EVERGREEN USEFUL LINUX COMMANDS - Jayce - 03-18-2017 Really basic, but useful for beginners I would say. Anyways, it would be better if you explain what commands do, because it helps beginners to learn basic Linux commands. RE: SOME EVERGREEN USEFUL LINUX COMMANDS - sagher - 03-19-2017 @Jayce : yes i definitely do it on demand. i make it simple in first step. if any member need further detail. i like to explain as required. |