• Linux,  Ubuntu

    How to check if my Ubuntu is placed on SSD?

    A simple way to tell if your OS is installed on SSD or not is to run a command from a terminal window called lsblk -o name,rota. Look at the ROTA column of the output and there you will see numbers. A 0 means no rotation speed or SSD drive. A 1 would indicate a drive with platters that rotate. My Ubuntu is installed on my /dev/sdb drive, so we can see that one indicates a 0 which means it is installed on a SSD drive. I put after this example of how to tell where your OS is installed using df. NOTE: Ubuntu that is installed as a client…

  • Linux,  Ubuntu

    8 commands to check cpu information on Linux

    CPU hardware information The cpu information includes details about the processor, like the architecture, vendor name, model, number of cores, speed of each core etc. There are quite a few commands on linux to get those details about the cpu hardware, and here is a brief about some of the commands. 1. /proc/cpuinfo The /proc/cpuinfo file contains details about individual cpu cores. Output its contents with less or cat. $ less /proc/cpuinfo processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 23 model name : Intel(R) Core(TM)2 Quad CPU Q8400 @ 2.66GHz stepping : 10 microcode : 0xa07 cpu MHz : 1998.000 cache size : 2048 KB…

  • Ubuntu

    “Unable to locate package” while trying to install packages with APT

    There are many questions about this topic. Here I provide a basic/general answer. When apt-get install is unable to locate a package, the package you want to install couldn’t be found within repositories that you have added (those in in /etc/apt/sources.list and under /etc/apt/sources.list.d/). The following (general) procedure helps to solve this: Make sure you have enabled Ubuntu repositories: To enable all repositories (main, universe, restricted, multiverse), use the following commands: sudo add-apt-repository main sudo add-apt-repository universe sudo add-apt-repository restricted sudo add-apt-repository multiverse Visit Help for more information. For finding PPA for more packages: Go to Ubuntu Package Search. (Already explained in this answer) For External Repositories, Visit Ubuntu Updates…

  • Nginx,  PHP,  Ubuntu

    Increase Max Number of Allowed Opened Files

    This is “How To Increase Max Number of Allowed Opened Files Nginx and PHP-FPM on Ubuntu“. According to some tutorials you can changed the max number of opened files per user in /etc/security/limits.conf * soft nofile 64000 * hard nofile 68000 You also changed the max number of opened files for entire system in /etc/sysctl.conf fs.file-max = 200500 After reboot your machine, you should check soft and hard limits for your user login to the system with thuns@ubuntu:~$ ulimit -Sn 64000 thuns@ubuntu:~$ ulimit -Hn 68000 As you see, the limits applied to users. The problem is sometime that can’t change the limits for Nginx and PHP thuns@ubuntu:~$ sudo ps aux|grep…