• العربية
  • Azerbaijani
  • Català
  • 中文
  • Hrvatski
  • Čeština
  • Dansk
  • Nederlands
  • English
  • Estonian
  • Persian
  • Français
  • Deutsch
  • עברית
  • Magyar
  • Italiano
  • Macedonian
  • Norwegian
  • Português
  • Português
  • Română
  • Русский
  • Español
  • Svenska
  • Türkçe
  • Українська
  • Account
    • Login
    • Register
    • Forgot Password?
  • FairyHosting.com
    • Services
      • My Services
      • Order New Services
      • Domains
      • DNS MANAGER
    • Payment
      • Invoices
      • Add funds
      • Mass Payment
    • Support
    • Knowledgebase
    • Affiliates

      Categories

    Hestia CP
    2
    ISPmanager
    9
    Linux Server
    25
    Plesk
    14
    Windows Server
    14
    Fairy Disk Services
    4
    Mikrotik (RouterOS)
    8
    Server management
    19
    For a new client
    13

      Categories

      Tag Cloud

    Debian Восстановление root пароля CentOS7 Linux сброс root пароля CentOS7 сервер Password recovery Root password Ubuntu

      Support

    My Support Tickets
    Knowledgebase
    Open Ticket

    Basic consol commands for Linux/Unix Print

    • 156

    In this article you can find the basic consol commands for Linux. They can help you for working on SSH.

    Basic commands of Linux consol



    Sudo - A widely used command in the Linux command line, sudo stands for "SuperUser Do". So, if you want any command to be done with administrative or root privileges, you can use the "sudo" command.
    Userdel - Delete user.

    whoami - Display who is logged on.
    whereis - Where you should search programm/package
    hostname - Use hostname to know your name in your host or network.
    top - Displays the resources being used on your system.
    service --status-all - Show all services installed on your Operating system.
    df - Use the df command to see the available disk space in each of the partitions in your system.
    Example: df -m

    uptime - Display time, working hours after loading, users quantity,
    w - Display information about working right at moment processes and users.
    ifconfig - Network settings (IP-address, Mask, Network address).
    traceroute domain - Utility initiates the sending of a packet (using the Internet Control Message Protocol or ICMP)
    whois domain - Information about domain.
    top - Displays the resources being used on your system.
    passwd - Change the password for the system administrator or user.
    pwd - When you first open the terminal, you are in the home directory of your user. To know which directory you are in, you can use the “pwd” command.

    history - command history.
    history -c - clear history.
    clear - Clear a command line screen/window for a fresh start.

    reboot - System restart.
    shutdown - Turn off or restart system (depend of options).
    Example: shutdown -r now (Meens: turn off and reboot system now).

    Linux commands: files and directorys


    cd - Use the "cd" command to go to a directory. Simple "cd" command using to go in home directory.
    Example: cd forder (move to forder)
    Example: cd .. (move to higher directory)
    Example: cd (move to / directory)

    cp - copy file
    Exmaple: cp file.txt file.backup - where file.txt is original file and file.backup is copy

    cd copy - Copy and move files.
    Example: cd source where.

    ls - Use the "Is" command to know what files are in the directory you are in.
    Example: ls - l  -

    Example: ls -a  - You can see all the hidden files

    apt
    - Use apt to work with packages in the Linux command line. Use apt to install, update and remove programm packages.
    Example: apt install ...
    Example: apt update ...

    Example: apt remove ...
    P.S. yum command is for CentOS!!!!!
    Example: yum install ...
    Example: yum update ...

    Example: yum remove ...

    cat - Create file with content
    Example: cat > file
    Now write needed information.
    CTRL+d
    Done.

    nano - Debian,Ubuntu text-editor.

    vi - CentOS text-editor.

    grep - Search files or output for a particular pattern.

    more и less - This command can be used to browse the contents of the specified file.

    chmod - Use chmod to make a file executable and to change the permissions granted to it in Linux.

    chown - Change who owns a file.

    find or locate - The locate or find command is used to locate a file in a Linux system, just like the search command in Windows.
    Example: find / -name file
    Example: locate file

    mv - Use the mv command to move files through the command line.
    Пример: mv file file1 (rename file, new name is file1).
    Пример: mv file.extension forder (move file which this extension to forder forder).

    mkdir "name" - Use the mkdir command when you need to create a folder or a directory.

    rmdir "name" - Delete directory.

    rm file - Delete file

    rm file* - Delete all files with name of file

    tar - archive file the name of file.tar
    Example: tar -cpf file.tar file - archive file(s)
    Example: tar -xpf file.tar - extract file(s)


    wget - Copy file on server.

     


    Was this answer helpful?

    Related Articles

    Ioncube installation Ioncube install on Debian server.   1. Archive download from website creator wget... Upload/download internet speed check in Linux Speedtest-cli is used to check the speed of uploading and downloading in the server and it use... Update nginx on Debian 6 1. Download nginx key wget http//nginx.org/keys/nginx_signing.key 2. Add him apt key add... Ioncube PHP Loader installation Install Ioncube PHP Loader extensions via SSH client.Firstable download module for your operating... How to change SSH port Default SSH server port is 22. Open configuration file /etc/ssh/sshd_config of SSH server by...
    « Back

      Tag Cloud

    Debian Восстановление root пароля CentOS7 Linux сброс root пароля CentOS7 сервер Password recovery Root password Ubuntu

      Support

    My Support Tickets
    Knowledgebase
    Open Ticket
    • Billing
      • Services
      • Invoices
      • Support
      • Knowledgebase
    • Services
      • Virtual servers
      • Dedicated servers
      • Colocation
      • Business hosting
      • Fairy Disk
      • Routers for rent
      • SSL-Certificates
    • News
    • Company
      • About Us
      • Contacts
      • User agreement
      • Privacy policy
    • Technologies

      RJ Network OÜ
      Reg.nr 14694302
      VAT ID: EE102147829

      Narva: P. Kerese tn 5, 20309
      Tallinn: Paul Pinna 8, 13615

    Telegram Chat

    +372 6647001

    [email protected]

    Copyright © 2025 FairyHosting.com. All Rights Reserved.


    Loading...
    Loading...
    Choose language
    العربية
    Azerbaijani
    Català
    中文
    Hrvatski
    Čeština
    Dansk
    Nederlands
    English
    Estonian
    Persian
    Français
    Deutsch
    עברית
    Magyar
    Italiano
    Macedonian
    Norwegian
    Português
    Português
    Română
    Русский
    Español
    Svenska
    Türkçe
    Українська

    Generate Password

    Please enter a number between 8 and 64 for the password length